• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

TrinityCore 3.3.5 Multivendor Problem

Portals

Banned
Okay so I have a problem using Rochet's Multivendor.

This is my query to create the gossip menu options and then add the items I want to the vendor.
Code:
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES 

	(60010, 3, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60010, 2, 3, 'Trinkets', 0, 3, 128, 500051, 0, 0, 0, NULL, 0),
	(60010, 1, 3, 'Rings', 0, 3, 128, 500050, 0, 0, 0, NULL, 0),
	(60010, 0, 3, 'Necks', 0, 3, 128, 500049, 0, 0, 0, NULL, 0),

	(60009, 15, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60009, 14, 3, 'Wand', 0, 3, 128, 500048, 0, 0, 0, NULL, 0),
	(60009, 13, 3, 'Crossbow', 0, 3, 128, 500047, 0, 0, 0, NULL, 0),
	(60009, 12, 3, 'Thrown', 0, 3, 128, 500046, 0, 0, 0, NULL, 0),
	(60009, 11, 3, 'Dagger', 0, 3, 128, 500045, 0, 0, 0, NULL, 0),
	(60009, 10, 3, 'Fist Weapons', 0, 3, 128, 500044, 0, 0, 0, NULL, 0),
	(60009, 9, 3, 'Staves', 0, 3, 128, 500043, 0, 0, 0, NULL, 0),
	(60009, 8, 3, 'Swords (Two Handed)', 0, 3, 128, 500042, 0, 0, 0, NULL, 0),
	(60009, 7, 3, 'Swords (One Handed)', 0, 3, 128, 500041, 0, 0, 0, NULL, 0),
	(60009, 6, 3, 'Polearms', 0, 3, 128, 500040, 0, 0, 0, NULL, 0),
	(60009, 5, 3, 'Maces (Two Handed)', 0, 3, 128, 500039, 0, 0, 0, NULL, 0),
	(60009, 4, 3, 'Maces (One Handed)', 0, 3, 128, 500038, 0, 0, 0, NULL, 0),
	(60009, 3, 3, 'Guns', 0, 3, 128, 500037, 0, 0, 0, NULL, 0),
	(60009, 2, 3, 'Bows', 0, 3, 128, 500036, 0, 0, 0, NULL, 0),
	(60009, 1, 3, 'Axes	(Two Handed)', 0, 3, 128, 500035, 0, 0, 0, NULL, 0),
	(60009, 0, 3, 'Axes	(One Handed)', 0, 3, 128, 500034, 0, 0, 0, NULL, 0),

	(60008, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60008, 3, 3, 'Plate', 0, 3, 128, 500033, 0, 0, 0, NULL, 0),
	(60008, 2, 3, 'Mail', 0, 3, 128, 500032, 0, 0, 0, NULL, 0),
	(60008, 1, 3, 'Leather', 0, 3, 128, 500031, 0, 0, 0, NULL, 0),
	(60008, 0, 3, 'Cloth', 0, 3, 128, 500030, 0, 0, 0, NULL, 0),

	(60007, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60007, 3, 3, 'Plate', 0, 3, 128, 500029, 0, 0, 0, NULL, 0),
	(60007, 2, 3, 'Mail', 0, 3, 128, 500028, 0, 0, 0, NULL, 0),
	(60007, 1, 3, 'Leather', 0, 3, 128, 500027, 0, 0, 0, NULL, 0),
	(60007, 0, 3, 'Cloth', 0, 3, 128, 500026, 0, 0, 0, NULL, 0),

	(60006, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60006, 3, 3, 'Plate', 0, 3, 128, 500025, 0, 0, 0, NULL, 0),
	(60006, 2, 3, 'Mail', 0, 3, 128, 500024, 0, 0, 0, NULL, 0),
	(60006, 1, 3, 'Leather', 0, 3, 128, 500023, 0, 0, 0, NULL, 0),
	(60006, 0, 3, 'Cloth', 0, 3, 128, 500022, 0, 0, 0, NULL, 0),

	(60005, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60005, 3, 3, 'Plate', 0, 3, 128, 500021, 0, 0, 0, NULL, 0),
	(60005, 2, 3, 'Mail', 0, 3, 128, 500020, 0, 0, 0, NULL, 0),
	(60005, 1, 3, 'Leather', 0, 3, 128, 500019, 0, 0, 0, NULL, 0),
	(60005, 0, 3, 'Cloth', 0, 3, 128, 500018, 0, 0, 0, NULL, 0),

	(60004, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60004, 3, 3, 'Plate', 0, 3, 128, 500017, 0, 0, 0, NULL, 0),
	(60004, 2, 3, 'Mail', 0, 3, 128, 500016, 0, 0, 0, NULL, 0),
	(60004, 1, 3, 'Leather', 0, 3, 128, 500015, 0, 0, 0, NULL, 0),
	(60004, 0, 3, 'Cloth', 0, 3, 128, 500014, 0, 0, 0, NULL, 0),

	(60003, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60003, 3, 3, 'Plate', 0, 3, 128, 500013, 0, 0, 0, NULL, 0),
	(60003, 2, 3, 'Mail', 0, 3, 128, 500012, 0, 0, 0, NULL, 0),
	(60003, 1, 3, 'Leather', 0, 3, 128, 500011, 0, 0, 0, NULL, 0),
	(60003, 0, 3, 'Cloth', 0, 3, 128, 500010, 0, 0, 0, NULL, 0),

	(60002, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60002, 3, 3, 'Plate', 0, 3, 128, 500009, 0, 0, 0, NULL, 0),
	(60002, 2, 3, 'Mail', 0, 3, 128, 500008, 0, 0, 0, NULL, 0),
	(60002, 1, 3, 'Leather', 0, 3, 128, 500007, 0, 0, 0, NULL, 0),
	(60002, 0, 3, 'Cloth', 0, 3, 128, 500006, 0, 0, 0, NULL, 0),

	(60001, 4, 3, 'Back', 0, 1, 1, 60000, 0, 0, 0, NULL, 0),
	(60001, 3, 3, 'Plate', 0, 1, 1, 500005, 0, 0, 0, NULL, 0),
	(60001, 2, 3, 'Mail', 0, 3, 128, 500004, 0, 0, 0, NULL, 0),
	(60001, 1, 3, 'Leather', 0, 3, 128, 500003, 0, 0, 0, NULL, 0),
	(60001, 0, 3, 'Cloth', 0, 3, 128, 500002, 0, 0, 0, NULL, 0),

	(60000, 12, 3, 'Jewelry', 0, 1, 1, 60010, 0, 0, 0, NULL, 0),
	(60000, 11, 3, 'Off Hands', 0, 3, 128, 500001, 0, 0, 0, NULL, 0),
	(60000, 10, 3, 'Weapons', 0, 1, 1, 60009, 0, 0, 0, NULL, 0),
	(60000, 9, 3, 'Boots', 0, 1, 1, 60008, 0, 0, 0, NULL, 0),
	(60000, 8, 3, 'Legguards', 0, 1, 1, 60007, 0, 0, 0, NULL, 0),
	(60000, 7, 3, 'Belts', 0, 1, 1, 60006, 0, 0, 0, NULL, 0),
	(60000, 6, 3, 'Gloves', 0, 1, 1, 60005, 0, 0, 0, NULL, 0),
	(60000, 5, 3, 'Bracers', 0, 1, 1, 60004, 0, 0, 0, NULL, 0),
	(60000, 4, 3, 'Chestguards', 0, 1, 1, 60003, 0, 0, 0, NULL, 0),
	(60000, 3, 3, 'Cloaks', 0, 3, 128, 500000, 0, 0, 0, NULL, 0),
	(60000, 2, 3, 'Shoulders', 0, 1, 1, 60002, 0, 0, 0, NULL, 0),
	(60000, 1, 3, 'Helmets', 0, 1, 1, 60001, 0, 0, 0, NULL, 0);



/*Cloaks*/
SET @Entry :=500000;
SET @iLvL :=46;
SET @type :=16;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Off Hands*/
SET @Entry :=500001;
SET @iLvL :=46;
SET @type :=14;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `quality`=@quality;
SET @Entry :=500001;
SET @iLvL :=46;
SET @type :=22;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `quality`=@quality;
SET @Entry :=500001;
SET @iLvL :=46;
SET @type :=23;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `quality`=@quality;

/*Helms*/
SET @Entry :=500002;
SET @iLvL :=46;
SET @type :=1;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500003;
SET @iLvL :=46;
SET @type :=1;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500004;
SET @iLvL :=46;
SET @type :=1;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500005;
SET @iLvL :=46;
SET @type :=1;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Shoulders*/
SET @Entry :=500006;
SET @iLvL :=46;
SET @type :=3;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500007;
SET @iLvL :=46;
SET @type :=3;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500008;
SET @iLvL :=46;
SET @type :=3;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500009;
SET @iLvL :=46;
SET @type :=3;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Chestguards*/
SET @Entry :=500010;
SET @iLvL :=46;
SET @type :=5;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500010;
SET @iLvL :=46;
SET @type :=20;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500011;
SET @iLvL :=46;
SET @type :=5;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500011;
SET @iLvL :=46;
SET @type :=20;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500012;
SET @iLvL :=46;
SET @type :=5;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500012;
SET @iLvL :=46;
SET @type :=20;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500013;
SET @iLvL :=46;
SET @type :=5;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500013;
SET @iLvL :=46;
SET @type :=20;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Bracers*/
SET @Entry :=500014;
SET @iLvL :=46;
SET @type :=9;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500015;
SET @iLvL :=46;
SET @type :=9;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500016;
SET @iLvL :=46;
SET @type :=9;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500017;
SET @iLvL :=46;
SET @type :=9;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Gloves*/
SET @Entry :=500018;
SET @iLvL :=46;
SET @type :=10;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500019;
SET @iLvL :=46;
SET @type :=10;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500020;
SET @iLvL :=46;
SET @type :=10;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500021;
SET @iLvL :=46;
SET @type :=10;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Belts*/
SET @Entry :=500022;
SET @iLvL :=46;
SET @type :=6;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500023;
SET @iLvL :=46;
SET @type :=6;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500024;
SET @iLvL :=46;
SET @type :=6;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500025;
SET @iLvL :=46;
SET @type :=6;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Legguards*/
SET @Entry :=500026;
SET @iLvL :=46;
SET @type :=7;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500027;
SET @iLvL :=46;
SET @type :=7;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500028;
SET @iLvL :=46;
SET @type :=7;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500029;
SET @iLvL :=46;
SET @type :=7;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Boots*/
SET @Entry :=500030;
SET @iLvL :=46;
SET @type :=8;
SET @class :=4;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500031;
SET @iLvL :=46;
SET @type :=8;
SET @class :=4;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500032;
SET @iLvL :=46;
SET @type :=8;
SET @class :=4;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500033;
SET @iLvL :=46;
SET @type :=8;
SET @class :=4;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Weapons*/
SET @Entry :=500034;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=0;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500035;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=1;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500036;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500037;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=3;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500038;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=4;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500039;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=5;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500040;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=6;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500041;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=7;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500042;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=8;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500043;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=10;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500044;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=13;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500045;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=15;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500046;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=16;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500047;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=18;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;
SET @Entry :=500048;
SET @iLvL :=46;
SET @class :=2;
SET @sub :=19;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `class`=@class AND `subclass`=@sub AND `quality`=@quality;

/*Jewelry*/
SET @Entry :=500049;
SET @iLvL :=46;
SET @type :=2;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type  AND `quality`=@quality;
SET @Entry :=500050;
SET @iLvL :=46;
SET @type :=11;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type  AND `quality`=@quality;
SET @Entry :=500051;
SET @iLvL :=46;
SET @type :=12;
SET @quality :=4;
INSERT IGNORE INTO `npc_vendor` (`entry`, `slot`, `item`, `maxcount`, `incrtime`, `ExtendedCost`)
SELECT @Entry, 0, entry, 0, 0, 0 FROM `item_template` WHERE `ItemLevel`=@iLvL AND `InventoryType`=@type  AND `quality`=@quality;

Now the code executes correctly and has no errors. But ingame there is an issue.

As you can see in this picture some of the menus do not appear
N8YR86p.png


After trying to click one of the menus I get this in the worldserver.exe screen
yjGcCTm.png


Anyone able to explain the issue here? Also feel free to use my query if anyone wants to its very easy to edit.
 

Rochet2

Moderator / Eluna Dev
How old multivendor are you using?
Does the default example work for you exactly as it is?

have you checked that the vendor you try to open is not empty?
 
Top