This commit is contained in:
Discover-
2013-09-23 16:47:47 +02:00
158 changed files with 5669 additions and 2426 deletions
File diff suppressed because one or more lines are too long
@@ -0,0 +1,25 @@
/* cs_group.cpp */
SET @id = 472;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+6;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0 , 'group'),
(@id+1 , 'group leader'),
(@id+2 , 'group disband'),
(@id+3 , 'group remove'),
(@id+4 , 'group join'),
(@id+5 , 'group list'),
(@id+6 , 'group summon');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+6;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+2),
(4, @id+3),
(4, @id+4),
(4, @id+5),
(4, @id+6);
@@ -0,0 +1,19 @@
/* cs_pet.cpp */
SET @id = 479;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+3;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0 , 'pet'),
(@id+1 , 'pet create'),
(@id+2 , 'pet learn'),
(@id+3 , 'pet unlearn');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+3;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(3, @id+0),
(3, @id+1),
(3, @id+2),
(3, @id+3);
@@ -0,0 +1,21 @@
/* cs_send.cpp */
SET @id = 483;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+4;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0 , 'send'),
(@id+1 , 'send items'),
(@id+2 , 'send mail'),
(@id+3 , 'send message'),
(@id+4 , 'send money');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+4;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(2, @id+0),
(2, @id+1),
(3, @id+2),
(3, @id+3),
(3, @id+4);
@@ -0,0 +1,107 @@
/* cs_misc.cpp */
SET @id = 488;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+47;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'additem'),
(@id+1, 'additemset'),
(@id+2, 'appear'),
(@id+3, 'aura'),
(@id+4, 'bank'),
(@id+5, 'bindsight'),
(@id+6, 'combatstop'),
(@id+7, 'cometome'),
(@id+8, 'commands'),
(@id+9, 'cooldown'),
(@id+10, 'damage'),
(@id+11, 'dev'),
(@id+12, 'die'),
(@id+13, 'dismount'),
(@id+14, 'distance'),
(@id+15, 'flusharenapoints'),
(@id+16, 'freeze'),
(@id+17, 'gps'),
(@id+18, 'guid'),
(@id+19, 'help'),
(@id+20, 'hidearea'),
(@id+21, 'itemmove'),
(@id+22, 'kick'),
(@id+23, 'linkgrave'),
(@id+24, 'listfreeze'),
(@id+25, 'maxskill'),
(@id+26, 'movegens'),
(@id+27, 'mute'),
(@id+28, 'neargrave'),
(@id+29, 'pinfo'),
(@id+30, 'playall'),
(@id+31, 'possess'),
(@id+32, 'recall'),
(@id+33, 'repairitems'),
(@id+34, 'respawn'),
(@id+35, 'revive'),
(@id+36, 'saveall'),
(@id+37, 'save'),
(@id+38, 'setskill'),
(@id+39, 'showarea'),
(@id+40, 'summon'),
(@id+41, 'unaura'),
(@id+42, 'unbindsight'),
(@id+43, 'unfreeze'),
(@id+44, 'unmute'),
(@id+45, 'unpossess'),
(@id+46, 'unstuck'),
(@id+47, 'wchange');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+47;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(2, @id+2),
(4, @id+3),
(4, @id+4),
(4, @id+5),
(3, @id+6),
(4, @id+7),
(1, @id+8),
(4, @id+9),
(4, @id+10),
(4, @id+11),
(4, @id+12),
(1, @id+13),
(4, @id+14),
(4, @id+15),
(2, @id+16),
(4, @id+17),
(3, @id+18),
(1, @id+19),
(4, @id+20),
(3, @id+21),
(3, @id+22),
(4, @id+23),
(2, @id+24),
(4, @id+25),
(4, @id+26),
(2, @id+27),
(4, @id+28),
(3, @id+29),
(3, @id+30),
(4, @id+31),
(2, @id+32),
(3, @id+33),
(4, @id+34),
(4, @id+35),
(2, @id+36),
(1, @id+37),
(4, @id+38),
(4, @id+39),
(2, @id+40),
(4, @id+41),
(4, @id+42),
(2, @id+43),
(2, @id+44),
(4, @id+45),
(1, @id+46),
(4, @id+47);
@@ -0,0 +1,23 @@
/* cs_mmaps.cpp */
SET @id = 536;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+5;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'mmap'),
(@id+1, 'mmap loadedtiles'),
(@id+2, 'mmap loc'),
(@id+3, 'mmap path'),
(@id+4, 'mmap stats'),
(@id+5, 'mmap testarea');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+5;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+2),
(4, @id+3),
(4, @id+4),
(4, @id+5);
@@ -0,0 +1,68 @@
/* cs_modify.cpp */
SET @id = 542;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+27;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'morph'),
(@id+1, 'demorph'),
(@id+2, 'modify'),
(@id+3, 'modify arenapoints'),
(@id+4, 'modify bit'),
(@id+5, 'modify drunk'),
(@id+6, 'modify energy'),
(@id+7, 'modify faction'),
(@id+8, 'modify gender'),
(@id+9, 'modify honor'),
(@id+10, 'modify hp'),
(@id+11, 'modify mana'),
(@id+12, 'modify money'),
(@id+13, 'modify mount'),
(@id+14, 'modify phase'),
(@id+15, 'modify rage'),
(@id+16, 'modify reputation'),
(@id+17, 'modify runicpower'),
(@id+18, 'modify scale'),
(@id+19, 'modify speed'),
(@id+20, 'modify speed all'),
(@id+21, 'modify speed backwalk'),
(@id+22, 'modify speed fly'),
(@id+23, 'modify speed walk'),
(@id+24, 'modify speed swim'),
(@id+25, 'modify spell'),
(@id+26, 'modify standstate'),
(@id+27, 'modify talentpoints');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+27;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(3, @id+0),
(3, @id+1),
(2, @id+2),
(2, @id+3),
(2, @id+4),
(2, @id+5),
(2, @id+6),
(2, @id+7),
(3, @id+8),
(2, @id+9),
(2, @id+10),
(2, @id+11),
(2, @id+12),
(2, @id+13),
(4, @id+14),
(2, @id+15),
(3, @id+16),
(2, @id+17),
(2, @id+18),
(2, @id+19),
(2, @id+20),
(2, @id+21),
(2, @id+22),
(2, @id+23),
(2, @id+24),
(2, @id+25),
(3, @id+26),
(2, @id+27);
@@ -0,0 +1,75 @@
/* cs_npc.cpp */
SET @id = 570;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+31;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'npc'),
(@id+1, 'npc add'),
(@id+2, 'npc add formation'),
(@id+3, 'npc add item'),
(@id+4, 'npc add move'),
(@id+5, 'npc add temp'),
(@id+6, 'npc add delete'),
(@id+7, 'npc add delete item'),
(@id+8, 'npc add follow'),
(@id+9, 'npc add follow stop'),
(@id+10, 'npc set'),
(@id+11, 'npc set allowmove'),
(@id+12, 'npc set entry'),
(@id+13, 'npc set factionid'),
(@id+14, 'npc set flag'),
(@id+15, 'npc set level'),
(@id+16, 'npc set link'),
(@id+17, 'npc set model'),
(@id+18, 'npc set movetype'),
(@id+19, 'npc set phase'),
(@id+20, 'npc set spawndist'),
(@id+21, 'npc set spawntime'),
(@id+22, 'npc set data'),
(@id+23, 'npc info'),
(@id+24, 'npc near'),
(@id+25, 'npc move'),
(@id+26, 'npc playemote'),
(@id+27, 'npc say'),
(@id+28, 'npc textemote'),
(@id+29, 'npc whisper'),
(@id+30, 'npc yell'),
(@id+31, 'npc tame');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+31;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(2, @id+0),
(3, @id+1),
(3, @id+2),
(3, @id+3),
(3, @id+4),
(3, @id+5),
(3, @id+6),
(3, @id+7),
(3, @id+8),
(3, @id+9),
(3, @id+10),
(4, @id+11),
(4, @id+12),
(3, @id+13),
(3, @id+14),
(3, @id+15),
(3, @id+16),
(3, @id+17),
(3, @id+18),
(3, @id+19),
(3, @id+20),
(3, @id+21),
(4, @id+22),
(4, @id+23),
(3, @id+24),
(3, @id+25),
(4, @id+26),
(2, @id+27),
(2, @id+28),
(2, @id+29),
(2, @id+30),
(3, @id+31);
@@ -0,0 +1,21 @@
/* cs_quest.cpp */
SET @id = 602;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+4;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'quest'),
(@id+1, 'quest add'),
(@id+2, 'quest complete'),
(@id+3, 'quest remove'),
(@id+4, 'quest reward');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+4;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+2),
(4, @id+3),
(4, @id+4);
@@ -0,0 +1,217 @@
/* cs_reload.cpp */
SET @id = 607;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+102;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'reload'),
(@id+1, 'reload access_requirement'),
(@id+2, 'reload achievement_criteria_data'),
(@id+3, 'reload achievement_reward'),
(@id+4, 'reload all'),
(@id+5, 'reload all achievement'),
(@id+6, 'reload all area'),
(@id+7, 'reload all eventai'),
(@id+8, 'reload all gossips'),
(@id+9, 'reload all item'),
(@id+10, 'reload all locales'),
(@id+11, 'reload all loot'),
(@id+12, 'reload all npc'),
(@id+13, 'reload all quest'),
(@id+14, 'reload all scripts'),
(@id+15, 'reload all spell'),
(@id+16, 'reload areatrigger_involvedrelation'),
(@id+17, 'reload areatrigger_tavern'),
(@id+18, 'reload areatrigger_teleport'),
(@id+19, 'reload auctions'),
(@id+20, 'reload autobroadcast'),
(@id+21, 'reload command'),
(@id+22, 'reload conditions'),
(@id+23, 'reload config'),
(@id+24, 'reload creature_text'),
(@id+25, 'reload creature_ai_scripts'),
(@id+26, 'reload creature_ai_texts'),
(@id+27, 'reload creature_questender'),
(@id+28, 'reload creature_linked_respawn'),
(@id+29, 'reload creature_loot_template'),
(@id+30, 'reload creature_onkill_reputation'),
(@id+31, 'reload creature_queststarter'),
(@id+32, 'reload creature_summon_groups'),
(@id+33, 'reload creature_template'),
(@id+34, 'reload disables'),
(@id+35, 'reload disenchant_loot_template'),
(@id+36, 'reload event_scripts'),
(@id+37, 'reload fishing_loot_template'),
(@id+38, 'reload game_graveyard_zone'),
(@id+39, 'reload game_tele'),
(@id+40, 'reload gameobject_questender'),
(@id+41, 'reload gameobject_loot_template'),
(@id+42, 'reload gameobject_queststarter'),
(@id+43, 'reload gm_tickets'),
(@id+44, 'reload gossip_menu'),
(@id+45, 'reload gossip_menu_option'),
(@id+46, 'reload item_enchantment_template'),
(@id+47, 'reload item_loot_template'),
(@id+48, 'reload item_set_names'),
(@id+49, 'reload lfg_dungeon_rewards'),
(@id+50, 'reload locales_achievement_reward'),
(@id+51, 'reload locales_creature'),
(@id+52, 'reload locales_creature_text'),
(@id+53, 'reload locales_gameobject'),
(@id+54, 'reload locales_gossip_menu_option'),
(@id+55, 'reload locales_item'),
(@id+56, 'reload locales_item_set_name'),
(@id+57, 'reload locales_npc_text'),
(@id+58, 'reload locales_page_text'),
(@id+59, 'reload locales_points_of_interest'),
(@id+60, 'reload locales_quest'),
(@id+61, 'reload mail_level_reward'),
(@id+62, 'reload mail_loot_template'),
(@id+63, 'reload milling_loot_template'),
(@id+64, 'reload npc_spellclick_spells'),
(@id+65, 'reload npc_trainer'),
(@id+66, 'reload npc_vendor'),
(@id+67, 'reload page_text'),
(@id+68, 'reload pickpocketing_loot_template'),
(@id+69, 'reload points_of_interest'),
(@id+70, 'reload prospecting_loot_template'),
(@id+71, 'reload quest_poi'),
(@id+72, 'reload quest_template'),
(@id+73, 'reload rbac'),
(@id+74, 'reload reference_loot_template'),
(@id+75, 'reload reserved_name'),
(@id+76, 'reload reputation_reward_rate'),
(@id+77, 'reload reputation_spillover_template'),
(@id+78, 'reload skill_discovery_template'),
(@id+79, 'reload skill_extra_item_template'),
(@id+80, 'reload skill_fishing_base_level'),
(@id+81, 'reload skinning_loot_template'),
(@id+82, 'reload smart_scripts'),
(@id+83, 'reload spell_required'),
(@id+84, 'reload spell_area'),
(@id+85, 'reload spell_bonus_data'),
(@id+86, 'reload spell_group'),
(@id+87, 'reload spell_learn_spell'),
(@id+88, 'reload spell_loot_template'),
(@id+89, 'reload spell_linked_spell'),
(@id+90, 'reload spell_pet_auras'),
(@id+91, 'reload spell_proc_event'),
(@id+92, 'reload spell_proc'),
(@id+93, 'reload spell_scripts'),
(@id+94, 'reload spell_target_position'),
(@id+95, 'reload spell_threats'),
(@id+96, 'reload spell_group_stack_rules'),
(@id+97, 'reload trinity_string'),
(@id+98, 'reload warden_action'),
(@id+99, 'reload waypoint_scripts'),
(@id+100, 'reload waypoint_data'),
(@id+101, 'reload vehicle_accessory'),
(@id+102, 'reload vehicle_template_accessory');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+102;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+2),
(4, @id+3),
(4, @id+4),
(4, @id+5),
(4, @id+6),
(4, @id+7),
(4, @id+8),
(4, @id+9),
(4, @id+10),
(4, @id+11),
(4, @id+12),
(4, @id+13),
(4, @id+14),
(4, @id+15),
(4, @id+16),
(4, @id+17),
(4, @id+18),
(4, @id+19),
(4, @id+20),
(4, @id+21),
(4, @id+22),
(4, @id+23),
(4, @id+24),
(4, @id+25),
(4, @id+26),
(4, @id+27),
(4, @id+28),
(4, @id+29),
(4, @id+30),
(4, @id+31),
(4, @id+32),
(4, @id+33),
(4, @id+34),
(4, @id+35),
(4, @id+36),
(4, @id+37),
(4, @id+38),
(4, @id+39),
(4, @id+40),
(4, @id+41),
(4, @id+42),
(4, @id+43),
(4, @id+44),
(4, @id+45),
(4, @id+46),
(4, @id+47),
(4, @id+48),
(4, @id+49),
(4, @id+50),
(4, @id+51),
(4, @id+52),
(4, @id+53),
(4, @id+54),
(4, @id+55),
(4, @id+56),
(4, @id+57),
(4, @id+58),
(4, @id+59),
(4, @id+60),
(4, @id+61),
(4, @id+62),
(4, @id+63),
(4, @id+64),
(4, @id+65),
(4, @id+66),
(4, @id+67),
(4, @id+68),
(4, @id+69),
(4, @id+70),
(4, @id+71),
(4, @id+72),
(4, @id+73),
(4, @id+74),
(4, @id+75),
(4, @id+76),
(4, @id+77),
(4, @id+78),
(4, @id+79),
(4, @id+80),
(4, @id+81),
(4, @id+82),
(4, @id+83),
(4, @id+84),
(4, @id+85),
(4, @id+86),
(4, @id+87),
(4, @id+88),
(4, @id+89),
(4, @id+90),
(4, @id+91),
(4, @id+92),
(4, @id+93),
(4, @id+94),
(4, @id+95),
(4, @id+96),
(4, @id+97),
(4, @id+98),
(4, @id+99),
(4, @id+100),
(4, @id+101),
(4, @id+102);
@@ -0,0 +1,27 @@
/* cs_reset.cpp */
SET @id = 710;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+7;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'reset'),
(@id+1, 'reset achievements'),
(@id+2, 'reset honor'),
(@id+3, 'reset level'),
(@id+4, 'reset spells'),
(@id+5, 'reset stats'),
(@id+6, 'reset talents'),
(@id+7, 'reset all');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+7;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+2),
(4, @id+3),
(4, @id+4),
(4, @id+5),
(4, @id+6),
(4, @id+7);
@@ -0,0 +1,46 @@
/* cs_server.cpp */
SET @id = 718;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+18;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'server'),
(@id+1, 'server corpses'),
(@id+2, 'server exit'),
(@id+3, 'server idlerestart'),
(@id+4, 'server idlerestart cancel'),
(@id+5, 'server idleshutdown'),
(@id+6, 'server idleshutdown cancel'),
(@id+7, 'server info'),
(@id+8, 'server plimit'),
(@id+9, 'server restart'),
(@id+10, 'server restart cancel'),
(@id+11, 'server set'),
(@id+12, 'server set closed'),
(@id+13, 'server set difftime'),
(@id+14, 'server set loglevel'),
(@id+15, 'server set motd'),
(@id+16, 'server shutdown'),
(@id+17, 'server shutdown cancel'),
(@id+18, 'server motd');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+18;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+3),
(4, @id+4),
(4, @id+5),
(4, @id+6),
(4, @id+7),
(4, @id+8),
(4, @id+9),
(4, @id+10),
(4, @id+11),
(4, @id+12),
(4, @id+15),
(4, @id+16),
(4, @id+17),
(4, @id+18);
@@ -0,0 +1,21 @@
/* cs_tele.cpp */
SET @id = 737;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+4;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'tele'),
(@id+1, 'tele add'),
(@id+2, 'tele del'),
(@id+3, 'tele name'),
(@id+4, 'tele group');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+4;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(2, @id+0),
(4, @id+1),
(4, @id+2),
(2, @id+3),
(2, @id+4);
@@ -0,0 +1,49 @@
/* cs_ticket.cpp */
SET @id = 742;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+18;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'ticket'),
(@id+1, 'ticket assign'),
(@id+2, 'ticket close'),
(@id+3, 'ticket closedlist'),
(@id+4, 'ticket comment'),
(@id+5, 'ticket complete'),
(@id+6, 'ticket delete'),
(@id+7, 'ticket escalate'),
(@id+8, 'ticket escalatedlist'),
(@id+9, 'ticket list'),
(@id+10, 'ticket onlinelist'),
(@id+11, 'ticket reset'),
(@id+12, 'ticket response'),
(@id+13, 'ticket response append'),
(@id+14, 'ticket response appendln'),
(@id+15, 'ticket togglesystem'),
(@id+16, 'ticket unassign'),
(@id+17, 'ticket viewid'),
(@id+18, 'ticket viewname');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+18;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(2, @id+0),
(3, @id+1),
(2, @id+2),
(2, @id+3),
(2, @id+4),
(2, @id+5),
(4, @id+6),
(2, @id+7),
(3, @id+8),
(2, @id+9),
(2, @id+10),
(4, @id+11),
(2, @id+12),
(2, @id+13),
(2, @id+14),
(4, @id+15),
(3, @id+16),
(2, @id+17),
(2, @id+18);
@@ -0,0 +1,39 @@
/* cs_titles.cpp & cs_wp.cpp */
SET @id = 761;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+13;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'titles'),
(@id+1, 'titles add'),
(@id+2, 'titles current'),
(@id+3, 'titles remove'),
(@id+4, 'titles set'),
(@id+5, 'titles set mask'),
(@id+6, 'wp'),
(@id+7, 'wp add'),
(@id+8, 'wp event'),
(@id+9, 'wp load'),
(@id+10, 'wp modify'),
(@id+11, 'wp unload'),
(@id+12, 'wp reload'),
(@id+13, 'wp show');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+13;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(3, @id+0),
(3, @id+1),
(3, @id+2),
(3, @id+3),
(3, @id+4),
(3, @id+5),
(3, @id+6),
(3, @id+7),
(3, @id+8),
(3, @id+9),
(3, @id+10),
(3, @id+11),
(4, @id+12),
(3, @id+13);
@@ -0,0 +1,4 @@
-- Remove obsolete permissions
DELETE FROM `rbac_role_permissions` WHERE `permissionId` IN (7, 8, 9, 10, 12);
DELETE FROM `rbac_permissions` WHERE `id` IN (7, 8, 9, 10, 12);
@@ -0,0 +1,92 @@
/* account email */
SET @amail = 263;
-- Add new permissions for account mail
DELETE FROM `rbac_permissions` WHERE `id` = @amail;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@amail, 'account email');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` = @amail;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(1, @amail),
(2, @amail),
(3, @amail),
(4, @amail);
/* account set sec email
account set sec regmail */
SET @setsec = 264;
-- Add new permissions for account set sec
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @setsec AND @setsec+2;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@setsec+0, 'account set sec'),
(@setsec+1, 'account set sec email'),
(@setsec+2, 'account set sec regmail');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @setsec AND @setsec+2;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @setsec+0),
(4, @setsec+1),
(4, @setsec+2);
/* cs_cast.cpp */
SET @id = 267;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+5;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'cast'),
(@id+1, 'cast back'),
(@id+2, 'cast dist'),
(@id+3, 'cast self'),
(@id+4, 'cast target'),
(@id+5, 'cast dest');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+5;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(4, @id+0),
(4, @id+1),
(4, @id+2),
(4, @id+3),
(4, @id+4),
(4, @id+5);
/* cs_go.cpp */
SET @id = 377;
-- Add new permissions
DELETE FROM `rbac_permissions` WHERE `id` BETWEEN @id AND @id+9;
INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(@id+0, 'go'),
(@id+1, 'go creature'),
(@id+2, 'go graveyard'),
(@id+3, 'go grid'),
(@id+4, 'go object'),
(@id+5, 'go taxinode'),
(@id+6, 'go ticket'),
(@id+7, 'go trigger'),
(@id+8, 'go xyz'),
(@id+9, 'go zonexy');
-- Add permissions to "corresponding Commands Role"
DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN @id AND @id+9;
INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
(2, @id+0),
(2, @id+1),
(2, @id+2),
(2, @id+3),
(2, @id+4),
(2, @id+5),
(2, @id+6),
(2, @id+7),
(2, @id+8),
(2, @id+9);
UPDATE `rbac_permissions` SET `name`='bf enable' WHERE `id`=262;
@@ -1,16 +1,16 @@
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = 201 WHERE `name` = '.rbac account';
UPDATE `command` SET `permission` = 202 WHERE `name` = '.rbac account group';
UPDATE `command` SET `permission` = 203 WHERE `name` = '.rbac account group add';
UPDATE `command` SET `permission` = 204 WHERE `name` = '.rbac account group remove';
UPDATE `command` SET `permission` = 205 WHERE `name` = '.rbac account role';
UPDATE `command` SET `permission` = 206 WHERE `name` = '.rbac account role grant';
UPDATE `command` SET `permission` = 207 WHERE `name` = '.rbac account role deny';
UPDATE `command` SET `permission` = 208 WHERE `name` = '.rbac account role revoke';
UPDATE `command` SET `permission` = 209 WHERE `name` = '.rbac account permission';
UPDATE `command` SET `permission` = 210 WHERE `name` = '.rbac account permission grant';
UPDATE `command` SET `permission` = 211 WHERE `name` = '.rbac account permission deny';
UPDATE `command` SET `permission` = 212 WHERE `name` = '.rbac account permission revoke';
UPDATE `command` SET `permission` = 214 WHERE `name` = '.rbac account list groups';
UPDATE `command` SET `permission` = 215 WHERE `name` = '.rbac account list roles';
UPDATE `command` SET `permission` = 216 WHERE `name` = '.rbac account list permissions';
UPDATE `command` SET `permission` = 201 WHERE `name` = 'rbac account';
UPDATE `command` SET `permission` = 202 WHERE `name` = 'rbac account group';
UPDATE `command` SET `permission` = 203 WHERE `name` = 'rbac account group add';
UPDATE `command` SET `permission` = 204 WHERE `name` = 'rbac account group remove';
UPDATE `command` SET `permission` = 205 WHERE `name` = 'rbac account role';
UPDATE `command` SET `permission` = 206 WHERE `name` = 'rbac account role grant';
UPDATE `command` SET `permission` = 207 WHERE `name` = 'rbac account role deny';
UPDATE `command` SET `permission` = 208 WHERE `name` = 'rbac account role revoke';
UPDATE `command` SET `permission` = 209 WHERE `name` = 'rbac account permission';
UPDATE `command` SET `permission` = 210 WHERE `name` = 'rbac account permission grant';
UPDATE `command` SET `permission` = 211 WHERE `name` = 'rbac account permission deny';
UPDATE `command` SET `permission` = 212 WHERE `name` = 'rbac account permission revoke';
UPDATE `command` SET `permission` = 214 WHERE `name` = 'rbac account list groups';
UPDATE `command` SET `permission` = 215 WHERE `name` = 'rbac account list roles';
UPDATE `command` SET `permission` = 216 WHERE `name` = 'rbac account list permissions';
@@ -0,0 +1,52 @@
-- Putting Olakin Back Together Again (13220)
SET @QUEST := 13220;
SET @NPC_OLAKIN := 31235; -- Crusader Olakin Sainrith
SET @GO_CLEAVER := 193092; -- The Doctor's Cleaver
SET @GO_SPOOL := 193091; -- Spool of Thread
SET @EVENT_SCRIPT := 20269; -- Event from 58856 Reanimate Crusader Olakin
SET @SPELL_FD := 35356; -- Feign Death
SET @SPELL_FAKE_BLOOD := 37692; -- Fake Blood Spurt
SET @SPELL_RESURRECTION := 58854; -- Resurrection
DELETE FROM `gameobject` WHERE `id` IN (@GO_CLEAVER,@GO_SPOOL);
INSERT INTO `gameobject` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`rotation0`,`rotation1`,`rotation2`,`rotation3`,`spawntimesecs`,`animprogress`,`state`) VALUES
(16974,@GO_SPOOL,571,1,1,6668.17,3268.54,669.539,2.54818,0,0,0.956304,0.292373,120,255, 1),
(16976,@GO_CLEAVER,571,1,1,6601.1,3147.78,666.916,-2.77507,0,0,-0.983254,0.182238,120,255,1);
DELETE FROM `event_scripts` WHERE `id`=@EVENT_SCRIPT;
INSERT INTO `event_scripts` (`id`,`delay`,`command`,`datalong`,`datalong2`,`dataint`,`x`,`y`,`z`,`o`) VALUES
(@EVENT_SCRIPT,0,10,@NPC_OLAKIN,60000,0,6636.792,3211.102,668.6439,0.8901179);
DELETE FROM `creature_template_addon` WHERE `entry`=@NPC_OLAKIN;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`auras`) VALUES
(@NPC_OLAKIN,0,0x0,0x1,'35356'); -- 31235 - 35356
DELETE FROM `creature_text` WHERE `entry`=@NPC_OLAKIN;
INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`) VALUES
(@NPC_OLAKIN,0,0,'Thank the Light for granting me another chance. And thank you, $N.',12,0,100,1,0,0,'Crusader Olakin Sainrith'),
(@NPC_OLAKIN,1,0,'Without your help, I would''ve been doomed to a life of undeath among the Lich King''s gruesome creations.', 12,0,100,1,0,0,'Crusader Olakin Sainrith'),
(@NPC_OLAKIN,2,0,'There will be time for a proper thanks later, but there is still a battle to be fought!', 12,0,100,25,0,0,'Crusader Olakin Sainrith');
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@NPC_OLAKIN;
DELETE FROM `smart_scripts` WHERE (`source_type`=0 AND `entryorguid`=@NPC_OLAKIN) OR (`source_type`=9 AND `entryorguid`=@NPC_OLAKIN*100);
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@NPC_OLAKIN,0,0,0,54,0,100,0,0,0,0,0,80,@NPC_OLAKIN*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Just summoned - Run Script'),
(@NPC_OLAKIN,0,1,0,40,0,100,0,3,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On WP Reached - Despawn'),
-- 17,26
(@NPC_OLAKIN*100,9,0,0,0,0,100,0,2000,2000,0,0,11,@SPELL_FAKE_BLOOD,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Cast Spell'),
(@NPC_OLAKIN*100,9,1,0,0,0,100,0,2000,2000,0,0,11,@SPELL_RESURRECTION,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Cast Spell'),
(@NPC_OLAKIN*100,9,2,0,0,0,100,0,0,0,0,0,28,@SPELL_FD,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Remove Aura'),
(@NPC_OLAKIN*100,9,3,0,0,0,100,0,0,0,0,0,96,32,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Remove dynamic flag'),
(@NPC_OLAKIN*100,9,4,0,0,0,100,0,1000,1000,0,0,19,1,1,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Remove Unit Flag_2 1 {dead)'),
(@NPC_OLAKIN*100,9,5,0,0,0,100,0,4000,4000,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Say 0'),
(@NPC_OLAKIN*100,9,6,0,0,0,100,0,4000,4000,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Say 1'),
(@NPC_OLAKIN*100,9,7,0,0,0,100,0,4000,4000,0,0,1,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Say 2'),
(@NPC_OLAKIN*100,9,8,0,0,0,100,0,3000,3000,0,0,33,@NPC_OLAKIN,0,0,0,0,0,17,0,30,0,0,0,0,0,'Crusader Olakin Sainrith - On Script - Quest Credit'),
(@NPC_OLAKIN*100,9,9,0,0,0,100,0,0,0,0,0,53,1,@NPC_OLAKIN,0,0,0,0,1,0,0,0,0,0,0,0,'Crusader Olakin Sainrith - On Script -Start WP movement');
DELETE FROM `waypoints` WHERE entry =@NPC_OLAKIN;
INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES
(@NPC_OLAKIN, 1, 6632.227, 3223.6350, 666.7750,'Olakin'),
(@NPC_OLAKIN, 2, 6624.2558, 3230.2343, 666.857, 'Olakin'),
(@NPC_OLAKIN, 3, 6608.985, 3234.5588, 668.779, 'Olakin');
@@ -0,0 +1,41 @@
-- A Cleansing Song (12735)
SET @KOOSU := 29034;
SET @HA_KHALAN := 29018;
SET @ATHA := 29033;
-- Spirit of Koosu
DELETE FROM `creature_ai_scripts` WHERE `creature_id`=@KOOSU;
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@KOOSU;
DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@KOOSU;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@KOOSU,0,0,0,4,0,100,1,0,0,0,0,22,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Koosu - Set Phase 1 - on Aggro'),
(@KOOSU,0,1,0,4,1,100,1,0,0,0,0,21,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Koosu - Stop Moving - on Aggro'),
(@KOOSU,0,2,0,4,1,100,1,0,0,0,0,11,21971,0,0,0,0,0,2,0,0,0,0,0,0,0,'Spirit of Koosu - Cast bolt - on Aggro'),
(@KOOSU,0,3,0,9,1,100,0,5,30,3500,4100,11,21971,0,0,0,0,0,2,0,0,0,0,0,0,0,'Spirit of Koosu - Cast bolt - In Range'),
(@KOOSU,0,4,0,9,1,100,0,30,100,0,0,21,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Koosu - Start Moving - When not in bolt Range'),
(@KOOSU,0,5,0,9,1,100,0,9,15,0,0,21,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Koosu - Stop Moving - 15 Yards'),
(@KOOSU,0,6,0,9,1,100,0,0,5,0,0,21,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Koosu - Start Moving - when not in bolt Range'),
(@KOOSU,0,7,0,9,1,100,0,5,30,0,0,21,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Koosu - Stop Moving - when in bolt Range');
-- Spirit of Ha-Khalan
DELETE FROM `creature_ai_scripts` WHERE `creature_id`=@HA_KHALAN;
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@HA_KHALAN;
DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@HA_KHALAN;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@HA_KHALAN,0,0,0,0,0,100,0,1000,1000,125000,125000,11,50502,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Ha-Khalan - IC - Cast Thick Hide'),
(@HA_KHALAN,0,1,0,0,0,100,0,5000,10000,12000,16000,11,34370,0,0,0,0,0,2,0,0,0,0,0,0,0,'Spirit of Ha-Khalan - IC - Cast Jagged Tooth Snap'),
(@HA_KHALAN,0,2,0,0,0,100,0,3000,5000,7000,11000,11,48287,0,0,0,0,0,2,0,0,0,0,0,0,0,'Spirit of Ha-Khalan - IC - Cast Powerful Bite');
-- Spirit of Atha
DELETE FROM `creature_ai_scripts` WHERE `creature_id`=@ATHA;
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@ATHA;
DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@ATHA;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@ATHA,0,0,0,0,0,100,0,8000,13000,12000,16000,11,21790,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Atha - IC - Cast Aqua Jet'),
(@ATHA,0,1,0,0,0,100,0,2000,4000,5000,7000,11,3391,0,0,0,0,0,1,0,0,0,0,0,0,0,'Spirit of Atha - IC - Cast Thrash');
UPDATE `creature_template` SET `unit_flags`=`unit_flags`|8 WHERE `entry`=29018; -- Spirit of Ha-Khalan
-- Addon data for creature 29018 (Spirit of Ha-Khalan)
DELETE FROM `creature_template_addon` WHERE `entry`=29018;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(29018,0,0,1,0,''); -- Spirit of Ha-Khalan
@@ -0,0 +1,38 @@
-- Corpulen Horror spawns in area The Fleshwerks
SET @CGUID = 127272;
DELETE FROM `creature_ai_scripts` WHERE `creature_id`=30696;
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=30696;
DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=30696;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(30696,0,0,0,9,0,100,0,8,40,3500,4100,11,50335,0,0,0,0,0,2,0,0,0,0,0,0,0,'Corpulent Horror - Cast Scourge Hook - In Range');
DELETE FROM `creature_template_addon` WHERE `entry`=30696;
INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES
(30696, 0, 0x0, 0x1, ''); -- Corpulent Horror
UPDATE `creature_template` SET `faction_A`=2102, `faction_H`=2102, `speed_walk`=1.142857, `speed_run`=1, `rangeattacktime`=2000, `unit_flags`=32768, `dynamicflags`=0 WHERE `entry`=30696; -- Corpulent Horror
DELETE FROM `creature` WHERE `id` = 30696;
INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`) VALUES
(@CGUID+0, 30696, 571, 1, 1, 0, 0, 6975.386, 3462.006, 710.9403, 6.126106, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+1, 30696, 571, 1, 1, 0, 0, 6982.377, 3478.588, 710.9403, 5.811946, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+2, 30696, 571, 1, 1, 0, 0, 6920.697, 3446.544, 710.2005, 3.097477, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+3, 30696, 571, 1, 1, 0, 0, 6932.927, 3502.471, 705.0461, 3.281219, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+4, 30696, 571, 1, 1, 0, 0, 6903.668, 3478.428, 700.0414, 3.093731, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+5, 30696, 571, 1, 1, 0, 0, 6895.87, 3460.794, 700.7824, 1.592374, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+6, 30696, 571, 1, 1, 0, 0, 6868.874, 3435.562, 705.6059, 1.542484, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+7, 30696, 571, 1, 1, 0, 0, 6869.054, 3493.792, 695.7783, 5.440073, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+8, 30696, 571, 1, 1, 0, 0, 6875.154, 3513.065, 698.8162, 3.944444, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+9, 30696, 571, 1, 1, 0, 0, 6836.296, 3505.824, 690.3577, 0.5061455, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+10, 30696, 571, 1, 1, 0, 0, 6823.636, 3484.259, 688.4615, 6.278303, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+11, 30696, 571, 1, 1, 0, 0, 6729.185, 3433.822, 682.3103, 2.64319, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+12, 30696, 571, 1, 1, 0, 0, 6676.063, 3349.062, 704.616, 2.582512, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+13, 30696, 571, 1, 1, 0, 0, 6699.958, 3422.957, 679.4948, 3.363122, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+14, 30696, 571, 1, 1, 0, 0, 6548.099, 3309.558, 665.8171, 2.951326, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+15, 30696, 571, 1, 1, 0, 0, 6535.431, 3322.088, 664.9422, 5.877358, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+16, 30696, 571, 1, 1, 0, 0, 6530.748, 3296.081, 664.9409, 3.446935, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+17, 30696, 571, 1, 1, 0, 0, 6534.971, 3260.271, 666.9742, 0.2021571, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+18, 30696, 571, 1, 1, 0, 0, 6477.204, 3257.901, 643.6331, 3.804818, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+19, 30696, 571, 1, 1, 0, 0, 6488.242, 3194.719, 652.9039, 1.48353, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks)
(@CGUID+20, 30696, 571, 1, 1, 0, 0, 6412.273, 3236.912, 640.3326, 0.7460284, 120, 0, 0, 0, 0, 0, 0, 0, 0), -- Corpulent Horror (Area: The Fleshwerks
(@CGUID+21, 30696, 571, 1, 1, 0, 0, 6413.427, 3218.029, 638.4678, 0.122173, 120, 0, 0, 0, 0, 0, 0, 0, 0); -- Corpulent Horror (Area: The Fleshwerks)
@@ -0,0 +1,26 @@
DELETE FROM `spell_linked_spell` WHERE `spell_trigger` IN (66548,66549,66550,66551);
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry` IN (66550,66551);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES
(13,1,66550,0,0,31,0,3,22515,0,0,0,0,'','Isle of Conquest - Teleport Fortress Out'),
(13,1,66550,0,0,35,0,1,10,1,0,0,0,'','Isle of Conquest - Teleport Fortress Out'),
(13,1,66551,0,0,31,0,3,22515,0,0,0,0,'','Isle of Conquest - Teleport Fortress In'),
(13,1,66551,0,0,35,0,1,10,1,0,0,0,'','Isle of Conquest - Teleport Fortress In');
SET @CGUID := 90179;
DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+13;
INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `MovementType`) VALUES
(@CGUID+0, 22515, 628, 3, 1, 392.4965, -859.4583, 48.99871, 3.036873, 7200, 0, 0), -- A IN
(@CGUID+1, 22515, 628, 3, 1, 313.2344, -918.0452, 48.85597, 4.869469, 7200, 0, 0), -- A OUT
(@CGUID+2, 22515, 628, 3, 1, 279.8698, -832.8073, 51.55094, 0, 7200, 0, 0), -- A CENTER
(@CGUID+3, 22515, 628, 3, 1, 323.4965, -883.8021, 48.99959, 1.466077, 7200, 0, 0), -- A IN
(@CGUID+4, 22515, 628, 3, 1, 430.6007, -857.0052, 48.31177, 0.1396263, 7200, 0, 0), -- A OUT
(@CGUID+5, 22515, 628, 3, 1, 325.9167, -781.8993, 49.00521, 4.590216, 7200, 0, 0), -- A IN
(@CGUID+6, 22515, 628, 3, 1, 326.2135, -744.0243, 49.43576, 1.308997, 7200, 0, 0), -- A OUT
(@CGUID+7, 22515, 628, 3, 1, 1139.498, -779.4739, 48.73496, 3.001966, 7200, 0, 0), -- H OUT
(@CGUID+8, 22515, 628, 3, 1, 1162.913, -745.908, 48.71506, 0.1396263, 7200, 0, 0), -- H IN
(@CGUID+9, 22515, 628, 3, 1, 1234.304, -688.2986, 49.22296, 4.677482, 7200, 0, 0), -- H IN
(@CGUID+10, 22515, 628, 3, 1, 1232.524, -666.3246, 48.13402, 2.303835, 7200, 0, 0), -- H OUT
(@CGUID+11, 22515, 628, 3, 1, 1233.106, -838.316, 48.99958, 1.466077, 7200, 0, 0), -- H IN
(@CGUID+12, 22515, 628, 3, 1, 1232.387, -861.0243, 48.99959, 3.560472, 7200, 0, 0), -- H OUT
(@CGUID+13, 22515, 628, 3, 1, 1296.526, -766.1823, 50.70293, 3.089233, 7200, 0, 0); -- H CENTER
@@ -0,0 +1,4 @@
-- Fix few startup errors
UPDATE `smart_scripts` SET `event_param3`=12555 WHERE `entryorguid`=27727 AND `source_type`=0 AND `id`=2 AND `link`=0;
DELETE FROM `creature_addon` WHERE `guid`=66177;
DELETE FROM `waypoint_data` WHERE `id`=661770;
@@ -0,0 +1,13 @@
DELETE FROM `smart_scripts` WHERE `entryorguid`=28481 AND `source_type`=0;
UPDATE `creature_template` SET `AIName`='' WHERE `entry`=28481;
DELETE FROM `spell_script_names` WHERE `spell_id` IN (51769,51770,58941);
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(51769,'spell_q12619_emblazon_runeblade'),
(51770,'spell_q12619_emblazon_runeblade_effect'),
(58941,'spell_archavon_rock_shards');
DELETE FROM `spelldifficulty_dbc` WHERE `id` IN (58695,58696);
INSERT INTO `spelldifficulty_dbc`(`id`,`spellid0`,`spellid1`) VALUES
(58695,58695,60883),
(58696,58696,60884);
@@ -0,0 +1,4 @@
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=28481;
DELETE FROM `smart_scripts` WHERE `entryorguid`=28481 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(28481, 0, 0, 0, 8, 0, 100, 0, 51769, 0, 0, 0, 11, 51738, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Runeforge (SE) - On Spellhit Emblazon Runeblade - Cast Shadow Storm');
@@ -0,0 +1,6 @@
-- Scourge Tactics
UPDATE `smart_scripts` SET `link`=1 WHERE `entryorguid`=30273 AND `id`=0;
UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=30273 AND `id`=1;
-- Abjurist Belmara & Conjurer Luminrath
UPDATE `smart_scripts` SET `target_type`=7 WHERE `entryorguid`=19546 AND `id`=2;
UPDATE `smart_scripts` SET `target_type`=7, `target_param1`=0 WHERE `entryorguid`=19580 AND `id`=2;
@@ -0,0 +1,4 @@
-- Do not delete query id 0
DELETE FROM `smart_scripts` WHERE `entryorguid` =21797 AND `source_type`=0 AND `id`>0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(21797, 0, 1, 0, 19, 0, 100, 0, 10645, 0, 0, 0, 80, 2179700, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Ancient Shadowmoon Spirit - On Quest Accept - Run Script');
@@ -0,0 +1,68 @@
-- Trapping the Light Fantastic (10674) & Gather the Orbs (10859)
SET @GOB_TRAP := 185011; -- Multi-Spectrum Light Trap
SET @NPC_BUNNY := 21926; -- Multi-Spectrum Light Trap Bunny
SET @ORB_TOTEM := 22333; -- Orb Collecting Totem
SET @NPC_CREDIT := 21929; -- Trapping the Light Kill Credit Trigger
SET @NPC_ORB1 := 20635; -- Razaani Light Orb
SET @NPC_ORB2 := 20771; -- Razaani Light Orb - Mini
SET @SPELL_PULL := 28337; -- Magnetic Pull
SET @ARC_EXPLOSION := 35426; -- Arcane Explosion
DELETE FROM `creature_template_addon` WHERE `entry` IN (@NPC_ORB1,@NPC_ORB2);
INSERT INTO `creature_template_addon` (`entry`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(20635,0,0,0,4097,0,'32566'),
(20771,0,0,0,4097,0,'32566');
UPDATE `creature_template` SET `AIName`='SmartAI',`unit_flags`=unit_flags|0x02000000,`flags_extra`=130,`ScriptName`='' WHERE `entry` IN (@NPC_ORB1,@NPC_ORB2);
DELETE FROM `creature_ai_scripts` WHERE `creature_id` IN (@NPC_ORB1,@NPC_ORB2);
UPDATE `creature` SET `MovementType`=0 WHERE `id`=@NPC_ORB1;
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_ORB1,@NPC_ORB1*100,@NPC_ORB1*101,@NPC_ORB2,@NPC_ORB2*100,@NPC_ORB2*101) AND `source_type` IN (0,9);
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
-- Alliance Version
(@NPC_ORB1,0,0,0,8,0,100,0,@SPELL_PULL,0,0,0,80,@NPC_ORB1*100,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Orb Bunny - On Spellhit - Start Action Script'),
(@NPC_ORB1*100,9,0,0,0,0,100,0,1000,1000,0,0,11,@ARC_EXPLOSION,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Orb Bunny - On Script - Cast Arcane Explosion'),
(@NPC_ORB1*100,9,1,0,0,0,100,0,500,500,0,0,45,1,1,0,0,0,0,19,@NPC_BUNNY,5,0,0,0,0,0, 'Orb Bunny - On Script - Cast Arcane Explosion'),
(@NPC_ORB1*100,9,2,0,0,0,100,0,0,0,0,0,41,100,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Orb Bunny - On Script - Despawn'),
-- Horde Version
(@NPC_ORB1,0,1,0,38,0,100,0,0,1,30000,30000,69,1,0,0,0,0,0,19,@ORB_TOTEM,20,0,0,0,0,0, 'Light Orb - On Data Set 0 1 - Move to totem'),
(@NPC_ORB1,0,2,3,34,0,100,1,8,1,0,0,11,@ARC_EXPLOSION,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - On point 1 reached - Cast arcane explosion'),
(@NPC_ORB1,0,3,4,61,0,100,0,0,0,0,0,33,@NPC_CREDIT,0,0,0,0,0,12,1,0,0,0,0,0,0, 'Light Orb - On Link - Call kill credit'),
(@NPC_ORB1,0,4,0,61,0,100,0,0,0,0,0,80,@NPC_ORB1*101,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - On Link - Start action list to display arcase explosion'),
(@NPC_ORB1*101,9,0,0,0,0,100,0,0,0,0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - Action 0 - Set unseen'),
(@NPC_ORB1*101,9,1,0,0,0,100,0,0,0,0,0,41,100,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - Action 1 - Despawn in 100 ms'),
-- Alliance Version
(@NPC_ORB2,0,0,0,8,0,100,0,@SPELL_PULL,0,0,0,80,@NPC_ORB2*100,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Orb Bunny - On Spellhit - Start Action Script'),
(@NPC_ORB2*100,9,0,0,0,0,100,0,1000,1000,0,0,11,@ARC_EXPLOSION,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Orb Bunny - On Script - Cast Arcane Explosion'),
(@NPC_ORB2*100,9,1,0,0,0,100,0,500,500,0,0,45,1,1,0,0,0,0,19,@NPC_BUNNY,5,0,0,0,0,0, 'Orb Bunny - On Script - Cast Arcane Explosion'),
(@NPC_ORB2*100,9,2,0,0,0,100,0,0,0,0,0,41,100,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Orb Bunny - On Script - Despawn'),
-- Horde Version
(@NPC_ORB2,0,1,0,38,0,100,0,1,1,30000,30000,69,1,0,0,0,0,0,19,@ORB_TOTEM,20,0,0,0,0,0, 'Light Orb - On Data Set 0 1 - Move to totem'),
(@NPC_ORB2,0,2,3,34,0,100,1,8,1,0,0,11,@ARC_EXPLOSION,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - On point 1 reached - Cast arcane explosion'),
(@NPC_ORB2,0,3,4,61,0,100,0,0,0,0,0,33,@NPC_CREDIT,0,0,0,0,0,12,1,0,0,0,0,0,0, 'Light Orb - On Link - Call kill credit'),
(@NPC_ORB2,0,4,0,61,0,100,0,0,0,0,0,80,@NPC_ORB2*101,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - On Link - Start action list to display arcase explosion'),
(@NPC_ORB2*101,9,0,0,0,0,100,0,0,0,0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - Action 0 - Set unseen'),
(@NPC_ORB2*101,9,1,0,0,0,100,0,0,0,0,0,41,100,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Light Orb - Action 1 - Despawn in 100 ms');
-- Alliance Multi-Spectrum Light Trap
UPDATE `creature_template` SET `AIName`='SmartAI',`flags_extra`=130,`ScriptName`='' WHERE `entry`=@NPC_BUNNY;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_BUNNY;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@NPC_BUNNY,0,0,0,54,0,100,1,0,0,0,0,50,@GOB_TRAP,30000,0,0,0,0,1,0,0,0,0,0,0,0, 'Multi-Spectrum Light Trap - On spawn - Summon gob'),
(@NPC_BUNNY,0,1,0,1,0,100,1,0,0,0,0,9,0,0,0,0,0,0,15,@GOB_TRAP,0,0,0,0,0,0, 'Multi-Spectrum Light Trap - OOC - Activate gob'),
--
(@NPC_BUNNY,0,2,0,1,0,100,1,3000,3000,3000,3000,11,@SPELL_PULL,0,0,0,0,0,19,@NPC_ORB1,20,0,0,0,0,0, 'Multi-Spectrum Light Trap - OOC 3 sec - Pull Razaani Light Orb'),
(@NPC_BUNNY,0,3,0,1,0,100,1,3000,3000,3000,3000,11,@SPELL_PULL,0,0,0,0,0,19,@NPC_ORB2,20,0,0,0,0,0, 'Multi-Spectrum Light Trap - OOC 3 sec - Pull Razaani Light Orb - Mini'),
(@NPC_BUNNY,0,4,5,38,0,100,1,1,1,0,0,33,@NPC_CREDIT,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Multi-Spectrum Light Trap - On Data Set - Give Quest Credit'),
(@NPC_BUNNY,0,5,0,61,0,100,1,0,0,0,0,9,0,0,0,0,0,0,15,@GOB_TRAP,0,0,0,0,0,0, 'Link - Activate gob - Gob');
-- Horde Totem
UPDATE `creature_template` SET `AIName`='SmartAI',`flags_extra`=0,`ScriptName`='' WHERE `entry`=@ORB_TOTEM;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@ORB_TOTEM;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@ORB_TOTEM,0,0,1,54,0,100,0,0,0,0,0,45,0,1,0,0,0,0,19,@NPC_ORB1,20,0,0,0,0,0, 'Orb collecting totem - On spawned - Set Data 0 1'),
(@ORB_TOTEM,0,1,2,61,0,100,0,0,0,0,0,64,1,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Orb collecting totem - On Link - Store invoker'),
(@ORB_TOTEM,0,2,0,61,0,100,0,0,0,0,0,100,1,0,0,0,0,0,19,@NPC_ORB1,20,0,0,0,0,0, 'Orb collecting totem - On Link - Send stored target list 1'),
--
(@ORB_TOTEM,0,3,4,54,0,100,0,0,0,0,0,45,1,1,0,0,0,0,19,@NPC_ORB2,20,0,0,0,0,0, 'Orb collecting totem - On spawned - Set Data 0 1'),
(@ORB_TOTEM,0,4,5,61,0,100,0,0,0,0,0,64,1,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Orb collecting totem - On Link - Store invoker'),
(@ORB_TOTEM,0,5,0,61,0,100,0,0,0,0,0,100,1,0,0,0,0,0,19,@NPC_ORB2,20,0,0,0,0,0, 'Orb collecting totem - On Link - Send stored target list 1');
@@ -0,0 +1,2 @@
-- -.- >.> <.< -_- ._.
UPDATE `creature` SET `spawndist`=0 WHERE`id`=20635;
@@ -0,0 +1,15 @@
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN (30135,30144,29974);
DELETE FROM `smart_scripts` WHERE entryorguid IN (30135,30144,29974);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
-- Niffelem Forefather
(29974, 0, 0, 0, 0, 0, 100, 0, 1000, 5000, 8000, 13000, 11, 57454, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Niffelem Forefather - IC - Cast Ice Spike'),
(29974, 0, 1, 2, 8, 0, 100, 0, 55983, 0, 0, 0, 33, 30138, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Niffelem Forefather - On Spellhit - Give Kill Credit'),
(29974, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Niffelem Forefather - Linked with Previous Event Despawn'),
-- Restless Frostborn Warrior
(30135, 0, 0, 0, 0, 0, 100, 0, 1000, 5000, 8000, 13000, 11, 57456, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Restless Frostborn Warrior - IC - Cast Frostbite'),
(30135, 0, 1, 2, 8, 0, 100, 0, 55983, 0, 0, 0, 33, 30139, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Restless Frostborn Warrior - On Spellhit - Give Kill Credit'),
(30135, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Restless Frostborn Warrior - Linked with Previous Event Despawn'),
-- Restless Frostborn Ghost
(30144, 0, 0, 0, 0, 0, 100, 0, 1000, 5000, 8000, 13000, 11, 57456, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Restless Frostborn Ghost - IC - Cast Frostbite'),
(30144, 0, 1, 2, 8, 0, 100, 0, 55983, 0, 0, 0, 33, 30139, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Restless Frostborn Ghost - On Spellhit - Give Kill Credit'),
(30144, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Restless Frostborn Ghost - Linked with Previous Event Despawn');
@@ -0,0 +1,8 @@
DELETE FROM `conditions` WHERE `SourceEntry` = 55983;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(17, 0, 55983, 0, 0, 31, 1, 3, 29974, 0, 0, 0, 0, '', 'Blow Hodir''s Horn can hit Niffelem Forefather'),
(17, 0, 55983, 0, 0, 36, 1, 0, 0, 0, 1, 0, 0, '', 'Blow Hodir''s Horn can only hit dead Niffelem Forefather'),
(17, 0, 55983, 0, 1, 31, 1, 3, 30144, 0, 0, 0, 0, '', 'Blow Hodir''s Horn can hit Restless Frostborn Ghost'),
(17, 0, 55983, 0, 1, 36, 1, 0, 0, 0, 1, 0, 0, '', 'Blow Hodir''s Horn can only hit dead Restless Frostborn Ghost'),
(17, 0, 55983, 0, 2, 31, 1, 3, 30135, 0, 0, 0, 0, '', 'Blow Hodir''s Horn can hit Restless Frostborn Warrior'),
(17, 0, 55983, 0, 2, 36, 1, 0, 0, 0, 1, 0, 0, '', 'Blow Hodir''s Horn can only hit dead Restless Frostborn Warrior');
@@ -0,0 +1,15 @@
/* cs_group.cpp */
SET @id = 472;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'group';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'group leader';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'group disband';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'group remove';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'group join';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'group list';
UPDATE `command` SET `permission` = @id+6, `name` = 'group summon', `help` =
'Syntax: .group summon [$charactername]\r\n\r\nTeleport the given character and his group to you. Teleported only online characters but original selected group member can be offline.'
WHERE `name` = 'groupsummon';
@@ -0,0 +1,9 @@
/* cs_pet.cpp */
SET @id = 479;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'pet';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'pet create';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'pet learn';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'pet unlearn';
@@ -0,0 +1,136 @@
-- Test Flight Quests
-- 10557 - The Zephyrium Capacitorium(part 1)
-- 10710 - The Singing Ridge(part 2)
-- 10711 - Razaan's Landing
-- 10712 - Ruuan Weald
SET @ENTRY := 21461; -- Rally Zapnabber
SET @ENTRY2 := 21393; -- Cannon Channeler Dummy npc
SET @BEAM := 36795; -- Cannon Channel(dnd) - Visual cannon beam
SET @MENUID := 8304; -- Gossip
SET @A_MENU := 8454; -- Action Gossip
SET @A_MENU2 := 8455; -- Action Gossip 2
SET @OPTION := 0;
SET @SPEACH := 10360; -- Text 1
SET @SPEACH2 := 10561; -- Text 2
-- Disable obsolete quest
DELETE FROM `disables` WHERE `entry`=10716;
INSERT INTO `disables` (`sourceType`, `entry`, `flags`, `params_0`, `params_1`, `comment`) VALUES
(1,10716,0,'','','Deprecated quest Test Flight: Raven''s Wood');
-- Make Canon Channeler float & Update position to match cannon
UPDATE `creature_template` SET `InhabitType`=4, `modelid1`= 11686 ,`modelid2`=0 WHERE `entry`=@ENTRY2;
UPDATE `creature` SET `position_x`=1924.6457, `position_y`= 5575.660, `position_z`=272.1429 WHERE `guid`=74872;-- Gossip & menus 1924.1457, 5575.647, 272.1429
UPDATE `creature_template` SET `gossip_menu_id`=@MENUID, `AIName`= 'SmartAI' WHERE `entry`=@ENTRY;
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=@ENTRY2;
DELETE FROM `gossip_menu` WHERE `entry` IN (@MENUID,@A_MENU);
INSERT INTO `gossip_menu` (`entry`,`text_id`) VALUES
(@MENUID,@SPEACH),
(@A_MENU,@SPEACH2);
DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (@MENUID,@A_MENU2,@A_MENU);
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`) VALUES
(@MENUID,@OPTION+0,0,'I''m ready for my test flight!',1,1,0,0,0,0,''), -- Test Flight: The Zephyrium Capacitorium
(@MENUID,@OPTION+1,0,'Take me to Singing Ridge!',1,1,@A_MENU,0,0,0,''), -- Test Flight: The Singing Ridge
(@MENUID,@OPTION+2,0,'Take me to Razaan''s Landing!',1,1,0,0,0,0,''), -- Test Flight: Razaan's Landing
(@MENUID,@OPTION+3,0,'Take me to Ruuan Weald!',1,1,0,0,0,0,''), -- Test Flight: Ruuan Weald
(@MENUID,@OPTION+4,0,'I want to fly to an old location!',1,1,@A_MENU2,0,0,0,''), -- Old locations from completed quests
(@A_MENU2,@OPTION+1,0,'Take me to Singing Ridge.',1,1,0,0,0,0,''),
(@A_MENU2,@OPTION+2,0,'Take me to Razaan''s Landing.',1,1,0,0,0,0,''),
(@A_MENU2,@OPTION+3,0,'Take me to Ruuan Weald.',1,1,0,0,0,0,''),
(@A_MENU,@OPTION+0,0,'I have the signed Waiver! Fire me into The Singing Ridge!',1,1,0,0,0,0,'');
-- Fix teleport spell position
DELETE FROM `spell_target_position` WHERE `Id` IN(37908,24831);
INSERT INTO `spell_target_position` (`id`, `effIndex`, `target_map`, `target_position_x`, `target_position_y`, `target_position_z`, `target_orientation`) VALUES
(24831, 0, 530, 1920.07, 5582.04, 269.222, 5.1846);
DELETE FROM `spell_linked_spell` WHERE `spell_trigger`= 37908;
INSERT INTO `spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comment`) VALUES
(37908, 24831, 0, 'Aura Visual Teleport - teleport');
-- SAI
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@ENTRY,@ENTRY*100,@ENTRY*101,@ENTRY*102,@ENTRY*103,@ENTRY2);
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@ENTRY,0,0,1,62,0,100,0,@MENUID,@OPTION+0,0,0,80,@ENTRY*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
(@ENTRY,0,2,3,62,0,100,0,@A_MENU,@OPTION+0,0,0,80,@ENTRY*101,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,3,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
(@ENTRY,0,4,5,62,0,100,0,@MENUID,@OPTION+2,0,0,80,@ENTRY*102,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,5,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
(@ENTRY,0,6,7,62,0,100,0,@MENUID,@OPTION+3,0,0,80,@ENTRY*103,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,7,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
(@ENTRY,0,8,9,62,0,100,0,@A_MENU2,@OPTION+1,0,0,80,@ENTRY*101,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,9,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
(@ENTRY,0,10,11,62,0,100,0,@A_MENU2,@OPTION+2,0,0,80,@ENTRY*102,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,11,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
(@ENTRY,0,12,13,62,0,100,0,@A_MENU2,@OPTION+3,0,0,80,@ENTRY*103,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Run script'),
(@ENTRY,0,13,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip'),
--
(@ENTRY*100,9,0,0,1,0,100,0,2000,2000,2000,2000,85,37908,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Zephyrium Capacitorium - After 2 seconds - Port visual'),
(@ENTRY*100,9,1,0,1,0,100,0,2000,2000,2000,2000,45,1,1,0,0,0,0,10,74872,@ENTRY2,0,0,0,0,0,'The Zephyrium Capacitorium - After 2 seconds - Port visual'),
(@ENTRY*100,9,2,0,1,0,100,0,3000,3000,3000,3000,85,36790,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Zephyrium Capacitorium - OOC Update - Invoker,cast charge state 2'),
(@ENTRY*100,9,3,0,1,0,100,0,3000,3000,3000,3000,85,36792,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Zephyrium Capacitorium - OOC Update - Invoker,cast charge state 3'),
(@ENTRY*100,9,4,0,1,0,100,0,3000,3000,3000,3000,85,36800,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Zephyrium Capacitorium - OOC Update - Invoker,cast charge state 4'),
(@ENTRY*100,9,5,0,1,0,100,0,3000,3000,3000,3000,85,37910,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Zephyrium Capacitorium - OOC Update - Invoker,cast Soar&Credit'),
(@ENTRY*100,9,6,0,1,0,100,0,0,0,0,0,85,37108,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Zephyrium Capacitorium - OOC Update - Invoker,cast Debuff'),
--
(@ENTRY*101,9,0,0,1,0,100,0,2000,2000,2000,2000,85,37908,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Singing Ridge - After 2 seconds - Port visual'),
(@ENTRY*101,9,1,0,1,0,100,0,2000,2000,2000,2000,45,1,1,0,0,0,0,10,74872,@ENTRY2,0,0,0,0,0,'The Zephyrium Capacitorium - After 2 seconds - Set Data on Channeler'),
(@ENTRY*101,9,2,0,1,0,100,0,3000,3000,3000,3000,85,36790,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Singing Ridge - OOC Update - Invoker,cast charge state 2'),
(@ENTRY*101,9,3,0,1,0,100,0,3000,3000,3000,3000,85,36792,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Singing Ridge - OOC Update - Invoker,cast charge state 3'),
(@ENTRY*101,9,4,0,1,0,100,0,3000,3000,3000,3000,85,36800,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Singing Ridge - OOC Update - Invoker,cast charge state 4'),
(@ENTRY*101,9,5,0,1,0,100,0,3000,3000,3000,3000,85,37962,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Singing Ridge - OOC Update - Invoker,cast Soar&Credit'),
(@ENTRY*101,9,6,0,1,0,100,0,0,0,0,0,85,37108,0,0,0,0,0,7,0,0,0,0,0,0,0,'The Singing Ridge - OOC Update - Invoker,cast Debuff'),
--
(@ENTRY*102,9,0,0,1,0,100,0,2000,2000,2000,2000,85,37908,0,0,0,0,0,7,0,0,0,0,0,0,0,'Razaan''s Landing - After 2 seconds - Port visual'),
(@ENTRY*102,9,1,0,1,0,100,0,2000,2000,2000,2000,45,1,1,0,0,0,0,10,74872,@ENTRY2,0,0,0,0,0,'The Zephyrium Capacitorium - After 2 seconds - Set Data on Channeler'),
(@ENTRY*102,9,2,0,1,0,100,0,3000,3000,3000,3000,85,36790,0,0,0,0,0,7,0,0,0,0,0,0,0,'Razaan''s Landing - OOC Update - Invoker,cast charge state 2'),
(@ENTRY*102,9,3,0,1,0,100,0,3000,3000,3000,3000,85,36792,0,0,0,0,0,7,0,0,0,0,0,0,0,'Razaan''s Landing - OOC Update - Invoker,cast charge state 3'),
(@ENTRY*102,9,4,0,1,0,100,0,3000,3000,3000,3000,85,36800,0,0,0,0,0,7,0,0,0,0,0,0,0,'Razaan''s Landing - OOC Update - Invoker,cast charge state 4'),
(@ENTRY*102,9,5,0,1,0,100,0,3000,3000,3000,3000,85,36812,0,0,0,0,0,7,0,0,0,0,0,0,0,'Razaan''s Landing - OOC Update - Invoker,cast Soar&Credit'),
(@ENTRY*102,9,6,0,1,0,100,0,0,0,0,0,85,37108,0,0,0,0,0,7,0,0,0,0,0,0,0,'Razaan''s Landing - OOC Update - Invoker,cast Debuff'),
--
(@ENTRY*103,9,0,0,1,0,100,0,2000,2000,2000,2000,85,37908,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ruuan Weald - After 2 seconds - Port visual'),
(@ENTRY*103,9,1,0,1,0,100,0,2000,2000,2000,2000,45,1,1,0,0,0,0,10,74872,@ENTRY2,0,0,0,0,0,'The Zephyrium Capacitorium - After 2 seconds - Set Data on Channeler'),
(@ENTRY*103,9,2,0,1,0,100,0,3000,3000,3000,3000,85,36790,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ruuan Weald - OOC Update - Invoker,cast charge state 2'),
(@ENTRY*103,9,3,0,1,0,100,0,3000,3000,3000,3000,85,36792,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ruuan Weald - OOC Update - Invoker,cast charge state 3'),
(@ENTRY*103,9,4,0,1,0,100,0,3000,3000,3000,3000,85,36800,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ruuan Weald - OOC Update - Invoker,cast charge state 4'),
(@ENTRY*103,9,5,0,1,0,100,0,3000,3000,3000,3000,85,37968,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ruuan Weald - OOC Update - Invoker,cast Soar&Credit'),
(@ENTRY*103,9,6,0,1,0,100,0,0,0,0,0,85,37108,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ruuan Weald - OOC Update - Invoker,cast Debuff'),
--
(@ENTRY2,0,0,0,38,0,100,0,1,1,0,0,11,36795,0,0,0,0,0,1,0,0,0,0,0,0,0,'Beam Channel Bunny - On Data Set - Cast Cannon Beam');
DELETE FROM `conditions` WHERE `SourceEntry`=@BEAM OR `SourceGroup` IN (@MENUID,@A_MENU2,@A_MENU);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(15, @A_MENU2, 3, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 3 if player does not have aura Zephyrium Charged'),
(15, @A_MENU2, 3, 0, 0, 8, 0, 10712, 0, 0, 0, 0, 0, '', 'Show gossip option 3 if player has quest Ruuan Weald marked as rewarded'),
(15, @A_MENU2, 2, 0, 0, 8, 0, 10711, 0, 0, 0, 0, 0, '', 'Show gossip option 2 if player has quest Razaan''s Landing marked as rewarded'),
(15, @A_MENU2, 2, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 2 if player does not have aura Zephyrium Charged'),
(15, @A_MENU2, 1, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 1 if player does not have aura Zephyrium Charged'),
(15, @A_MENU2, 1, 0, 0, 8, 0, 10710, 0, 0, 0, 0, 0, '', 'Show gossip option 1 if player has quest The Singing Ridge marked as rewarded'),
(15, @A_MENU2, 4, 0, 0, 8, 0, 10557, 0, 0, 0, 0, 0, '', 'Show gossip option 4 if player has quest The Zephyrium Capacitorium marked as rewarded'),
(15, @A_MENU, 0, 0, 0, 2, 0, 30539, 1, 0, 0, 0, 0, '', 'Show gossip option 0 if player has item Tally''s Waiver (Signed)'),
(15, @MENUID, 3, 0, 0, 9, 0, 10712, 0, 0, 0, 0, 0, '', 'Show gossip option 3 if player has quest Ruuan Weald marked as taken'),
(15, @MENUID, 3, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 3 if player does not have aura Zephyrium Charged'),
(15, @MENUID, 2, 0, 0, 9, 0, 10711, 0, 0, 0, 0, 0, '', 'Show gossip option 2 if player has quest Razaan''s Landing marked as taken'),
(15, @MENUID, 2, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 2 if player does not have aura Zephyrium Charged'),
(15, @MENUID, 1, 0, 0, 9, 0, 10710, 0, 0, 0, 0, 0, '', 'Show gossip option 1 if player has quest The Singing Ridge marked as taken'),
(15, @MENUID, 1, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 1 if player does not have aura Zephyrium Charged'),
(15, @MENUID, 0, 0, 0, 9, 0, 10557, 0, 0, 0, 0, 0, '', 'Show gossip option 0 if player has quest The Zephyrium Capacitorium marked as taken'),
(15, @MENUID, 0, 0, 0, 1, 0, 37108, 0, 0, 1, 0, 0, '', 'Show gossip option 0 if player does not have aura Zephyrium Charged'),
--
(13, 1, 36795, 0, 0, 31, 0, 4, 0, 0, 0, 0, 0, '', 'Spell Cannon Channel(dnd) target player');
-- SAI for Rally (Questgiver)
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=21460;
DELETE FROM `smart_scripts` WHERE `entryorguid`=21460;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(21460,0,0,1,62,0,100,0,8303,0,0,0,56,30540,1,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Give Item '),
(21460,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rally Zapnabber - On gossip option select - Close gossip');
DELETE FROM `conditions` WHERE `SourceGroup` = 8303;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(15, 8303, 0, 0, 0, 2, 0, 30540, 1, 1, 1, 0, 0, '', 'Only allow gossip option to be visible if player doesn''t have item'),
(15, 8303, 0, 0, 0, 9, 0, 10710, 0, 0, 0, 0, 0, '', 'Only allow gossip option to be visible if player has quest taken');
@@ -0,0 +1,10 @@
/* cs_send.cpp */
SET @id = 483;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'send';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'send items';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'send mail';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'send message';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'send money';
@@ -0,0 +1,53 @@
/* cs_misc.cpp */
SET @id = 488;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'additem';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'additemset';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'appear';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'aura';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'bank';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'bindsight';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'combatstop';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'cometome';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'commands';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'cooldown';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'damage';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'dev';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'die';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'dismount';
UPDATE `command` SET `permission` = @id+14 WHERE `name` = 'distance';
UPDATE `command` SET `permission` = @id+15 WHERE `name` = 'flusharenapoints';
UPDATE `command` SET `permission` = @id+16 WHERE `name` = 'freeze';
UPDATE `command` SET `permission` = @id+17 WHERE `name` = 'gps';
UPDATE `command` SET `permission` = @id+18 WHERE `name` = 'guid';
UPDATE `command` SET `permission` = @id+19 WHERE `name` = 'help';
UPDATE `command` SET `permission` = @id+20 WHERE `name` = 'hidearea';
UPDATE `command` SET `permission` = @id+21 WHERE `name` = 'itemmove';
UPDATE `command` SET `permission` = @id+22 WHERE `name` = 'kick';
UPDATE `command` SET `permission` = @id+23 WHERE `name` = 'linkgrave';
UPDATE `command` SET `permission` = @id+24 WHERE `name` = 'listfreeze';
UPDATE `command` SET `permission` = @id+25 WHERE `name` = 'maxskill';
UPDATE `command` SET `permission` = @id+26 WHERE `name` = 'movegens';
UPDATE `command` SET `permission` = @id+27 WHERE `name` = 'mute';
UPDATE `command` SET `permission` = @id+28 WHERE `name` = 'neargrave';
UPDATE `command` SET `permission` = @id+29 WHERE `name` = 'pinfo';
UPDATE `command` SET `permission` = @id+30 WHERE `name` = 'playall';
UPDATE `command` SET `permission` = @id+31 WHERE `name` = 'possess';
UPDATE `command` SET `permission` = @id+32 WHERE `name` = 'recall';
UPDATE `command` SET `permission` = @id+33 WHERE `name` = 'repairitems';
UPDATE `command` SET `permission` = @id+34 WHERE `name` = 'respawn';
UPDATE `command` SET `permission` = @id+35 WHERE `name` = 'revive';
UPDATE `command` SET `permission` = @id+36 WHERE `name` = 'saveall';
UPDATE `command` SET `permission` = @id+37 WHERE `name` = 'save';
UPDATE `command` SET `permission` = @id+38 WHERE `name` = 'setskill';
UPDATE `command` SET `permission` = @id+39 WHERE `name` = 'showarea';
UPDATE `command` SET `permission` = @id+40 WHERE `name` = 'summon';
UPDATE `command` SET `permission` = @id+41 WHERE `name` = 'unaura';
UPDATE `command` SET `permission` = @id+42 WHERE `name` = 'unbindsight';
UPDATE `command` SET `permission` = @id+43 WHERE `name` = 'unfreeze';
UPDATE `command` SET `permission` = @id+44 WHERE `name` = 'unmute';
UPDATE `command` SET `permission` = @id+45 WHERE `name` = 'unpossess';
UPDATE `command` SET `permission` = @id+46 WHERE `name` = 'unstuck';
UPDATE `command` SET `permission` = @id+47 WHERE `name` = 'wchange';
@@ -0,0 +1,11 @@
/* cs_mmaps.cpp */
SET @id = 536;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'mmap';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'mmap loadedtiles';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'mmap loc';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'mmap path';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'mmap stats';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'mmap testarea';
@@ -0,0 +1,33 @@
/* cs_modify.cpp */
SET @id = 542;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'morph';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'demorph';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'modify';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'modify arenapoints';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'modify bit';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'modify drunk';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'modify energy';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'modify faction';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'modify gender';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'modify honor';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'modify hp';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'modify mana';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'modify money';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'modify mount';
UPDATE `command` SET `permission` = @id+14 WHERE `name` = 'modify phase';
UPDATE `command` SET `permission` = @id+15 WHERE `name` = 'modify rage';
UPDATE `command` SET `permission` = @id+16 WHERE `name` = 'modify reputation';
UPDATE `command` SET `permission` = @id+17 WHERE `name` = 'modify runicpower';
UPDATE `command` SET `permission` = @id+18 WHERE `name` = 'modify scale';
UPDATE `command` SET `permission` = @id+19 WHERE `name` = 'modify speed';
UPDATE `command` SET `permission` = @id+20 WHERE `name` = 'modify speed all';
UPDATE `command` SET `permission` = @id+21 WHERE `name` = 'modify speed backwalk';
UPDATE `command` SET `permission` = @id+22 WHERE `name` = 'modify speed fly';
UPDATE `command` SET `permission` = @id+23 WHERE `name` = 'modify speed walk';
UPDATE `command` SET `permission` = @id+24 WHERE `name` = 'modify speed swim';
UPDATE `command` SET `permission` = @id+25 WHERE `name` = 'modify spell';
UPDATE `command` SET `permission` = @id+26 WHERE `name` = 'modify standstate';
UPDATE `command` SET `permission` = @id+27 WHERE `name` = 'modify talentpoints';
@@ -0,0 +1,37 @@
/* cs_npc.cpp */
SET @id = 570;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'npc';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'npc add';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'npc add formation';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'npc add item';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'npc add move';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'npc add temp';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'npc add delete';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'npc add delete item';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'npc add follow';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'npc add follow stop';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'npc set';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'npc set allowmove';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'npc set entry';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'npc set factionid';
UPDATE `command` SET `permission` = @id+14 WHERE `name` = 'npc set flag';
UPDATE `command` SET `permission` = @id+15 WHERE `name` = 'npc set level';
UPDATE `command` SET `permission` = @id+16 WHERE `name` = 'npc set link';
UPDATE `command` SET `permission` = @id+17 WHERE `name` = 'npc set model';
UPDATE `command` SET `permission` = @id+18 WHERE `name` = 'npc set movetype';
UPDATE `command` SET `permission` = @id+19 WHERE `name` = 'npc set phase';
UPDATE `command` SET `permission` = @id+20 WHERE `name` = 'npc set spawndist';
UPDATE `command` SET `permission` = @id+21 WHERE `name` = 'npc set spawntime';
UPDATE `command` SET `permission` = @id+22 WHERE `name` = 'npc set data';
UPDATE `command` SET `permission` = @id+23 WHERE `name` = 'npc info';
UPDATE `command` SET `permission` = @id+24 WHERE `name` = 'npc near';
UPDATE `command` SET `permission` = @id+25 WHERE `name` = 'npc move';
UPDATE `command` SET `permission` = @id+26 WHERE `name` = 'npc playemote';
UPDATE `command` SET `permission` = @id+27 WHERE `name` = 'npc say';
UPDATE `command` SET `permission` = @id+28 WHERE `name` = 'npc textemote';
UPDATE `command` SET `permission` = @id+29 WHERE `name` = 'npc whisper';
UPDATE `command` SET `permission` = @id+30 WHERE `name` = 'npc yell';
UPDATE `command` SET `permission` = @id+31 WHERE `name` = 'npc tame';
@@ -0,0 +1,10 @@
/* cs_quest.cpp */
SET @id = 602;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'quest';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'quest add';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'quest complete';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'quest remove';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'quest reward';
@@ -0,0 +1,108 @@
/* cs_reload.cpp */
SET @id = 607;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'reload';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'reload access_requirement';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'reload achievement_criteria_data';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'reload achievement_reward';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'reload all';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'reload all achievement';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'reload all area';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'reload all eventai';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'reload all gossips';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'reload all item';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'reload all locales';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'reload all loot';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'reload all npc';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'reload all quest';
UPDATE `command` SET `permission` = @id+14 WHERE `name` = 'reload all scripts';
UPDATE `command` SET `permission` = @id+15 WHERE `name` = 'reload all spell';
UPDATE `command` SET `permission` = @id+16 WHERE `name` = 'reload areatrigger_involvedrelation';
UPDATE `command` SET `permission` = @id+17 WHERE `name` = 'reload areatrigger_tavern';
UPDATE `command` SET `permission` = @id+18 WHERE `name` = 'reload areatrigger_teleport';
UPDATE `command` SET `permission` = @id+19 WHERE `name` = 'reload auctions';
UPDATE `command` SET `permission` = @id+20 WHERE `name` = 'reload autobroadcast';
UPDATE `command` SET `permission` = @id+21 WHERE `name` = 'reload command';
UPDATE `command` SET `permission` = @id+22 WHERE `name` = 'reload conditions';
UPDATE `command` SET `permission` = @id+23 WHERE `name` = 'reload config';
UPDATE `command` SET `permission` = @id+24 WHERE `name` = 'reload creature_text';
UPDATE `command` SET `permission` = @id+25 WHERE `name` = 'reload creature_ai_scripts';
UPDATE `command` SET `permission` = @id+26 WHERE `name` = 'reload creature_ai_texts';
UPDATE `command` SET `permission` = @id+27 WHERE `name` = 'reload creature_questender';
UPDATE `command` SET `permission` = @id+28 WHERE `name` = 'reload creature_linked_respawn';
UPDATE `command` SET `permission` = @id+29 WHERE `name` = 'reload creature_loot_template';
UPDATE `command` SET `permission` = @id+30 WHERE `name` = 'reload creature_onkill_reputation';
UPDATE `command` SET `permission` = @id+31 WHERE `name` = 'reload creature_queststarter';
UPDATE `command` SET `permission` = @id+32 WHERE `name` = 'reload creature_summon_groups';
UPDATE `command` SET `permission` = @id+33 WHERE `name` = 'reload creature_template';
UPDATE `command` SET `permission` = @id+34 WHERE `name` = 'reload disables';
UPDATE `command` SET `permission` = @id+35 WHERE `name` = 'reload disenchant_loot_template';
UPDATE `command` SET `permission` = @id+36 WHERE `name` = 'reload event_scripts';
UPDATE `command` SET `permission` = @id+37 WHERE `name` = 'reload fishing_loot_template';
UPDATE `command` SET `permission` = @id+38 WHERE `name` = 'reload game_graveyard_zone';
UPDATE `command` SET `permission` = @id+39 WHERE `name` = 'reload game_tele';
UPDATE `command` SET `permission` = @id+40 WHERE `name` = 'reload gameobject_questender';
UPDATE `command` SET `permission` = @id+41 WHERE `name` = 'reload gameobject_loot_template';
UPDATE `command` SET `permission` = @id+42 WHERE `name` = 'reload gameobject_queststarter';
UPDATE `command` SET `permission` = @id+43 WHERE `name` = 'reload gm_tickets';
UPDATE `command` SET `permission` = @id+44 WHERE `name` = 'reload gossip_menu';
UPDATE `command` SET `permission` = @id+45 WHERE `name` = 'reload gossip_menu_option';
UPDATE `command` SET `permission` = @id+46 WHERE `name` = 'reload item_enchantment_template';
UPDATE `command` SET `permission` = @id+47 WHERE `name` = 'reload item_loot_template';
UPDATE `command` SET `permission` = @id+48 WHERE `name` = 'reload item_set_names';
UPDATE `command` SET `permission` = @id+49 WHERE `name` = 'reload lfg_dungeon_rewards';
UPDATE `command` SET `permission` = @id+50 WHERE `name` = 'reload locales_achievement_reward';
UPDATE `command` SET `permission` = @id+51 WHERE `name` = 'reload locales_creature';
UPDATE `command` SET `permission` = @id+52 WHERE `name` = 'reload locales_creature_text';
UPDATE `command` SET `permission` = @id+53 WHERE `name` = 'reload locales_gameobject';
UPDATE `command` SET `permission` = @id+54 WHERE `name` = 'reload locales_gossip_menu_option';
UPDATE `command` SET `permission` = @id+55 WHERE `name` = 'reload locales_item';
UPDATE `command` SET `permission` = @id+56 WHERE `name` = 'reload locales_item_set_name';
UPDATE `command` SET `permission` = @id+57 WHERE `name` = 'reload locales_npc_text';
UPDATE `command` SET `permission` = @id+58 WHERE `name` = 'reload locales_page_text';
UPDATE `command` SET `permission` = @id+59 WHERE `name` = 'reload locales_points_of_interest';
UPDATE `command` SET `permission` = @id+60 WHERE `name` = 'reload locales_quest';
UPDATE `command` SET `permission` = @id+61 WHERE `name` = 'reload mail_level_reward';
UPDATE `command` SET `permission` = @id+62 WHERE `name` = 'reload mail_loot_template';
UPDATE `command` SET `permission` = @id+63 WHERE `name` = 'reload milling_loot_template';
UPDATE `command` SET `permission` = @id+64 WHERE `name` = 'reload npc_spellclick_spells';
UPDATE `command` SET `permission` = @id+65 WHERE `name` = 'reload npc_trainer';
UPDATE `command` SET `permission` = @id+66 WHERE `name` = 'reload npc_vendor';
UPDATE `command` SET `permission` = @id+67 WHERE `name` = 'reload page_text';
UPDATE `command` SET `permission` = @id+68 WHERE `name` = 'reload pickpocketing_loot_template';
UPDATE `command` SET `permission` = @id+69 WHERE `name` = 'reload points_of_interest';
UPDATE `command` SET `permission` = @id+70 WHERE `name` = 'reload prospecting_loot_template';
UPDATE `command` SET `permission` = @id+71 WHERE `name` = 'reload quest_poi';
UPDATE `command` SET `permission` = @id+72 WHERE `name` = 'reload quest_template';
UPDATE `command` SET `permission` = @id+73 WHERE `name` = 'reload rbac';
UPDATE `command` SET `permission` = @id+74 WHERE `name` = 'reload reference_loot_template';
UPDATE `command` SET `permission` = @id+75 WHERE `name` = 'reload reserved_name';
UPDATE `command` SET `permission` = @id+76 WHERE `name` = 'reload reputation_reward_rate';
UPDATE `command` SET `permission` = @id+77 WHERE `name` = 'reload reputation_spillover_template';
UPDATE `command` SET `permission` = @id+78 WHERE `name` = 'reload skill_discovery_template';
UPDATE `command` SET `permission` = @id+79 WHERE `name` = 'reload skill_extra_item_template';
UPDATE `command` SET `permission` = @id+80 WHERE `name` = 'reload skill_fishing_base_level';
UPDATE `command` SET `permission` = @id+81 WHERE `name` = 'reload skinning_loot_template';
UPDATE `command` SET `permission` = @id+82 WHERE `name` = 'reload smart_scripts';
UPDATE `command` SET `permission` = @id+83 WHERE `name` = 'reload spell_required';
UPDATE `command` SET `permission` = @id+84 WHERE `name` = 'reload spell_area';
UPDATE `command` SET `permission` = @id+85 WHERE `name` = 'reload spell_bonus_data';
UPDATE `command` SET `permission` = @id+86 WHERE `name` = 'reload spell_group';
UPDATE `command` SET `permission` = @id+87 WHERE `name` = 'reload spell_learn_spell';
UPDATE `command` SET `permission` = @id+88 WHERE `name` = 'reload spell_loot_template';
UPDATE `command` SET `permission` = @id+89 WHERE `name` = 'reload spell_linked_spell';
UPDATE `command` SET `permission` = @id+90 WHERE `name` = 'reload spell_pet_auras';
UPDATE `command` SET `permission` = @id+91 WHERE `name` = 'reload spell_proc_event';
UPDATE `command` SET `permission` = @id+92 WHERE `name` = 'reload spell_proc';
UPDATE `command` SET `permission` = @id+93 WHERE `name` = 'reload spell_scripts';
UPDATE `command` SET `permission` = @id+94 WHERE `name` = 'reload spell_target_position';
UPDATE `command` SET `permission` = @id+95 WHERE `name` = 'reload spell_threats';
UPDATE `command` SET `permission` = @id+96 WHERE `name` = 'reload spell_group_stack_rules';
UPDATE `command` SET `permission` = @id+97 WHERE `name` = 'reload trinity_string';
UPDATE `command` SET `permission` = @id+98 WHERE `name` = 'reload warden_action';
UPDATE `command` SET `permission` = @id+99 WHERE `name` = 'reload waypoint_scripts';
UPDATE `command` SET `permission` = @id+100 WHERE `name` = 'reload waypoint_data';
UPDATE `command` SET `permission` = @id+101 WHERE `name` = 'reload vehicle_accessory';
UPDATE `command` SET `permission` = @id+102 WHERE `name` = 'reload vehicle_template_accessory';
@@ -0,0 +1,13 @@
/* cs_reset.cpp */
SET @id = 710;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'reset';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'reset achievements';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'reset honor';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'reset level';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'reset spells';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'reset stats';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'reset talents';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'reset all';
@@ -0,0 +1,24 @@
/* cs_server.cpp */
SET @id = 718;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'server';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'server corpses';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'server exit';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'server idlerestart';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'server idlerestart cancel';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'server idleshutdown';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'server idleshutdown cancel';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'server info';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'server plimit';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'server restart';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'server restart cancel';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'server set';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'server set closed';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'server set difftime';
UPDATE `command` SET `permission` = @id+14 WHERE `name` = 'server set loglevel';
UPDATE `command` SET `permission` = @id+15 WHERE `name` = 'server set motd';
UPDATE `command` SET `permission` = @id+16 WHERE `name` = 'server shutdown';
UPDATE `command` SET `permission` = @id+17 WHERE `name` = 'server shutdown cancel';
UPDATE `command` SET `permission` = @id+18 WHERE `name` = 'server motd';
@@ -0,0 +1,10 @@
/* cs_tele.cpp */
SET @id = 737;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'tele';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'tele add';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'tele del';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'tele name';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'tele group';
@@ -0,0 +1,24 @@
/* cs_ticket.cpp */
SET @id = 742;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'ticket';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'ticket assign';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'ticket close';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'ticket closedlist';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'ticket comment';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'ticket complete';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'ticket delete';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'ticket escalate';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'ticket escalatedlist';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'ticket list';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'ticket onlinelist';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'ticket reset';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'ticket response';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'ticket response append';
UPDATE `command` SET `permission` = @id+14 WHERE `name` = 'ticket response appendln';
UPDATE `command` SET `permission` = @id+15 WHERE `name` = 'ticket togglesystem';
UPDATE `command` SET `permission` = @id+16 WHERE `name` = 'ticket unassign';
UPDATE `command` SET `permission` = @id+17 WHERE `name` = 'ticket viewid';
UPDATE `command` SET `permission` = @id+18 WHERE `name` = 'ticket viewname';
@@ -0,0 +1,19 @@
/* cs_titles.cpp & cs_wp.cpp */
SET @id = 761;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'titles';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'titles add';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'titles current';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'titles remove';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'titles set';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'titles set mask';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'wp';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'wp add';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'wp event';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'wp load';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'wp modify';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'wp unload';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'wp reload';
UPDATE `command` SET `permission` = @id+13 WHERE `name` = 'wp show';
@@ -0,0 +1,2 @@
-- Update command table and remove obsolete permissions (0 = non existent permission)
UPDATE `command` SET `permission` = 0 WHERE `permission` IN (7, 8, 9, 10, 12);
@@ -0,0 +1,16 @@
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = 201 WHERE `name` = 'rbac account';
UPDATE `command` SET `permission` = 202 WHERE `name` = 'rbac account group';
UPDATE `command` SET `permission` = 203 WHERE `name` = 'rbac account group add';
UPDATE `command` SET `permission` = 204 WHERE `name` = 'rbac account group remove';
UPDATE `command` SET `permission` = 205 WHERE `name` = 'rbac account role';
UPDATE `command` SET `permission` = 206 WHERE `name` = 'rbac account role grant';
UPDATE `command` SET `permission` = 207 WHERE `name` = 'rbac account role deny';
UPDATE `command` SET `permission` = 208 WHERE `name` = 'rbac account role revoke';
UPDATE `command` SET `permission` = 209 WHERE `name` = 'rbac account permission';
UPDATE `command` SET `permission` = 210 WHERE `name` = 'rbac account permission grant';
UPDATE `command` SET `permission` = 211 WHERE `name` = 'rbac account permission deny';
UPDATE `command` SET `permission` = 212 WHERE `name` = 'rbac account permission revoke';
UPDATE `command` SET `permission` = 214 WHERE `name` = 'rbac account list groups';
UPDATE `command` SET `permission` = 215 WHERE `name` = 'rbac account list roles';
UPDATE `command` SET `permission` = 216 WHERE `name` = 'rbac account list permissions';
@@ -0,0 +1,9 @@
UPDATE `command` SET `permission`=214 WHERE `name`='rbac list groups';
UPDATE `command` SET `permission`=215 WHERE `name`='rbac list roles';
UPDATE `command` SET `permission`=216 WHERE `name`='rbac list permissions';
UPDATE `command` SET `permission`=262 WHERE `name`='bf enable';
UPDATE `command` SET `permission`=576 WHERE `name`='npc delete';
UPDATE `command` SET `permission`=577 WHERE `name`='npc delete item';
UPDATE `command` SET `permission`=578 WHERE `name`='npc follow';
UPDATE `command` SET `permission`=579 WHERE `name`='npc follow stop';
UPDATE `command` SET `permission`=316 WHERE `name`='debug play cinematic';
@@ -0,0 +1,66 @@
DELETE FROM `command` WHERE `name` = 'account email';
DELETE FROM `command` WHERE `name` = 'account set sec email';
DELETE FROM `command` WHERE `name` = 'account set sec regmail';
INSERT INTO `command` (`name`, `permission`, `help`) VALUES
('account email', 263, 'Syntax: .account email $oldemail $currentpassword $newemail $newemailconfirmation\r\n\r\n Change your account email. You may need to check the actual security mode to see if email input is necessary for password change'),
('account set sec email', 265, 'Syntax: .account set sec email $accountname $email $emailconfirmation\r\n\r\nSet the email for entered player account.'),
('account set sec regmail', 266, 'Syntax: .account set sec regmail $account $regmail $regmailconfirmation\r\n\r\nSets the regmail for entered player account.');
/* cs_cast.cpp */
SET @id = 267;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'cast';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'cast back';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'cast dist';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'cast self';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'cast target';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'cast dest';
/* cs_go.cpp */
SET @id = 377;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'go';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'go creature';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'go graveyard';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'go grid';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'go object';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'go taxinode';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'go ticket';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'go trigger';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'go xyz';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'go zonexy';
/* cs_gobject.cpp */
SET @id = 387;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'gobject';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'gobject activate';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'gobject add';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'gobject add temp';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'gobject delete';
UPDATE `command` SET `permission` = @id+5 WHERE `name` = 'gobject info';
UPDATE `command` SET `permission` = @id+6 WHERE `name` = 'gobject move';
UPDATE `command` SET `permission` = @id+7 WHERE `name` = 'gobject near';
UPDATE `command` SET `permission` = @id+8 WHERE `name` = 'gobject set';
UPDATE `command` SET `permission` = @id+9 WHERE `name` = 'gobject set phase';
UPDATE `command` SET `permission` = @id+10 WHERE `name` = 'gobject set state';
UPDATE `command` SET `permission` = @id+11 WHERE `name` = 'gobject target';
UPDATE `command` SET `permission` = @id+12 WHERE `name` = 'gobject turn';
/* cs_instance.cpp */
SET @id = 412;
-- Update command table with new RBAC permissions
UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'instance';
UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'instance listbinds';
UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'instance unbind';
UPDATE `command` SET `permission` = @id+3 WHERE `name` = 'instance stats';
UPDATE `command` SET `permission` = @id+4 WHERE `name` = 'instance savedata';
@@ -0,0 +1 @@
UPDATE `creature_template` SET `modelid1`=1126,`modelid2`=16925 WHERE `entry`=21393;
@@ -0,0 +1,7 @@
-- Update for Forgotten npcs to award credit.
UPDATE `smart_scripts` SET `action_type`=85 WHERE `entryorguid`=27224 AND `source_type`=0 AND `id`=0 AND `link`=1;
UPDATE `smart_scripts` SET `action_type`=85 WHERE `entryorguid`=27225 AND `source_type`=0 AND `id`=0 AND `link`=1;
UPDATE `smart_scripts` SET `action_type`=85 WHERE `entryorguid`=27229 AND `source_type`=0 AND `id`=0 AND `link`=1;
UPDATE `smart_scripts` SET `action_type`=85 WHERE `entryorguid`=27226 AND `source_type`=0 AND `id`=0 AND `link`=1;
-- Forced model for Channel Bunny... should've used that earlier.
UPDATE `creature` SET `modelid`=16925, `position_x`=1924.63, `position_y`=5574.76, `position_z`=273.122 WHERE `guid`=74872;
@@ -0,0 +1 @@
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=8455 AND `SourceEntry`=4;
@@ -0,0 +1,5 @@
UPDATE `creature_template` SET`AIName`='SmartAI' WHERE `entry`=26321;
DELETE FROM `creature_ai_scripts` WHERE `creature_id`=26321;
DELETE FROM `smart_scripts` WHERE `entryorguid`=26321;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(26321,0,0,0,8,0,100,1,47530,0,0,0,33,26321,0,0,0,0,0,7,0,0,0,0,0,0,0,'Lothalor Ancient - On Spellhit - Give Credit to Invoker');
@@ -0,0 +1,17 @@
-- [QUEST] War Is Hell
UPDATE `creature` SET `spawntimesecs`=60 WHERE `id` IN (24009,24010);
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry` IN (24009,24010);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (24009,24010) AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
-- Alliance Corpse
(24009, 0, 0, 1, 8, 0, 100, 1, 42793, 0, 0, 0, 11, 43297, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Alliance Corpse - SMART_EVENT_SPELLHIT - SMART_ACTION_CAST'),
(24009, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 20000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Alliance Corpse - SMART_EVENT_LINK - SMART_ACTION_FORCE_DESPAWN'),
-- Forsaken Corpse
(24010, 0, 0, 1, 8, 0, 100, 1, 42793, 0, 0, 0, 11, 43297, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Forsaken Corpse - SMART_EVENT_SPELLHIT - SMART_ACTION_CAST'),
(24010, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 20000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Forsaken Corpse - SMART_EVENT_LINK - SMART_ACTION_FORCE_DESPAWN');
DELETE FROM `conditions` WHERE `SourceEntry`=42793 AND `SourceTypeOrReferenceId`=17;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(17, 0, 42793, 0, 0, 31, 1, 3, 24009, 0, 0, 0, 0, '', ''),
(17, 0, 42793, 0, 1, 31, 1, 3, 24010, 0, 0, 0, 0, '', '');
@@ -0,0 +1 @@
UPDATE `conditions` SET `ElseGroup`=2 WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=75509;
@@ -0,0 +1 @@
UPDATE `smart_scripts` SET `target_type`=24 WHERE `entryorguid`=2935200 AND `source_type`=9 AND `id`=0 AND `link`=0;
@@ -0,0 +1,3 @@
DELETE FROM `gameobject` WHERE `id`= 15885;
INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES
(99849, 15885, 1, 1, 1, 7853.95, -2212.3, 456.397, 0, 0, 0, 0, 0, 0, 0, 1);
@@ -0,0 +1,132 @@
-- Fate of the Titans (12986)
-- http://www.youtube.com/watch?v=H6HED6PaxIs
SET @NPC_DISK := 30313; -- Mobile Databank
SET @NPC_BUNNY_INVENTION := 30315; -- Temple of Invention Bunny
SET @NPC_BUNNY_LIFE := 30316; -- Temple of Life Bunny
SET @NPC_BUNNY_WINTER := 30317; -- Temple of Winter Bunny
SET @NPC_BUNNY_ORDER := 30318; -- Temple of Order Bunny
SET @NPC_BUNNY_DATASCAN := 30889; -- Data Scan Target Bunny
SET @SPELL_DATASCAN := 56523; -- Data Scan
SET @SPELL_INVENTION_KC := 56532; -- Temple of Invention Kill Credit
SET @SPELL_LIFE_KC := 56534; -- Temple of Life Kill Credit
SET @SPELL_WINTER_KC := 56533; -- Temple of Winter Kill Credit
SET @SPELL_ORDER_KC := 56535; -- Temple of Order Kill Credit
SET @GUID := 127294;
UPDATE `creature_template` SET `AIName`='SmartAI',`speed_walk`=3.14286, `InhabitType`=4 WHERE `entry`=@NPC_DISK;
UPDATE `creature_template` SET `AIName`='SmartAI',`unit_flags`=`unit_flags`|33554432,`InhabitType`=7,`flags_extra`=`flags_extra`|128 WHERE `entry` IN (@NPC_BUNNY_INVENTION,@NPC_BUNNY_LIFE,@NPC_BUNNY_WINTER,@NPC_BUNNY_ORDER,@NPC_BUNNY_DATASCAN);
-- Sniffed
DELETE FROM `creature` WHERE `id` IN (@NPC_BUNNY_INVENTION,@NPC_BUNNY_LIFE,@NPC_BUNNY_WINTER,@NPC_BUNNY_ORDER,@NPC_BUNNY_DATASCAN);
INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`currentwaypoint`,`curhealth`,`curmana`,`MovementType`,`npcflag`,`unit_flags`,`dynamicflags`) VALUES
-- Databank should go from one to another and say text
(@GUID+0,@NPC_BUNNY_INVENTION,571,1,1,0,0,7865.214,-1397.313,1534.143,3.752458,300,0,0,1,0,0,0,0,0),
(@GUID+1,@NPC_BUNNY_LIFE,571,1,1,0,0,7994.017,-2734.839,1133.662,0.3316126,300,0,0,1,0,0,0,0,0),
(@GUID+2,@NPC_BUNNY_WINTER,571,1,1,0,0,7498.68,-1899.41,1473.61,0.132902,300,0,0,1,0,0,0,0,0),
(@GUID+3,@NPC_BUNNY_ORDER,571,1,1,0,0,8194.199,-1963.597,1738.56,1.954769,300,0,0,1,0,0,0,0,0),
-- At the Temple of Order:
(@GUID+4,@NPC_BUNNY_DATASCAN,571,1,1,0,0,8130.811,-1995.321,1781.117,0.05235988,300,0,0,1,0,0,0,0,0),
(@GUID+5,@NPC_BUNNY_DATASCAN,571,1,1,0,0,8213.646,-1901.764,1744.02,0.5759587,300,0,0,1,0,0,0,0,0),
(@GUID+6,@NPC_BUNNY_DATASCAN,571,1,1,0,0,8255.328,-1982.391,1742.117,4.031711,300,0,0,1,0,0,0,0,0),
-- At the Temple of Invention:
(@GUID+7,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7868.994,-1375.799,1541.754,4.712389,300,0,0,1,0,0,0,0,0),
(@GUID+8,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7924.429,-1385.165,1534.788,6.038839,300,0,0,1,0,0,0,0,0),
(@GUID+9,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7903.273, -1424.807, 1539.821,2.048841,300,0,0,1,0,0,0,0,0),
(@GUID+10,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7863.330, -1434.625, 1537.565,3.072831,300,0,0,1,0,0,0,0,0),
-- At the Temple of Life:
(@GUID+11,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7924.706,-2748.963,1151.056,4.520403,300,0,0,1,0,0,0,0,0),
(@GUID+12,@NPC_BUNNY_DATASCAN,571,1,1,0,0,8010.217,-2750.608,1151.104,0.418879,300,0,0,1,0,0,0,0,0),
(@GUID+13,@NPC_BUNNY_DATASCAN,571,1,1,0,0,8027.505,-2728.616,1139.939,3.944444,300,0,0,1,0,0,0,0,0),
(@GUID+14,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7978.187,-2714.357,1137.354,2.643541,300,0,0,1,0,0,0,0,0),
-- At the Temple of Winter:
(@GUID+15,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7520.712,-1929.840,1482.500,4.520403,300,0,0,1,0,0,0,0,0),
(@GUID+16,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7478.601, -1917.123, 1473.615,0.418879,300,0,0,1,0,0,0,0,0),
(@GUID+17,@NPC_BUNNY_DATASCAN,571,1,1,0,0,7473.774, -1875.455, 1473.614,3.944444,300,0,0,1,0,0,0,0,0);
-- Databank only executes SAI near Temple Bunnies
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceEntry`=@NPC_DISK;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES
(22,1,@NPC_DISK,0,0,29,0,@NPC_BUNNY_INVENTION,15,0,0,0,'','Execute sai if near dummy npc'),
(22,2,@NPC_DISK,0,0,29,0,@NPC_BUNNY_WINTER,15,0,0,0,'','Execute sai if near dummy npc'),
(22,3,@NPC_DISK,0,0,29,0,@NPC_BUNNY_LIFE,15,0,0,0,'','Execute sai if near dummy npc'),
(22,4,@NPC_DISK,0,0,29,0,@NPC_BUNNY_ORDER,15,0,0,0,'','Execute sai if near dummy npc');
DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` IN (@NPC_DISK,@NPC_BUNNY_INVENTION);
DELETE FROM `smart_scripts` WHERE `source_type`=9 AND `entryorguid` IN (@NPC_DISK*100+0,@NPC_DISK*100+1,@NPC_DISK*100+2,@NPC_DISK*100+3);
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(@NPC_DISK,0,0,0,10,0,100,1,500,1000,500,1000,80,@NPC_DISK*100+0,2,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - OOC near npc - Run script'),
--
(@NPC_DISK,0,1,0,10,0,100,1,500,1000,500,1000,80,@NPC_DISK*100+1,2,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - OOC near npc - Run script'),
--
(@NPC_DISK,0,2,0,10,0,100,1,500,1000,500,1000,80,@NPC_DISK*100+2,2,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - OOC near npc - Run script'),
--
(@NPC_DISK,0,3,0,10,0,100,1,500,1000,500,1000,80,@NPC_DISK*100+3,2,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - OOC near npc - Run script'),
--
(@NPC_DISK*100+0,9,0,0,0,0,100,0,5000,5000,5000,5000,69,1,0,0,0,0,0,10,@GUID+7,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+0,9,1,0,0,0,100,0,3000,3000,3000,3000,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+0,9,2,0,0,0,100,0,2000,2000,2000,2000,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+0,9,3,0,0,0,100,0,8000,8000,8000,8000,69,1,0,0,0,0,0,10,@GUID+8,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+0,9,4,0,0,0,100,0,7000,7000,7000,7000,1,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+0,9,5,0,0,0,100,0,9000,9000,9000,9000,69,1,0,0,0,0,0,10,@GUID+9,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+0,9,6,0,0,0,100,0,3000,3000,3000,3000,1,3,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+0,9,7,0,0,0,100,0,9000,9000,9000,9000,69,1,0,0,0,0,0,10,@GUID+10,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+0,9,8,0,0,0,100,0,3000,3000,3000,3000,1,4,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+0,9,9,0,0,0,100,0,0,0,0,0,11,@SPELL_INVENTION_KC,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On script - Cast Credit'),
--
(@NPC_DISK*100+1,9,0,0,0,0,100,0,5000,5000,5000,5000,69,1,0,0,0,0,0,10,@GUID+15,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+1,9,1,0,0,0,100,0,3000,3000,3000,3000,1,5,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+1,9,2,0,0,0,100,0,2000,2000,2000,2000,1,6,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+1,9,3,0,0,0,100,0,8000,8000,8000,8000,69,1,0,0,0,0,0,10,@GUID+16,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+1,9,4,0,0,0,100,0,7000,7000,7000,7000,1,7,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+1,9,5,0,0,0,100,0,9000,9000,9000,9000,69,1,0,0,0,0,0,10,@GUID+17,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+1,9,6,0,0,0,100,0,3000,3000,3000,3000,1,8,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+1,9,7,0,0,0,100,0,3000,3000,3000,3000,1,9,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+1,9,8,0,0,0,100,0,0,0,0,0,11,@SPELL_WINTER_KC,0,0,0,0,0,7,0,0,0,0,0,0,0,'Mobile Databank - On script - Cast Credit'),
--
(@NPC_DISK*100+2,9,0,0,0,0,100,0,5000,5000,5000,5000,69,1,0,0,0,0,0,10,@GUID+11,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+2,9,1,0,0,0,100,0,3000,3000,3000,3000,1,10,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+2,9,2,0,0,0,100,0,2000,2000,2000,2000,1,11,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+2,9,3,0,0,0,100,0,8000,8000,8000,8000,69,1,0,0,0,0,0,10,@GUID+12,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+2,9,4,0,0,0,100,0,7000,7000,7000,7000,1,12,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+2,9,5,0,0,0,100,0,9000,9000,9000,9000,69,1,0,0,0,0,0,10,@GUID+13,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+2,9,6,0,0,0,100,0,3000,3000,3000,3000,1,13,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+2,9,7,0,0,0,100,0,9000,9000,9000,9000,69,1,0,0,0,0,0,10,@GUID+14,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+2,9,8,0,0,0,100,0,3000,3000,3000,3000,1,14,0,0,0,0,0,1,0,0,0,0,0,0,0,'MMobile Databank - On Script - Say'),
(@NPC_DISK*100+2,9,9,0,0,0,100,0,0,0,0,0,11,@SPELL_LIFE_KC,0,0,0,0,0,7,0,0,0,0,0,0,0,'Mobile Databank - On script - Cast Credit'),
--
(@NPC_DISK*100+3,9,0,0,0,0,100,0,5000,5000,5000,5000,69,1,0,0,0,0,0,10,@GUID+4,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+3,9,1,0,0,0,100,0,3000,3000,3000,3000,1,15,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+3,9,2,0,0,0,100,0,2000,2000,2000,2000,1,16,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+3,9,3,0,0,0,100,0,8000,8000,8000,8000,69,1,0,0,0,0,0,10,@GUID+5,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+3,9,4,0,0,0,100,0,7000,7000,7000,7000,1,17,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+3,9,5,0,0,0,100,0,9000,9000,9000,9000,69,1,0,0,0,0,0,10,@GUID+6,@NPC_BUNNY_DATASCAN,0,0,0,0,0,'Mobile Databank - On Script - Move to Pos'),
(@NPC_DISK*100+3,9,6,0,0,0,100,0,3000,3000,3000,3000,1,18,0,0,0,0,0,1,0,0,0,0,0,0,0,'Mobile Databank - On Script - Say'),
(@NPC_DISK*100+3,9,7,0,0,0,100,0,0,0,0,0,11,@SPELL_ORDER_KC,0,0,0,0,0,7,0,0,0,0,0,0,0,'Mobile Databank - On script - Cast Credit');
DELETE FROM `creature_text` WHERE `entry`=@NPC_DISK;
INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`) VALUES
-- At the Temple of Invention:
(@NPC_DISK,0,0,'Temple of Invention analysis commencing.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,1,0,'Temple of Invention verified to be in-tact.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,2,0,'Mechanical servants appear to have turned against each other. Several attendants have been piled together in an unorganized manner.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,3,0,'Remaining mechagnome guardians corrupted by unknown source.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,4,0,'Watcher Mimir verified to no longer be present. Analysis complete.',12,0,100,15,0,0,'Mobile Databank'),
-- At the Temple of Winter:
(@NPC_DISK,5,0,'Temple of Winter analysis commencing.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,6,0,'Temple of Winter verified to be in-tact.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,7,0,'Temple guardians verified to be deceased. Sulfurous odor suggests that death resulted from a fire-base entity.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,8,0,'Previously established cold weather patterns at the temple have ceased.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,9,0,'Watcher Hodir verified to no longer be present. Analysis complete.',12,0,100,15,0,0,'Mobile Databank'),
-- At the Temple of Life:
(@NPC_DISK,10,0,'Temple of Life analysis commencing.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,11,0,'Temple of Life verified to be damaged beyond repair.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,12,0,'Evidence indicates a significant battle. The opponent of Watcher Freya estimated to be of similar size and strength to Watcher Freya.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,13,0,'Temple guardians are no longer present. Plant forms associated with temple are deceased.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,14,0,'Watcher Freya verified to no longer be present. Analysis complete.',12,0,100,15,0,0,'Mobile Databank'),
-- At the Temple of Order:
(@NPC_DISK,15,0,'Temple of Order analysis commencing.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,16,0,'Temple of Order verified to be in-tact.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,17,0,'No indications of struggle are present. No guardians are present.',12,0,100,15,0,0,'Mobile Databank'),
(@NPC_DISK,18,0,'Watcher Tyr verified to no longer be present. Analysis complete.',12,0,100,15,0,0,'Mobile Databank');
@@ -0,0 +1,13 @@
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceGroup`=1 AND `SourceEntry`=28739 AND `SourceId`=0;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(22,1,28739,0,0,1,1,52231,0,0,1,0,0,'','Execute sai only if aura is not presented');
DELETE FROM `disables` WHERE `entry` IN (52227,52228) AND `sourcetype`=0;
INSERT INTO `disables` (`sourceType`, `entry`, `flags`, `params_0`, `params_1`, `comment`) VALUES
(0,52227,64,'','','Disable LOS check for Dilute Blight Cauldron'),
(0,52228,64,'','','Disable LOS check for Kill Credit (quest 12669)');
UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry`=28739;
DELETE FROM `smart_scripts` WHERE `entryorguid`=28739 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(28739,0,0,1,8,0,100,0,52227,0,0,0,11,52228,0,0,0,0,0,7,0,0,0,0,0,0,0,'Blight Cauldron Bunny 00 - On Spell Hit - Give Quest Credit'),
(28739,0,1,0,61,0,100,0,0,0,0,0,11,52231,0,0,0,0,0,1,0,0,0,0,0,0,0,'Blight Cauldron Bunny 00 - Link With Previous Event - Cast Cauldron Diluted Effect'),
(28739,0,2,0,1,0,100,0,30000,30000,30000,30000,28,52231,0,0,0,0,0,1,0,0,0,0,0,0,0,'Blight Cauldron Bunny 00 - OOC - Remove Aura From Cauldron Diluted Effect');
@@ -0,0 +1,8 @@
-- 10146 - [Mission: The Murketh and Shaadraz Gateways]
-- 10129 - [Mission: Gateways Murketh and Shaadraz]
DELETE FROM `creature_ai_scripts` WHERE `creature_id` in (19291,19292);
UPDATE `creature_template` SET `AIName`='SmartAI',`flags_extra`=130 WHERE `entry` IN (19291,19292);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (19291,19292) AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES
(19291,0,0,0,8,0,100,0,33655,0,0,0,33,19291,0,0,0,0,0,7,0,0,0,0,0,0,0,'Legion Transporter: Alpha - Quest Credit on Dropping The Nether Modulator Spellhit'),
(19292,0,0,0,8,0,100,0,33655,0,0,0,33,19292,0,0,0,0,0,7,0,0,0,0,0,0,0,'Legion Transporter: Beta - Quest Credit on Dropping The Nether Modulator Spellhit');
@@ -0,0 +1 @@
DELETE FROM `creature_addon` WHERE `guid`=105665;
@@ -0,0 +1,49 @@
-- Deep in the bowels of the Underhalls
UPDATE `smart_scripts` SET `target_type`=24 WHERE `entryorguid`=30409 AND `source_type`=0 AND `id`=4 AND `link`=0;
-- Guide our sights
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN(23957,23972);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (23957,23972);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(23957, 0, 0, 0, 8, 0, 100, 0, 43076, 0, 0, 0, 33, 23957 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Westguard Cannon Credit Trigger East - On Spellhit - Kill Credit'),
(23972, 0, 0, 0, 8, 0, 100, 0, 43076, 0, 0, 0, 33, 23972 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Westguard Cannon Credit Trigger West - On Spellhit - Kill Credit');
-- Baleheim Must Burn
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN(24182,24183,24184,24185);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (24182,24183,24184,24185);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(24182, 0, 0, 0, 8, 0, 100, 0, 43233, 0, 0, 0, 33, 24182 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Winterskorn Dwelling Credit - On Spellhit - Kill Credit'),
(24183, 0, 0, 0, 8, 0, 100, 0, 43233, 0, 0, 0, 33, 24183 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Winterskorn Watchtower Credit - On Spellhit - Kill Credit'),
(24184, 0, 0, 0, 8, 0, 100, 0, 43233, 0, 0, 0, 33, 24184 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Winterskorn Barracks Credit - On Spellhit - Kill Credit'),
(24185, 0, 0, 0, 8, 0, 100, 0, 43233, 0, 0, 0, 33, 24185 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Winterskorn Bridge Credit - On Spellhit - Kill Credit');
-- Forge Camp: Annihilated
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN(17998,17999,18000,18002);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (17998,17999,18000,18002);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(17998, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 17998 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Umbrafen Steam Pump Credit Marker - On Spellhit - Kill Credit'),
(17999, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 17999 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Lagoon Steam Pump Credit Marker - On Spellhit - Kill Credit'),
(18000, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 18000 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Serpent Steam Pump Credit Marker - On Spellhit - Kill Credit'),
(18002, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 18002 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Marshlight Steam Pump Credit Marker - On Spellhit - Kill Credit');
-- Balance Must Be Preserved
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN(17998,17999,18000,18002);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (17998,17999,18000,18002);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(17998, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 17998 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Umbrafen Steam Pump Credit Marker - On Spellhit - Kill Credit'),
(17999, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 17999 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Lagoon Steam Pump Credit Marker - On Spellhit - Kill Credit'),
(18000, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 18000 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Serpent Steam Pump Credit Marker - On Spellhit - Kill Credit'),
(18002, 0, 0, 0, 8, 0, 100, 0, 31736, 0, 0, 0, 33, 18002 , 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Marshlight Steam Pump Credit Marker - On Spellhit - Kill Credit');
-- Burn in Effigy
UPDATE `smart_scripts` SET `event_flags`=0 WHERE `entryorguid` BETWEEN 25510 AND 25513 AND `source_type`=0;
-- A Necessary Distraction
UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` IN (21506);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (21506);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(21506, 0, 0, 0, 8, 0, 100, 0, 37834, 0, 0, 0, 33, 21892, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Azaloth - On Spellhit - Kill Credit');
-- Monitoring the Rift: Sundered Chasm 3.3.5
UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry`=25308;
DELETE FROM `smart_scripts` WHERE `entryorguid`=25308 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(25308,0,0,0,8,0,100,0,45414,0,0,0,33,25308,0,0,0,0,0,7,0,0,0,0,0,0,0,'Borean - Westrift Chasm Anomaly - On Spell Hit - Give Quest Credit');
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=25309;
DELETE FROM `smart_scripts` WHERE `entryorguid`=25309 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(25309,0,0,0,8,0,100,0,45414,0,0,0,33,25309,0,0,0,0,0,7,0,0,0,0,0,0,0,'Borean - Westrift Cavern Anomaly - On Spell Hit - Give Quest Credit');
@@ -0,0 +1,5 @@
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN(19067,19210);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (19067,19210);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(19067, 0, 0, 0, 8, 0, 100, 0, 33531, 0, 0, 0, 33, 19067 , 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 'Fel Cannon: Hate - On Spellhit - Kill Credit'),
(19210, 0, 0, 0, 8, 0, 100, 0, 33532, 0, 0, 0, 33, 19210 , 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 'Fel Cannot: Fear - On Spellhit - Kill Credit');
@@ -0,0 +1,18 @@
UPDATE `achievement_criteria_data` SET `value2` = 3 WHERE `type`=8 AND `criteria_id` IN (2358, 2412, 3384);
UPDATE `achievement_criteria_data` SET `type` = 0 WHERE `type`=8 AND `criteria_id` IN (12066, 12067, 12132);
DELETE FROM `achievement_criteria_data` WHERE `criteria_id` IN (4944,4946,4948,4949,4950,4951,4952,4953,4954,4955,4956,4957,4958);
INSERT INTO `achievement_criteria_data` (`criteria_id`, `type`, `value1`, `value2`, `ScriptName`) VALUES
(4944, 0, 0, 0, ''), -- no criteria data
(4946,11, 0, 0, 'achievement_killed_exp_or_honor_target'),
(4948, 8, 1, 0, ''), -- Beast
(4949, 8, 3, 0, ''), -- Dragonkin
(4950, 8, 2, 0, ''), -- drachkin
(4951, 8, 4, 0, ''), -- Elemental
(4952, 8, 5, 0, ''), -- Giant
(4953, 8, 7, 0, ''), -- Humanoid
(4954, 8, 9, 0, ''), -- Mechanical
(4955, 8, 6, 0, ''), -- Undead
(4956, 8, 10, 0, ''), -- Not specified
(4957, 8, 11, 0, ''), -- Totem
(4958, 8, 12, 0, ''); -- Non-Combat Pet
@@ -0,0 +1,65 @@
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=41427 WHERE `entryorguid`=23219 AND `id`=6 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43384 WHERE `entryorguid`=23652 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43341 WHERE `entryorguid`=23678 AND `id`=6 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43174 WHERE `entryorguid`=23689 AND `id`=2 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43174 WHERE `entryorguid`=24170 AND `id`=1 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43806 WHERE `entryorguid`=24439 AND `id`=3 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=45627 WHERE `entryorguid`=25471 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=45628 WHERE `entryorguid`=25472 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=45629 WHERE `entryorguid`=25473 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=46443 WHERE `entryorguid`=25752 AND `id`=2 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=46445 WHERE `entryorguid`=25752 AND `id`=2 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47009 WHERE `entryorguid`=26270 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47665 WHERE `entryorguid`=26482 AND `id`=1 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47664 WHERE `entryorguid`=26615 AND `id`=2 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=50473 WHERE `entryorguid`=27409 AND `id`=5 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=48813 WHERE `entryorguid`=27482 AND `id`=4 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=50290 WHERE `entryorguid`=28013 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=51279 WHERE `entryorguid`=28156 AND `id`=1 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=56940 WHERE `entryorguid`=29445 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=55289 WHERE `entryorguid`=29747 AND `id`=1 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=58599 WHERE `entryorguid`=31048 AND `id`=2 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=58955 WHERE `entryorguid`=31304 AND `id`=7 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=61748 WHERE `entryorguid`=32588 AND `id`=5 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=65374 WHERE `entryorguid`=34365 AND `id`=1 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=40347 WHERE `entryorguid`=2061000 AND `id`=1 AND `source_type`=9;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=40347 WHERE `entryorguid`=2077700 AND `id`=2 AND `source_type`=9;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47683 WHERE `entryorguid`=2642000 AND `id`=5 AND `source_type`=9;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47685 WHERE `entryorguid`=2648400 AND `id`=5 AND `source_type`=9;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=59876 WHERE `entryorguid`=3244501 AND `id`=0 AND `source_type`=9;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=75197 WHERE `entryorguid`=4032900 AND `id`=7 AND `source_type`=9;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=11024,`action_param2`=0,`action_param3`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0,`target_o`=0 WHERE `entryorguid`=7572 AND `source_type`=0 AND `id`=3 AND `link`=4;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43160,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=23777 AND `source_type`=0 AND `id`=2 AND `link`=3;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43326,`action_param2`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0,`target_o`=0 WHERE `entryorguid`=23931 AND `source_type`=0 AND `id`=5 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43289,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=24210 AND `source_type`=0 AND `id`=0 AND `link`=1;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=43787,`action_param2`=0,`action_param3`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0 WHERE `entryorguid`=24399 AND `source_type`=0 AND `id`=5 AND `link`=0;
UPDATE `smart_scripts` SET `event_param3`=0,`event_param4`=0 WHERE `entryorguid`=12900 AND `source_type`=0 AND `id` IN (0,1) AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=48550,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=26633 AND `source_type`=0 AND `id`=4 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47315,`action_param2`=0 WHERE `entryorguid`=26699 AND `source_type`=0 AND `id`=0 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=52030 WHERE `entryorguid`=28565 AND `source_type`=0 AND `id`=1 AND `link`=2;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=52220 WHERE `entryorguid`=28669 AND `source_type`=0 AND `id`=2 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57911,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30829 AND `source_type`=0 AND `id`=1 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57892,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30830 AND `source_type`=0 AND `id`=1 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57917,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30831 AND `source_type`=0 AND `id`=1 AND `link`=0;
-- Remove SPELL_AURA_CONTROL_VEHICLE from addon template
UPDATE `creature_template_addon` SET `auras`='50494' WHERE `entry`=28006;
UPDATE `creature_template_addon` SET `auras`='' WHERE `entry` IN (27661,28093,29838);
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=74154 WHERE `entryorguid`=1268 AND `id`=4 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=42337 WHERE `entryorguid`=4351 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=42337 WHERE `entryorguid`=4352 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=42486 WHERE `entryorguid`=4393 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=42486 WHERE `entryorguid`=4394 AND `id`=0 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=60111 WHERE `entryorguid`=5284 AND `id`=0 AND `source_type`=2;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=60112 WHERE `entryorguid`=5285 AND `id`=0 AND `source_type`=2;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=60115 WHERE `entryorguid`=5286 AND `id`=0 AND `source_type`=2;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=60117 WHERE `entryorguid`=5287 AND `id`=0 AND `source_type`=2;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=74156 WHERE `entryorguid`=6119 AND `id`=4 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=74155 WHERE `entryorguid`=7955 AND `id`=3 AND `source_type`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=61314 WHERE `entryorguid` IN (15273,15274,15294,15298) AND `id` IN (0,1) AND `source_type`=0;
-- Meeting the Warchief prevquest
UPDATE `quest_template` SET `PrevQuestId`=9812 WHERE `Id`=9813;
-- Report to Orgnil prevquest
UPDATE `quest_template` SET `PrevQuestId`=805 WHERE `Id`=823;
@@ -0,0 +1,14 @@
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57910,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30838 AND `source_type`=0 AND `id`=1 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57890,`action_param2`=0,`action_param3`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0,`target_o`=0 WHERE `entryorguid`=30838 AND `source_type`=0 AND `id`=7 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57916,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30839 AND `source_type`=0 AND `id`=1 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57916,`action_param2`=0,`action_param3`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0,`target_o`=0 WHERE `entryorguid`=30839 AND `source_type`=0 AND `id`=7 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57910,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30840 AND `source_type`=0 AND `id`=1 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57913,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=30840 AND `source_type`=0 AND `id`=4 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=57910,`action_param2`=0,`action_param3`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0,`target_o`=0 WHERE `entryorguid`=30840 AND `source_type`=0 AND `id`=9 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=34539,`action_param2`=0 WHERE `entryorguid` IN (1972300,1972400) AND `source_type`=9 AND `id`=0 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=39217,`action_param2`=0,`action_param3`=0,`target_type`=1,`target_x`=0,`target_y`=0,`target_z`=0 WHERE `entryorguid`=2245801 AND `source_type`=9 AND `id`=7 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=47303,`action_param2`=0,`action_param3`=0 WHERE `entryorguid`=2667800 AND `source_type`=9 AND `id` IN (0,1,2,3,4);
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=55383,`action_param2`=0,`action_param3`=0,`target_type`=0,`target_x`=0,`target_y`=0,`target_z`=0,`target_o`=0 WHERE `entryorguid`=2986100 AND `source_type`=9 AND `id`=0 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=56243,`action_param2`=0,`action_param3`=0,`action_param5`=0 WHERE `entryorguid`=2991401 AND `source_type`=9 AND `id`=0 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=46443 WHERE `entryorguid` IN (25753,25758) AND `source_type`=0 AND `id`=4 AND `link`=0;
UPDATE `smart_scripts` SET `action_type`=11,`action_param1`=46443 WHERE `entryorguid`=25792 AND `source_type`=0 AND `id`=2 AND `link`=0;
@@ -0,0 +1,3 @@
DELETE FROM `gameobject_template` WHERE `entry`=188509;
INSERT INTO `gameobject_template` (`entry`, `type`, `displayId`, `name`, `IconName`, `castBarCaption`, `unk1`, `faction`, `flags`, `size`, `questItem1`, `questItem2`, `questItem3`, `questItem4`, `questItem5`, `questItem6`, `data0`, `data1`, `data2`, `data3`, `data4`, `data5`, `data6`, `data7`, `data8`, `data9`, `data10`, `data11`, `data12`, `data13`, `data14`, `data15`, `data16`, `data17`, `data18`, `data19`, `data20`, `data21`, `data22`, `data23`, `AIName`, `ScriptName`, `WDBVerified`) VALUES
(188509, 6, 2770, 'Dark Iron Mole Machine (Minion Summoner Trap)', '', '', '', 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 47375, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 17371);
@@ -0,0 +1,538 @@
-- Quest Chain: http://www.wowhead.com/quest=13213/battle-at-valhalas#see-also
-- Battle at Valhalas: Fallen Heroes
-- Battle at Valhalas: Khit'rix the Dark Master
-- Battle at Valhalas: The Return of Sigrid Iceborn
-- Battle at Valhalas: Carnage!
-- Battle at Valhalas: Thane Deathblow
-- Battle at Valhalas: Final Challenge
SET @NPC_GEIRRVIF := 31135;
SET @QUEST_FALLENHEROES := 13214;
SET @NPC_ELDRETH_13214 := 31195;
SET @NPC_GENESS_13214 := 31193;
SET @NPC_JHADRAS_13214 := 31191;
SET @NPC_MASUD_13214 := 31192;
SET @NPC_RITH_13214 := 31196;
SET @NPC_TALLA_13214 := 31194;
SET @QUEST_KDARKMASTER := 13215;
SET @NPC_KHITRIX_13215 := 31222;
SET @NPC_BONESPIDER_13215 := 32484;
SET @QUEST_SIGRIDICEBORN := 13216;
SET @NPC_SIGRID_13216 := 31242;
SET @NPC_SIGRID_MOUNT := 30159;
SET @QUEST_CARNAGE := 13217;
SET @NPC_CARNAGE_13217 := 31271;
SET @QUEST_THANE := 13218;
SET @NPC_THANE_13218 := 31277;
SET @QUEST_FINCHAL := 13219;
SET @NPC_PRINCESAND_13219 := 14688;
SET @NPC_GENERIC_BUNNY := 24110;
SET @CHEER_SOUND := 14998;
SET @KILL_13214 := 20;
SET @WIPE_13214 := 19;
SET @CREDIT_13214 := 1;
SET @CREDIT_13215 := 2;
SET @CREDIT_13216 := 3;
SET @CREDIT_13217 := 4;
SET @CREDIT_13218 := 5;
SET @CREDIT_13219 := 6;
SET @DESPAWN_13219 := 7;
-- Quest Progression
UPDATE `creature_template` SET `InhabitType` = 4 WHERE `entry` = 31135;
UPDATE `quest_template` SET `PrevQuestId`=13213 WHERE `Id`=13214;
UPDATE `quest_template` SET `PrevQuestId`=13214 WHERE `Id`=13215;
UPDATE `quest_template` SET `PrevQuestId`=13215 WHERE `Id`=13216;
UPDATE `quest_template` SET `PrevQuestId`=13216 WHERE `Id`=13217;
UPDATE `quest_template` SET `PrevQuestId`=13217 WHERE `Id`=13218;
UPDATE `quest_template` SET `PrevQuestId`=13218 WHERE `Id`=13219;
-- Proper template data
UPDATE `creature_template` SET `minlevel`=80, `maxlevel`=80, `mindmg`=311, `maxdmg`=474, `attackpower`=478, `minrangedmg`=344, `maxrangedmg`=490, `rangedattackpower`=80 WHERE `entry`=31242;
UPDATE `creature_template` SET `minlevel`=80, `maxlevel`=80, `mindmg`=417, `maxdmg`=582, `attackpower`=608, `minrangedmg`=341, `maxrangedmg`=506, `rangedattackpower`=80 WHERE `entry`=31271;
UPDATE `creature_template` SET `minlevel`=80, `maxlevel`=80, `mindmg`=445, `maxdmg`=621, `attackpower`=642, `minrangedmg`=289, `maxrangedmg`=381, `rangedattackpower`=69 WHERE `entry`=31277;
UPDATE `creature_template` SET `mindmg`=217, `maxdmg`=389, `attackpower`=357, `minrangedmg`=211, `maxrangedmg`=378, `rangedattackpower`=80 WHERE `entry`=31192;
UPDATE `creature_template` SET `mindmg`=299, `maxdmg`=411, `attackpower`=394, `minrangedmg`=373, `maxrangedmg`=541, `rangedattackpower`=69 WHERE `entry`=31193;
UPDATE `creature_template` SET `mindmg`=254, `maxdmg`=371, `attackpower`=294, `minrangedmg`=344, `maxrangedmg`=490, `rangedattackpower`=80 WHERE `entry`=31194;
UPDATE `creature_template` SET `mindmg`=417, `maxdmg`=682, `attackpower`=608, `minrangedmg`=341, `maxrangedmg`=506, `rangedattackpower`=80 WHERE `entry`=31196;
-- Template updates for creature 31191 (Father Jhadras)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|32768 WHERE `entry`=31191; -- Father Jhadras
-- Equipment of 31191 (Father Jhadras)
DELETE FROM `creature_equip_template` WHERE `entry`=31191;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(31191,1,13220,0,0);
-- Model data 27584 (creature 31191 (Father Jhadras))
UPDATE `creature_model_info` SET `bounding_radius`=0.173611,`combat_reach`=0.75,`gender`=0 WHERE `modelid`=27584; -- Father Jhadras
-- Addon data for creature 31191 (Father Jhadras)
DELETE FROM `creature_template_addon` WHERE `entry`=31191;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31191,0,0,1,0, NULL); -- Father Jhadras
-- Template updates for creature 31193 (Geness Half-Soul)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|32768 WHERE `entry`=31193; -- Geness Half-Soul
-- Model data 27580 (creature 31193 (Geness Half-Soul))
UPDATE `creature_model_info` SET `bounding_radius`=0.1909721,`combat_reach`=0.825,`gender`=0 WHERE `modelid`=27580; -- Geness Half-Soul
-- Addon data for creature 31193 (Geness Half-Soul)
DELETE FROM `creature_template_addon` WHERE `entry`=31193;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31193,0,0,1,0, NULL); -- Geness Half-Soul
-- Template updates for creature 31192 (Masud)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|32768 WHERE `entry`=31192; -- Masud
-- Equipment of 31192 (Masud)
DELETE FROM `creature_equip_template` WHERE `entry`=31192;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(31192,1,30388,0,0);
-- Model data 27582 (creature 31192 (Masud))
UPDATE `creature_model_info` SET `bounding_radius`=0.2951387,`combat_reach`=1.275,`gender`=0 WHERE `modelid`=27582; -- Masud
-- Addon data for creature 31192 (Masud)
DELETE FROM `creature_template_addon` WHERE `entry`=31192;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31192,0,0,1,0, NULL); -- Masud
-- Template updates for creature 31196 (Rith)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|32768 WHERE `entry`=31196; -- Rith
-- Equipment of 31196 (Rith)
DELETE FROM `creature_equip_template` WHERE `entry`=31196;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(31196,1,29631,0,0);
-- Model data 27583 (creature 31196 (Rith))
UPDATE `creature_model_info` SET `bounding_radius`=0.2083332,`combat_reach`=0.9,`gender`=0 WHERE `modelid`=27583; -- Rith
-- Addon data for creature 31196 (Rith)
DELETE FROM `creature_template_addon` WHERE `entry`=31196;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31196,0,0,1,0, NULL); -- Rith
-- Template updates for creature 31194 (Talla)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|32768,`unit_class`=4 WHERE `entry`=31194; -- Talla
-- Equipment of 31194 (Talla)
DELETE FROM `creature_equip_template` WHERE `entry`=31194;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(31194,1,34283,0,0);
-- Model data 27906 (creature 31194 (Talla))
UPDATE `creature_model_info` SET `bounding_radius`=0.1562499,`combat_reach`=0.675,`gender`=0 WHERE `modelid`=27906; -- Talla
-- Addon data for creature 31194 (Talla)
DELETE FROM `creature_template_addon` WHERE `entry`=31194;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31194,0,0,1,0, NULL); -- Talla
-- Template updates for creature 31222 (Khit'rix the Dark Master)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|33600 WHERE `entry`=31222;
-- Khit'rix the Dark Master
-- Model data 25269 (creature 31222 (Khit'rix the Dark Master))
UPDATE `creature_model_info` SET `bounding_radius`=1.24,`combat_reach`=4,`gender`=0 WHERE `modelid`=25269; -- Khit'rix the Dark Master
-- Addon data for creature 31222 (Khit'rix the Dark Master)
DELETE FROM `creature_template_addon` WHERE `entry`=31222;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31222,0,0,1,0, NULL); -- Khit'rix the Dark Master
-- Template updates for creature 31242 (Sigrid Iceborn)
UPDATE `creature_template` SET `faction_A`=14,`faction_H`=14,`exp`=2,`minlevel`=80,`maxlevel`=80,`unit_flags`=`unit_flags`|33600 WHERE `entry`=31242; -- Sigrid Iceborn
-- Equipment of 31242 (Sigrid Iceborn)
DELETE FROM `creature_equip_template` WHERE `entry`=31242;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(31242,1,40436,0,0);
-- Model data 27528 (creature 31242 (Sigrid Iceborn))
UPDATE `creature_model_info` SET `bounding_radius`=0.465,`combat_reach`=1.5,`gender`=1 WHERE `modelid`=27528;
-- Sigrid Iceborn
-- Addon data for creature 31242 (Sigrid Iceborn)
DELETE FROM `creature_template_addon` WHERE `entry`=31242;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31242,0,0,1,0, '');
-- Sigrid Iceborn
UPDATE `creature_template` SET `speed_run`=3.14286 WHERE `entry`=30159;
-- Sigrid Iceborn's Proto Drake
DELETE FROM `creature_template_addon` WHERE `entry`=30159;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(30159,0,33554432,1,0, ''); -- Addon data for creature 30159 (Sigrid Iceborn's Proto Drake)
-- Template updates for creature 31271 (Carnage)
UPDATE `creature_template` SET `faction_A`=14,`faction_H`=14,`exp`=2,`minlevel`=80,`maxlevel`=80,`unit_flags`=`unit_flags`|33600 WHERE `entry`=31271; -- Carnage
-- Model data 24301 (creature 31271 (Carnage))
UPDATE `creature_model_info` SET `bounding_radius`=0.62,`combat_reach`=9,`gender`=0 WHERE `modelid`=24301; -- Carnage
-- Addon data for creature 31271 (Carnage)
DELETE FROM `creature_template_addon` WHERE `entry`=31271;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31271,0,0,1,0, NULL); -- Carnage
-- Template updates for creature 31277 (Thane Banahogg)
UPDATE `creature_template` SET `faction_A`=2116,`faction_H`=2116,`exp`=2,`minlevel`=80,`maxlevel`=80,`unit_flags`=`unit_flags`|33600,`speed_walk`=1.6,`speed_run`=1.71429 WHERE `entry`=31277; -- Thane Banahogg
-- Equipment of 31277 (Thane Banahogg)
DELETE FROM `creature_equip_template` WHERE `entry`=31277;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(31277,1,43578,0,0);
-- Model data 27551 (creature 31277 (Thane Banahogg))
UPDATE `creature_model_info` SET `bounding_radius`=0.6076385,`combat_reach`=2.625,`gender`=0 WHERE `modelid`=27551; -- Thane Banahogg
-- Addon data for creature 31277 (Thane Banahogg)
DELETE FROM `creature_template_addon` WHERE `entry`=31277;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(31277,0,0,1,0, NULL); -- Thane Banahogg
-- Template updates for creature 14688 (Prince Sandoval)
UPDATE `creature_template` SET `faction_A`=21,`faction_H`=21,`unit_flags`=`unit_flags`|33600,`speed_walk`=2,`speed_run`=2.14286 WHERE `entry`=14688; -- Prince Sandoval
-- Equipment of 14688 (Prince Sandoval)
DELETE FROM `creature_equip_template` WHERE `entry`=14688;
INSERT INTO `creature_equip_template` (`entry`,`id`,`itemEntry1`,`itemEntry2`,`itemEntry3`) VALUES
(14688,1,31311,0,0);
-- Model data 27555 (creature 14688 (Prince Sandoval))
UPDATE `creature_model_info` SET `bounding_radius`=0.62,`combat_reach`=2,`gender`=0 WHERE `modelid`=27555; -- Prince Sandoval
-- Addon data for creature 14688 (Prince Sandoval)
DELETE FROM `creature_template_addon` WHERE `entry`=14688;
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
(14688,0,0,0,0, NULL); -- Prince Sandoval
UPDATE `creature_template` SET `faction_A`=16, `faction_H`=16, `AIName`='SmartAI' WHERE `entry` IN (@NPC_ELDRETH_13214, @NPC_GENESS_13214, @NPC_JHADRAS_13214, @NPC_MASUD_13214, @NPC_TALLA_13214, @NPC_RITH_13214);
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_ELDRETH_13214 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_ELDRETH_13214, 0, 0, 0, 0, 0, 80, 0, 0, 0, 6000, 12000, 11, 34829, 2, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Eldreth - IC - Cast Arcane Shot'),
(@NPC_ELDRETH_13214, 0, 1, 0, 0, 0, 80, 0, 10000, 20000, 10000, 20000, 11, 44475, 2, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Eldreth - IC - Cast Magic Dampening Field'),
(@NPC_ELDRETH_13214, 0, 2, 0, 9, 0, 80, 0, 5, 30, 3000, 6000, 11, 15620, 2, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Eldreth - On range - Cast Shoot'),
(@NPC_ELDRETH_13214, 0, 3, 0, 6, 0, 100, 1, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 11, @NPC_GENERIC_BUNNY, 100, 0, 0, 0, 0, 0, 'Eldreth - On death - Set Data'),
(@NPC_ELDRETH_13214, 0, 4, 0, 21, 0, 100, 0, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Eldreth - On reach home - Despawn self'),
(@NPC_ELDRETH_13214, 0, 5, 0, 21, 0, 100, 0, 0, 0, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Eldreth - On reach home - Set Data'),
(@NPC_ELDRETH_13214, 0, 6, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0,0, 0, 0, 'Eldreth - On kill target - Set Data');
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_GENESS_13214 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_GENESS_13214, 0, 0, 0, 0, 0, 80, 0, 2000, 6000, 3000, 7000, 11, 61041, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Geness Half-Soul - IC - Cast Brutal Fist'),
(@NPC_GENESS_13214, 0, 1, 0, 13, 0, 80, 0, 10000, 15000, 0, 0, 11, 46182, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Geness Half-Soul - On target Cast - Cast Snap Kick'),
(@NPC_GENESS_13214, 0, 2, 0, 6, 0, 100, 1, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 11, @NPC_GENERIC_BUNNY, 100, 0, 0, 0, 0, 0, 'Geness Half-Soul - On death - Set Data'),
(@NPC_GENESS_13214, 0, 3, 0, 21, 0, 100, 0, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Geness Half-Soul - On reach home - Despawn self'),
(@NPC_GENESS_13214, 0, 4, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Geness Half-Soul - On kill target - Set Data'),
(@NPC_GENESS_13214, 0, 5, 0, 21, 0, 100, 0, 0, 0, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Geness Half-Soul - On reach home - Set Data');
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_JHADRAS_13214 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_JHADRAS_13214, 0, 0, 0, 14, 0, 80, 0, 50, 40, 10000, 30000, 11, 15586, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Father Jhadras - On friendly hp deficit - Cast Heal'),
(@NPC_JHADRAS_13214, 0, 1, 0, 0, 0, 80, 0, 0, 3000, 8000, 12000, 11, 25054, 0, 0, 0, 0, 0, 5, 0, 0, 40, 0, 0, 0, 0, 'Father Jhadras - IC - Cast Holy Smite'),
(@NPC_JHADRAS_13214, 0, 2, 0, 6, 0, 100, 1, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 11, @NPC_GENERIC_BUNNY, 100, 0, 0, 0, 0, 0, 'Father Jhadras - On death - Set Data'),
(@NPC_JHADRAS_13214, 0, 3, 0, 21, 0, 100, 0, 0, 0, 0, 0, 41, 5000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Father Jhadras - On reach home - Despawn self'),
(@NPC_JHADRAS_13214, 0, 4, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Father Jhadras - On kill target - Set Data'),
(@NPC_JHADRAS_13214, 0, 5, 0, 21, 0, 100, 0, 0, 0, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0,0, 'Father Jhadras - On reach home - Set Data');
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_MASUD_13214 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_MASUD_13214, 0, 0, 0, 0, 0, 80, 0, 0, 0, 15000, 25000, 11, 41056, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Masud - IC - Cast Whirlwind'),
(@NPC_MASUD_13214, 0, 1, 0, 0, 0, 80, 0, 0, 0, 10000, 20000, 11, 15496, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Masud - IC - Cast Cleave'),
(@NPC_MASUD_13214, 0, 2, 0, 6, 0, 100, 1, 0, 0, 0, 0, 45, 4, 4, 0, 0, 0, 0, 11, @NPC_GENERIC_BUNNY, 100, 0, 0, 0, 0, 0, 'Masud - On death - Set Data'),
(@NPC_MASUD_13214, 0, 3, 0, 21, 0, 100, 0, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Masud - On reach home - Despawn self'),
(@NPC_MASUD_13214, 0, 4, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Masud - On kill target - Set Data'),
(@NPC_MASUD_13214, 0, 5, 0, 21, 0, 100, 0, 0, 0, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0,0, 'Masud - On reach home - Set Data');
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_RITH_13214 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_RITH_13214, 0, 0, 0, 0, 0, 80, 0, 0, 0, 10000, 20000, 11, 61044, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Rith - IC - Cast Demoralizing Shout'),
(@NPC_RITH_13214, 0, 1, 0, 0, 0, 80, 0, 0, 0, 20000, 30000, 11, 58461, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Rith - IC - Cast Sunder Armor'),
(@NPC_RITH_13214, 0, 2, 0, 6, 0, 100, 1, 0, 0, 0, 0, 45, 5, 5, 0, 0, 0, 0, 11, @NPC_GENERIC_BUNNY, 100, 0, 0, 0, 0, 0, 'Rith - On death - Set Data'),
(@NPC_RITH_13214, 0, 3, 0, 21, 0, 100, 0, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rith - On reach home - Despawn self'),
(@NPC_RITH_13214, 0, 4, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Rith - On kill target - Set Data'),
(@NPC_RITH_13214, 0, 5, 0, 21, 0, 100, 0, 0, 0, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0,0, 'Rith - On reach home - Set Data');
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_TALLA_13214 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_TALLA_13214, 0, 0, 0, 0, 0, 80, 0, 0, 0, 5000, 15000, 11, 14873, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Talla - IC - Cast Sinister Strike '),
(@NPC_TALLA_13214, 0, 1, 0, 0, 0, 80, 0, 0, 0, 20000, 25000, 11, 30981, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Talla - IC - Cast Crippling PoisOn '),
(@NPC_TALLA_13214, 0, 2, 0, 6, 0, 100, 1, 0, 0, 0, 0, 45, 6, 6, 0, 0, 0, 0, 11, @NPC_GENERIC_BUNNY, 100, 0, 0, 0, 0, 0, 'Talla - On death - Set Data'),
(@NPC_TALLA_13214, 0, 3, 0, 21, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Talla - On reach home - Despawn self'),
(@NPC_TALLA_13214, 0, 4, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Talla - On kill target - Set Data'),
(@NPC_TALLA_13214, 0, 5, 0, 21, 0, 100, 0, 0, 0, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0,0, 'Talla - On reach home - Set Data');
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=@NPC_GENERIC_BUNNY;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_GENERIC_BUNNY AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_GENERIC_BUNNY, 0, 0, 0, 38, 0, 100, 1, 1, 1, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On data set - increment phase 1(1)'),
(@NPC_GENERIC_BUNNY, 0, 1, 0, 38, 0, 100, 1, 2, 2, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On data set - increment phase 2(2)'),
(@NPC_GENERIC_BUNNY, 0, 2, 0, 38, 0, 100, 1, 3, 3, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On data set - increment phase 3(4)'),
(@NPC_GENERIC_BUNNY, 0, 3, 0, 38, 0, 100, 1, 4, 4, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On data set - increment phase 4(8)'),
(@NPC_GENERIC_BUNNY, 0, 4, 0, 38, 0, 100, 1, 5, 5, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On data set - increment phase 5(16)'),
(@NPC_GENERIC_BUNNY, 0, 5, 0, 38, 0, 100, 1, 6, 6, 0, 0, 23, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On data set - increment phase 6(32)'),
(@NPC_GENERIC_BUNNY, 0, 6, 7, 1, 32, 100, 1, 0, 0, 0, 0, 45, @CREDIT_13214, @CREDIT_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Kill trigger - On phase 6(32) - Set Data'),
(@NPC_GENERIC_BUNNY, 0, 7, 0, 61, 32, 100, 0, 0, 0, 0, 0, 78, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Kill trigger - On phase 6(32) - Set Phase 0');
UPDATE `creature_template` SET `faction_A`=16, `faction_H`=16, `AIName`='SmartAI', `unit_flags`=0 WHERE `entry`=@NPC_KHITRIX_13215;
DELETE FROM `creature_text` WHERE `entry`=@NPC_KHITRIX_13215;
INSERT INTO `creature_text` VALUES
(@NPC_KHITRIX_13215,0,0,'When I am done here, I am going to mount your heads upon the walls of Azjol-Nerub!',14,0,0,0,0,0,'Dark Master say 1');
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_KHITRIX_13215, @NPC_KHITRIX_13215*100);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_KHITRIX_13215, 0, 0, 0, 0, 0, 80, 0, 0, 0, 10000, 20000, 11, 38243, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - IC - Cast Mind Flay'),
(@NPC_KHITRIX_13215, 0, 1, 0, 0, 0, 80, 0, 5000, 25000, 5000, 25000, 11, 22884, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - IC - Cast Psychic Scream'),
(@NPC_KHITRIX_13215, 0, 2, 0, 0, 0, 80, 0, 10000, 15000, 120000, 180000, 11, 61055, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - IC - Cast Bone Spiders'),
(@NPC_KHITRIX_13215, 0, 3, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, @NPC_KHITRIX_13215*100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - On summon - Call script 1'),
--
(@NPC_KHITRIX_13215*100, 9, 0, 0, 1, 0, 100, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8197.6045, 3502.557, 625.108032, 0.585, 'Khitrix the Dark Master - OOC script 1 - Move to position'),
(@NPC_KHITRIX_13215*100, 9, 1, 0, 1, 0, 100, 1, 4000, 4000, 0, 0, 1, 0, 10, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - OOC script 1 - Say 1'),
--
(@NPC_KHITRIX_13215, 0, 5, 0, 1, 0, 100, 0, 500, 500, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 50, 0, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - OOC - Start Attack'),
(@NPC_KHITRIX_13215, 0, 6, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - On Kill target - Set Data'),
(@NPC_KHITRIX_13215, 0, 7, 0, 6, 0, 100, 0, 0, 0, 1, 0, 45, @CREDIT_13215, @CREDIT_13215, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - On Death - Set Data'),
(@NPC_KHITRIX_13215, 0, 8, 0, 1, 0, 100, 1, 30000, 30000, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Khitrix the Dark Master - OOC - Set Data');
UPDATE `creature_template` SET `exp`=0, `mindmg`=200, `maxdmg`=300, `dmg_multiplier`=2, `AIName`='SmartAI',`Health_mod`=1 WHERE `entry`=@NPC_BONESPIDER_13215;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@NPC_BONESPIDER_13215 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_BONESPIDER_13215, 0, 0, 0, 0, 0, 80, 0, 0, 0, 10000, 20000, 11, 744, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Bone spiders - IC - Cast Poison'),
(@NPC_BONESPIDER_13215, 0, 1, 0, 1, 0, 100, 0, 500, 500, 0, 0, 49, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Bone Spiders - OOC - Start Attack Random Player');
DELETE FROM `creature_text` WHERE `entry` IN (@NPC_SIGRID_13216);
INSERT INTO `creature_text` VALUES
(@NPC_SIGRID_13216,0,0,'Ah, there you are! Remember me? Of course you do! Wait right there, I''m coming down.',14,0,0,0,0,0,'Sigrid Iceborn say 1'),
(@NPC_SIGRID_13216,1,0,'I told you I''d be better prepared when next we met. I''ve fought and won the Hyldsmeet, trained at Valkyrion, and here I am. Come and get some!',14,0,0,0,0,0,'Sigrid Iceborn say 2');
-- Sigrid Flight WP's
DELETE FROM `waypoints` WHERE entry =@NPC_SIGRID_MOUNT;
INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES
(@NPC_SIGRID_MOUNT, 1, 8258.836, 3599.048, 677.6457, ''),
(@NPC_SIGRID_MOUNT, 2, 8258.059, 3598.419, 677.6457, ''),
(@NPC_SIGRID_MOUNT, 3, 8217.432, 3554.571, 677.6457, ''),
(@NPC_SIGRID_MOUNT, 4, 8169.096, 3473.421, 677.6457, ''),
(@NPC_SIGRID_MOUNT, 5, 8200.269, 3417.768, 673.563, ''),
(@NPC_SIGRID_MOUNT, 6, 8281.517, 3453.952, 673.535, ''),
(@NPC_SIGRID_MOUNT, 7, 8278.022, 3504.947, 677.6457, ''),
(@NPC_SIGRID_MOUNT, 8, 8222.471, 3532.925, 631.09, ''),
(@NPC_SIGRID_MOUNT, 9, 8222.471, 3532.925, 631.09, '');
UPDATE `creature_template` SET `InhabitType` =1 WHERE `entry` =@NPC_SIGRID_13216;
UPDATE `creature_template` SET `InhabitType` =7 WHERE `entry` =@NPC_SIGRID_MOUNT;
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`IN (@NPC_SIGRID_13216,@NPC_SIGRID_MOUNT);
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_SIGRID_13216, @NPC_SIGRID_13216*100,@NPC_SIGRID_MOUNT);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_SIGRID_13216, 0, 0, 0, 9, 0, 80, 0, 0, 2, 15000, 30000, 11, 57635, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On range - Cast Disengage'),
(@NPC_SIGRID_13216, 0, 1, 2, 9, 0, 80, 0, 0, 3, 10000, 30000, 11, 61170, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - IC - Cast Flash Freeze'),
(@NPC_SIGRID_13216, 0, 2, 0, 61, 0, 80, 0, 0, 0, 0, 0, 89, 30, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On Link - Set Random Movement'),
(@NPC_SIGRID_13216, 0, 3, 0, 1, 0, 100, 1, 0, 0, 0, 0, 11, 61165, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - IC - Cast Frostbite Weapon'),
(@NPC_SIGRID_13216, 0, 4, 0, 9, 0, 80, 0, 5, 30, 5000, 25000, 11, 61168, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On range - Cast Throw'),
(@NPC_SIGRID_13216, 0, 5, 0, 9, 0, 100, 0, 30, 100, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - Start Moving - Not in Throw Range'),
(@NPC_SIGRID_13216, 0, 6, 0, 9, 0, 100, 0, 9, 15, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - In Range - Stop Moving at 15 Yard'),
(@NPC_SIGRID_13216, 0, 7, 0, 9, 0, 100, 0, 0, 5, 0, 0, 21, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - Start Moving - Not in Throw Range'),
(@NPC_SIGRID_13216, 0, 8, 0, 9, 0, 100, 0, 5, 30, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - Stop Moving - In Throw Range'),
(@NPC_SIGRID_13216, 0, 9, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, @NPC_SIGRID_13216*100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On summon - Call script 1'),
--
(@NPC_SIGRID_13216*100, 9, 0, 0, 0, 0, 100, 0, 2000, 2000, 2000, 2000, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On summon script 1 - Say 1'),
--
(@NPC_SIGRID_13216, 0, 10, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On kill target - Set Data'),
(@NPC_SIGRID_13216, 0, 11, 0, 6, 0, 100, 0, 0, 0, 1, 0, 45, @CREDIT_13216, @CREDIT_13216, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On death - Set Data'),
(@NPC_SIGRID_13216, 0, 12, 0, 1, 0, 100, 1, 30000, 30000, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Sigrid Iceborn - OOC - Set Data'),
--
(@NPC_SIGRID_MOUNT, 0, 0, 0, 27, 0, 100, 0, 0, 0, 0, 0, 53, 1, @NPC_SIGRID_MOUNT, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn Mount - On Respawn - Start WP movement'),
(@NPC_SIGRID_MOUNT, 0, 1, 2, 40, 0, 100, 1, 9, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn Mount - On WP reached - Despawn'),
(@NPC_SIGRID_MOUNT, 0, 2, 0, 61, 0, 100, 1, 9, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 11, @NPC_SIGRID_13216, 20, 0, 0, 0, 0, 0, 'Sigrid Iceborn Mount - On WP reached - Set Data on Sigrid'),
--
(@NPC_SIGRID_13216, 0, 13, 14, 54, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_SIGRID_MOUNT, 7, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On Link - Summon Mount'),
(@NPC_SIGRID_13216, 0, 14, 0, 61, 0, 100, 0, 0, 0, 0, 0, 11, 46598, 7, 0, 0, 0, 0, 11, @NPC_SIGRID_MOUNT, 100, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On Link - Mount Sigrid''s Proto Drake'),
(@NPC_SIGRID_13216, 0, 15, 16, 38, 0, 100, 1, 1, 1, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On WP reached - Start Attack'),
(@NPC_SIGRID_13216, 0, 16, 17, 61, 0, 100, 1, 0, 0, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 50, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On WP reached - Start Attack'),
(@NPC_SIGRID_13216, 0, 17, 0, 61, 0, 100, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sigrid Iceborn - On Link - Say 2');
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=@NPC_CARNAGE_13217;
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_CARNAGE_13217, @NPC_CARNAGE_13217*100);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_CARNAGE_13217, 0, 1, 0, 0, 0, 80, 0, 10000, 30000, 20000, 40000, 11, 61065, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Carnage - IC - Cast War Stomp'),
(@NPC_CARNAGE_13217, 0, 2, 0, 0, 0, 80, 0, 5000, 12000, 5000, 12000, 11, 61070, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Carnage - IC - Cast Smash'),
(@NPC_CARNAGE_13217, 0, 3, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, @NPC_CARNAGE_13217*100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Carnage - On summon - Call script 1'),
--
(@NPC_CARNAGE_13217*100, 9, 0, 0, 1, 0, 100, 1, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8193.264648, 3496.165771, 625.067322, 0.746269, 'Carnage - OOC script 1 - Move to position'),
--
(@NPC_CARNAGE_13217, 0, 4, 0, 1, 0, 100, 0, 5000, 5000, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 70, 0, 0, 0, 0, 0, 0, 'Carnage - OOC - Start Attack'),
(@NPC_CARNAGE_13217, 0, 5, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Carnage - On kill target - Set Data'),
(@NPC_CARNAGE_13217, 0, 6, 0, 6, 0, 100, 0, 0, 0, 1, 0, 45, @CREDIT_13217, @CREDIT_13217, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Carnage - On death - Set Data'),
(@NPC_CARNAGE_13217, 0, 7, 0, 1, 0, 100, 1, 30000, 30000, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Carnage - OOC - Set Data');
DELETE FROM `creature_text` WHERE `entry` IN (@NPC_THANE_13218);
INSERT INTO `creature_text` VALUES
(@NPC_THANE_13218,0,0,'ENOUGH! You tiny insects are not worthy to do battle within this sacred place!.',14,0,0,0,0,0,'Thane say 1'),
(@NPC_THANE_13218,1,0,'Fight me and die you cowards!',14,0,0,0,0,0,'Thane say 2'),
(@NPC_THANE_13218,2,0,'Haraak foln! ',12,0,0,0,0,0,'Thane say 3');
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=@NPC_THANE_13218;
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_THANE_13218, @NPC_THANE_13218*100);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_THANE_13218, 0, 1, 0, 0, 0, 80, 0, 5000, 10000, 15000, 20000, 11, 13737, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - IC - Cast Mortal Strike'),
(@NPC_THANE_13218, 0, 2, 0, 0, 0, 80, 0, 5000, 10000, 5000, 10000, 11, 61133, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - IC - Cast Punt'),
(@NPC_THANE_13218, 0, 3, 0, 0, 0, 100, 0, 20000, 20000, 20000, 30000, 11, 61134, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - IC - Cast Leap'),
(@NPC_THANE_13218, 0, 5, 0, 12, 0, 100, 0, 0, 20, 5000, 10000, 11, 61140, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - On %hp - Cast Execute'),
(@NPC_THANE_13218, 0, 6, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, @NPC_THANE_13218*100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - On summon - call script 1'),
--
(@NPC_THANE_13218*100, 9, 0, 0, 0, 0, 100, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - OOC script 1 - say 1'),
(@NPC_THANE_13218*100, 9, 1, 0, 0, 0, 100, 1, 5000, 5000, 0, 0, 97, 25, 30, 0, 0, 0, 0, 1, 0, 0, 0, 8169.0015, 3477.075, 626.4695, 0.673769, 'Thane Banahogg - OOC script 1 - Jump to position'),
(@NPC_THANE_13218*100, 9, 2, 0, 0, 0, 100, 1, 2000, 2000, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - OOC script 1 - Set Home Pos'),
(@NPC_THANE_13218*100, 9, 3, 0, 0, 0, 100, 1, 1500, 1500, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - OOC script 1 - Say 2'),
(@NPC_THANE_13218*100, 9, 4, 0, 0, 0, 100, 1, 1000, 1000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - OOC script 1 - Say 3'),
--
(@NPC_THANE_13218, 0, 8, 0, 1, 0, 100, 0, 12000, 12000, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Thane Banahogg - OOC - Start Attack'),
(@NPC_THANE_13218, 0, 9, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Thane Banahogg - On kill target - Set Data'),
(@NPC_THANE_13218, 0, 10, 0, 6, 0, 100, 0, 0, 0, 1, 0, 45, @CREDIT_13218, @CREDIT_13218, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Thane Banahogg - On death - Set Data'),
(@NPC_THANE_13218, 0, 11, 0, 1, 0, 100, 1, 30000, 30000, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Thane Banahogg - OOC - Set Data');
DELETE FROM `creature_text` WHERE `entry` IN (@NPC_PRINCESAND_13219);
INSERT INTO `creature_text` VALUES
(@NPC_PRINCESAND_13219,0,0,'Hardly a fitting introduction , Spear-Wife. Now, who is this outsider that I''ve been hearing so much about?',14,0,0,0,0,0,'Prince Sandoval say 1'),
(@NPC_PRINCESAND_13219,1,0,'I will make this as easy as possible for you. Simply come here and die. That is all that I ask for your many trespasses. For your sullying this exlated place of battle. ',14,0,0,0,0,0,'Prince Sandoval say 2'),
(@NPC_PRINCESAND_13219,2,0,'FOR YOUR EFFRONTERY TO THE LICH KING!',14,0,0,0,0,0,'Prince Sandoval say 3');
UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=@NPC_PRINCESAND_13219;
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_PRINCESAND_13219, @NPC_PRINCESAND_13219*100);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_PRINCESAND_13219, 0, 0, 0, 0, 0, 80, 0, 0, 0, 10000, 20000, 11, 61162, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - IC - Cast Engulfing Strike'),
(@NPC_PRINCESAND_13219, 0, 1, 0, 0, 0, 80, 0, 15000, 20000, 30000, 30000, 11, 61163, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - IC - Cast Fire Nova'),
(@NPC_PRINCESAND_13219, 0, 2, 0, 0, 0, 100, 0, 30000, 30000, 30000, 30000, 11, 61144, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - IC - Cast Fire Shield'),
(@NPC_PRINCESAND_13219, 0, 3, 4, 0, 0, 100, 0, 31100, 31100, 30000, 30000, 11, 61145, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - IC - Cast Ember Shower'),
(@NPC_PRINCESAND_13219, 0, 4, 5, 61, 0, 100, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Change state'),
(@NPC_PRINCESAND_13219, 0, 5, 6, 61, 0, 100, 0, 0, 0, 0, 0, 18, 131077, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Change unit flag'),
(@NPC_PRINCESAND_13219, 0, 6, 0, 61, 0, 100, 0, 0, 0, 0, 0, 103, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Set Root'),
(@NPC_PRINCESAND_13219, 0, 7, 8, 0, 0, 100, 0, 45100, 45100, 30000, 30000, 19, 131077, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - IC - Change unit flag'),
(@NPC_PRINCESAND_13219, 0, 8, 9, 61, 0, 100, 0, 0, 0, 0, 0, 21, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Change state'),
(@NPC_PRINCESAND_13219, 0, 9, 10, 61, 0, 100, 0, 0, 0, 0, 0, 28, 61144, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Remove Fire Shield'),
(@NPC_PRINCESAND_13219, 0, 10, 11, 61, 0, 100, 0, 0, 0, 0, 0, 28, 61145, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link- Remove Ember Shower'),
(@NPC_PRINCESAND_13219, 0, 11, 0, 61, 0, 100, 0, 0, 0, 0, 0, 103, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Remove Root'),
(@NPC_PRINCESAND_13219, 0, 12, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, @NPC_PRINCESAND_13219*100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On summon - Call script 1'),
(@NPC_PRINCESAND_13219, 0, 13, 0, 54, 0, 100, 0, 0, 0, 0, 0, 11, 4335, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On summon - Cast Summon Smoke'),
--
(@NPC_PRINCESAND_13219*100, 9, 0, 0, 1, 0, 100, 1, 4000, 4000, 0, 0, 1, 1, 10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - OOC script 1 - Say 1'),
(@NPC_PRINCESAND_13219*100, 9, 1, 0, 1, 0, 100, 1, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8197.6045, 3502.557, 625.108032, 0.585, 'Prince Sandoval - OOC script 1 - Move to position'),
(@NPC_PRINCESAND_13219*100, 9, 2, 0, 1, 0, 100, 1, 8000, 8000, 0, 0, 1, 2, 10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - OOC script 1 - Say 2'),
--
(@NPC_PRINCESAND_13219, 0, 14, 0, 54, 0, 100, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - OOC script 1 - Say 3'),
(@NPC_PRINCESAND_13219, 0, 15, 0, 1, 0, 100, 0, 14000, 14000, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - OOC - Start Attack'),
(@NPC_PRINCESAND_13219, 0, 16, 0, 5, 0, 100, 0, 0, 0, 0, 0, 45, @KILL_13214, @KILL_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Prince Sandoval - On kill target - Set Data'),
(@NPC_PRINCESAND_13219, 0, 17, 0, 6, 0, 100, 0, 0, 0, 1, 0, 45, @CREDIT_13219, @CREDIT_13219, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Prince Sandoval - On death - Set Data'),
(@NPC_PRINCESAND_13219, 0, 18, 0, 1, 0, 100, 1, 30000, 30000, 0, 0, 45, @WIPE_13214, @WIPE_13214, 0, 0, 0, 0, 11, @NPC_GEIRRVIF, 100, 0, 0, 0, 0, 0, 'Prince Sandoval - OOC - Set Data'),
--
(@NPC_PRINCESAND_13219, 0, 19, 20, 1, 0, 100, 0, 0, 0, 0, 0, 19, 131077, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - OOC - Change state'),
(@NPC_PRINCESAND_13219, 0, 20, 21, 61, 0, 100, 0, 0, 0, 0, 0, 28, 61144, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Remove Fire Shield'),
(@NPC_PRINCESAND_13219, 0, 21, 22, 61, 0, 100, 0, 0, 0, 0, 0, 28, 61145, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link- Remove Ember Shower'),
(@NPC_PRINCESAND_13219, 0, 22, 0, 61, 0, 100, 0, 0, 0, 0, 0, 103, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Prince Sandoval - On Link - Remove Root');
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@NPC_GEIRRVIF;
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@NPC_GEIRRVIF, @NPC_GEIRRVIF*100, @NPC_GEIRRVIF*100+1, @NPC_GEIRRVIF*100+2, @NPC_GEIRRVIF*100+3, @NPC_GEIRRVIF*100+4, @NPC_GEIRRVIF*100+5, @NPC_GEIRRVIF*100+6);
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(@NPC_GEIRRVIF, 0, 0, 0, 19, 0, 100, 0, @QUEST_FALLENHEROES, 0, 0, 0, 80, @NPC_GEIRRVIF*100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On accept quest 1 - Call script 1'),
--
(@NPC_GEIRRVIF*100, 9, 0, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 69, 8216, 3516, 653, 0, 0, 0, 8, 0, 0, 0, 8215.81, 3515.88, 652.885, 3.83972, 'Grieff - OOC script 1 - Move to position'),
(@NPC_GEIRRVIF*100, 9, 1, 0, 1, 0, 100, 1, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 1 - Change npc flag'),
(@NPC_GEIRRVIF*100, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 45, @DESPAWN_13214, @DESPAWN_13214, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 1 - Despawn corpse'),
(@NPC_GEIRRVIF*100, 9, 3, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 1, 0, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 1 - say 0'),
(@NPC_GEIRRVIF*100, 9, 4, 0, 1, 0, 100, 1, 4000, 4000, 0, 0, 1, 1, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 1 - say 1'),
(@NPC_GEIRRVIF*100, 9, 5, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 2, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 1 - say 2'),
(@NPC_GEIRRVIF*100, 9, 6, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 1, 3, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 1 - say 3'),
(@NPC_GEIRRVIF*100, 9, 7, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_JHADRAS_13214, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8222, 3518, 625.162, 3.559, 'Grieff - OOC script 1 - Summon Father Jhadras'),
(@NPC_GEIRRVIF*100, 9, 8, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_MASUD_13214, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8217, 3523, 624.908, 5.236, 'Grieff - OOC script 1 - Summon Masud'),
(@NPC_GEIRRVIF*100, 9, 9, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_GENESS_13214, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8210, 3517, 624.6, 6.143, 'Grieff - OOC script 1 - Summon Geness Half-Soul'),
(@NPC_GEIRRVIF*100, 9, 10, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_TALLA_13214, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8209, 3511, 625.117, 0.571, 'Grieff - OOC script 1 - Summon Talla'),
(@NPC_GEIRRVIF*100, 9, 11, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_ELDRETH_13214, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8198, 3517, 625.838, 0.089, 'Grieff - OOC script 1 - Summon Eldreth'),
(@NPC_GEIRRVIF*100, 9, 12, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_RITH_13214, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8200, 3507, 625.339, 0.514, 'Grieff - OOC script 1 - Summon Rith'),
--
(@NPC_GEIRRVIF, 0, 1, 2, 38, 0, 100, 0, @CREDIT_13214, @CREDIT_13214, 0, 0, 1, 4, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Say 5'),
(@NPC_GEIRRVIF, 0, 2, 3, 61, 0, 100, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 1, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On linked - Move to position'),
(@NPC_GEIRRVIF, 0, 3, 4, 61, 0, 100, 0, 0, 0, 0, 0, 81, 3, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Change npc flag'),
(@NPC_GEIRRVIF, 0, 4, 0, 61, 0, 100, 0, 0, 0, 0, 0, 15, @QUEST_FALLENHEROES, 0, 0, 0, 0, 0, 18, 80, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Kill credit'),
(@NPC_GEIRRVIF, 0, 5, 0, 19, 0, 100, 0, @QUEST_KDARKMASTER, 0, 0, 0, 80, @NPC_GEIRRVIF*100+1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On accept quest 2 - Call script 2'),
--
(@NPC_GEIRRVIF*100+1, 9, 0, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 69, 8216, 3516, 653, 0, 0, 0, 8, 0, 0, 0, 8215.81, 3515.88, 652.885, 3.83972, 'Grieff - OOC script 2 - Move to position'),
(@NPC_GEIRRVIF*100+1, 9, 1, 0, 1, 0, 100, 1, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 2 - Change npc flag'),
(@NPC_GEIRRVIF*100+1, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 45, @DESPAWN_13214, @DESPAWN_13214, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 2 - Despawn corpse'),
(@NPC_GEIRRVIF*100+1, 9, 3, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 1, 5, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 2 - say 5'),
(@NPC_GEIRRVIF*100+1, 9, 4, 0, 1, 0, 100, 1, 4000, 4000, 0, 0, 1, 6, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 2 - say 6'),
(@NPC_GEIRRVIF*100+1, 9, 5, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 7, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 2 - say 7'),
(@NPC_GEIRRVIF*100+1, 9, 6, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_KHITRIX_13215, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8165, 3451, 627.199, 1.935, 'Grieff - OOC script 2 - Summon Khitrix the Dark Master'),
--
(@NPC_GEIRRVIF, 0, 6, 7, 38, 0, 100, 0, @CREDIT_13215, @CREDIT_13215, 0, 0, 1, 8, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Say 8'),
(@NPC_GEIRRVIF, 0, 7, 8, 61, 0, 100, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On linked - Move to position'),
(@NPC_GEIRRVIF, 0, 8, 9, 61, 0, 100, 0, 0, 0, 0, 0, 81, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Change npc flag'),
(@NPC_GEIRRVIF, 0, 9, 0, 61, 0, 100, 0, 0, 0, 0, 0, 15, @QUEST_KDARKMASTER, 0, 0, 0, 0, 0, 18, 80, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Kill credit'),
(@NPC_GEIRRVIF, 0, 10, 0, 19, 0, 100, 0, @QUEST_SIGRIDICEBORN, 0, 0, 0, 80, @NPC_GEIRRVIF*100+2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On accept quest 3 - Call script 3'),
--
(@NPC_GEIRRVIF*100+2, 9, 0, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 69, 8216, 3516, 653, 0, 0, 0, 8, 0, 0, 0, 8215.81, 3515.88, 652.885, 3.83972, 'Grieff - OOC script 3 - Move to position'),
(@NPC_GEIRRVIF*100+2, 9, 1, 0, 1, 0, 100, 0, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 3 - Change npc flag'),
(@NPC_GEIRRVIF*100+2, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 45, @DESPAWN_13214, @DESPAWN_13214, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 3 - Despawn corpse'),
(@NPC_GEIRRVIF*100+2, 9, 3, 0, 1, 0, 100, 1, 0, 0, 0, 0, 1, 9, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 3 - Say 9'),
(@NPC_GEIRRVIF*100+2, 9, 4, 0, 1, 0, 100, 1, 9000, 9000, 0, 0, 1, 10, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 3 - Say 10'),
(@NPC_GEIRRVIF*100+2, 9, 5, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_SIGRID_13216, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8258.836, 3599.048, 677.6457, 0.383, 'Grieff - OOC script 3 - summon Sigrid Iceborn'),
--
(@NPC_GEIRRVIF, 0, 11, 12, 38, 0, 100, 0, @CREDIT_13216, @CREDIT_13216, 0, 0, 1, 11, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Say 11'),
(@NPC_GEIRRVIF, 0, 12, 13, 61, 0, 100, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On linked - Move to position'),
(@NPC_GEIRRVIF, 0, 13, 14, 61, 0, 100, 0, 0, 0, 0, 0, 81, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Change npc flag'),
(@NPC_GEIRRVIF, 0, 14, 0, 61, 0, 100, 0, 0, 0, 0, 0, 15, @QUEST_SIGRIDICEBORN, 0, 0, 0, 0, 0, 18, 80, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Kill credit'),
(@NPC_GEIRRVIF, 0, 15, 0, 19, 0, 100, 0, @QUEST_CARNAGE, 0, 0, 0, 80, @NPC_GEIRRVIF*100+3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On accept quest 4 - Call Script 4'),
--
(@NPC_GEIRRVIF*100+3, 9, 0, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 69, 8216, 3516, 653, 0, 0, 0, 8, 0, 0, 0, 8215.81, 3515.88, 652.885, 3.83972, 'Grieff - OOC script 4 - Move to position'),
(@NPC_GEIRRVIF*100+3, 9, 1, 0, 1, 0, 100, 0, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 4 - Change npc flag'),
(@NPC_GEIRRVIF*100+3, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 45, @DESPAWN_13214, @DESPAWN_13214, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 4 - Despawn corpse'),
(@NPC_GEIRRVIF*100+3, 9, 3, 0, 1, 0, 100, 1, 0, 0, 0, 0, 1, 12, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 4 - say 13'),
(@NPC_GEIRRVIF*100+3, 9, 4, 0, 1, 0, 100, 1, 4000, 4000, 0, 0, 1, 13, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 4 - say 13'),
(@NPC_GEIRRVIF*100+3, 9, 5, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 14, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 4 - say 14'),
(@NPC_GEIRRVIF*100+3, 9, 6, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_CARNAGE_13217, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8141.532715, 3488.100342, 626.986084, 3.662119, 'Grieff - OOC script 4 - summon Carnage'),
--
(@NPC_GEIRRVIF, 0, 16, 17, 38, 0, 100, 0, @CREDIT_13217, @CREDIT_13217, 0, 0, 1, 15, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Say 15'),
(@NPC_GEIRRVIF, 0, 17, 18, 61, 0, 100, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On linked - Move to position'),
(@NPC_GEIRRVIF, 0, 18, 19, 61, 0, 100, 0, 0, 0, 0, 0, 81, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Change npc flag'),
(@NPC_GEIRRVIF, 0, 19, 0, 61, 0, 100, 0, 0, 0, 0, 0, 15, @QUEST_CARNAGE, 0, 0, 0, 0, 0, 18, 80, 0, 0, 0, 0, 0, 0, 'Grieff - On Link - Kill credit'),
(@NPC_GEIRRVIF, 0, 20, 0, 19, 0, 100, 0, @QUEST_THANE, 0, 0, 0, 80, @NPC_GEIRRVIF*100+4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On accept quest 5 - Call script 5'),
--
(@NPC_GEIRRVIF*100+4, 9, 0, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 69, 8216, 3516, 653, 0, 0, 0, 8, 0, 0, 0, 8215.81, 3515.88, 652.885, 3.83972, 'Grieff - OOC script 5 - Move to position'),
(@NPC_GEIRRVIF*100+4, 9, 1, 0, 1, 0, 100, 0, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 5 - Change npc flag'),
(@NPC_GEIRRVIF*100+4, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 45, @DESPAWN_13214, @DESPAWN_13214, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 5 - Despawn corpse'),
(@NPC_GEIRRVIF*100+4, 9, 3, 0, 1, 0, 100, 1, 0, 0, 0, 0, 1, 16, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 5 - say 16'),
(@NPC_GEIRRVIF*100+4, 9, 4, 0, 1, 0, 100, 1, 4000, 4000, 0, 0, 1, 17, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 5 - say 17'),
(@NPC_GEIRRVIF*100+4, 9, 5, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 18, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 5 - say 18'),
(@NPC_GEIRRVIF*100+4, 9, 6, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_THANE_13218, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8151.247559, 3462.894043, 672.115662, 0.6877, 'Grieff - OOC script 5 - summon Thane Banahogg'),
--
(@NPC_GEIRRVIF, 0, 21, 22, 38, 0, 100, 0, @CREDIT_13218, @CREDIT_13218, 0, 0, 1, 19, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Say 19'),
(@NPC_GEIRRVIF, 0, 22, 23, 61, 0, 100, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On linked - Move to position'),
(@NPC_GEIRRVIF, 0, 23, 24, 61, 0, 100, 0, 0, 0, 0, 0, 81, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Change npc flag'),
(@NPC_GEIRRVIF, 0, 24, 0, 61, 0, 100, 0, 0, 0, 0, 0, 15, @QUEST_THANE, 0, 0, 0, 0, 0, 18, 80, 0, 0, 0, 0, 0, 0, 'Grieff - On linked - Kill credit'),
(@NPC_GEIRRVIF, 0, 25, 0, 19, 0, 100, 0, @QUEST_FINCHAL, 0, 0, 0, 80, @NPC_GEIRRVIF*100+5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On accept quest 6 - Call script 6'),
--
(@NPC_GEIRRVIF*100+5, 9, 0, 0, 1, 0, 100, 1, 1000, 1000, 0, 0, 69, 8216, 3516, 653, 0, 0, 0, 8, 0, 0, 0, 8215.81, 3515.88, 652.885, 3.83972, 'Grieff - OOC script 6 - Move to position'),
(@NPC_GEIRRVIF*100+5, 9, 1, 0, 1, 0, 100, 0, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 6 - Change npc flag'),
(@NPC_GEIRRVIF*100+5, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 45, @DESPAWN_13214, @DESPAWN_13214, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 6 - Despawn corpse'),
(@NPC_GEIRRVIF*100+5, 9, 3, 0, 1, 0, 100, 1, 0, 0, 0, 0, 1, 20, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 6 - Say 20'),
(@NPC_GEIRRVIF*100+5, 9, 4, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 21, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 6 - Say 21'),
(@NPC_GEIRRVIF*100+5, 9, 5, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 22, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 6 - Say 22'),
(@NPC_GEIRRVIF*100+5, 9, 6, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 23, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 6 - Say 23'),
(@NPC_GEIRRVIF*100+5, 9, 7, 0, 1, 0, 100, 1, 0, 0, 0, 0, 12, @NPC_PRINCESAND_13219, 7, 0, 0, 1, 0, 8, 0, 0, 0, 8182.54, 3489.78, 625.50519, 0.63625, 'Grieff - OOC script 6 - Summon Prince Sandoval'),
--
(@NPC_GEIRRVIF, 0, 26, 27, 38, 0, 100, 0, @CREDIT_13219, @CREDIT_13219, 0, 0, 80, @NPC_GEIRRVIF*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Call script 7'),
--
(@NPC_GEIRRVIF*100+6, 9, 0, 0, 1, 0, 100, 1, 0, 0, 0, 0, 1, 24, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Say 24'),
(@NPC_GEIRRVIF*100+6, 9, 1, 0, 1, 0, 100, 0, 0, 0, 0, 0, 15, @QUEST_FINCHAL, 0, 0, 0, 0, 0, 18, 80, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 7 - Kill credit'),
(@NPC_GEIRRVIF*100+6, 9, 2, 0, 1, 0, 100, 1, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On link - Move to position'),
(@NPC_GEIRRVIF*100+6, 9, 3, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 1, 25, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 7 - Say 25'),
(@NPC_GEIRRVIF*100+6, 9, 4, 0, 1, 0, 100, 1, 6000, 6000, 0, 0, 1, 26, 10, 0, 0, 1, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 7 - Say 26'),
(@NPC_GEIRRVIF*100+6, 9, 5, 0, 1, 0, 100, 1, 0, 0, 0, 0, 81, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - OOC script 7 - Change npc flag'),
--
(@NPC_GEIRRVIF, 0, 27, 0, 38, 0, 100, 0, @KILL_13214, @KILL_13214, 0, 0, 1, 27, 10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Greiff - On data set - Say kill'),
(@NPC_GEIRRVIF, 0, 28, 0, 38, 0, 100, 0, @WIPE_13214, @WIPE_13214, 0, 0, 69, 0, 0, 0, 0, 1, 0, 8, 0, 0, 0, 8216.25, 3516.23, 629.357, 3.83972, 'Grieff - On data set - Move to position'),
(@NPC_GEIRRVIF, 0, 29, 0, 38, 0, 100, 0, @WIPE_13214, @WIPE_13214, 0, 0, 81, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Change npc flag'),
(@NPC_GEIRRVIF, 0, 30, 0, 38, 0, 100, 0, @WIPE_13214, @WIPE_13214, 0, 0, 78, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Grieff - On data set - Script reset'),
(@NPC_GEIRRVIF, 0, 31, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_ELDRETH_13214, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 32, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_GENESS_13214, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 33, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_JHADRAS_13214, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 34, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_MASUD_13214, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 35, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_RITH_13214, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 36, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_TALLA_13214, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 37, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_KHITRIX_13215, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 38, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_SIGRID_13216, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 39, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_CARNAGE_13217, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 40, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_THANE_13218, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse'),
(@NPC_GEIRRVIF, 0, 41, 0, 38, 0, 100, 0, @DESPAWN_13219, @DESPAWN_13219, 0, 0, 41, 0, 0, 0, 0, 0, 0, 11, @NPC_PRINCESAND_13219, 200, 0, 0, 0, 0, 0, 'Grieff - On data set - Despawn corpse');
DELETE FROM `creature_text` WHERE `entry`=@NPC_GEIRRVIF;
INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`) VALUES
(@NPC_GEIRRVIF, 0, 0, 'Valhalas is yours to win or die in, $N. But whatever you do, stay within the bounds of the arena. To flee is to lose and be dishonored.', 12, 0, 0, 0, 0, 0, 'Greiff quest 1 say 1'),
(@NPC_GEIRRVIF, 1, 1, '$N and $g his : her; comrades in arms have chosen to accept honorable combat within the sacred confines of Valhalas.', 14, 0, 0, 0, 0, 0, 'Greiff quest 1 say 2'),
(@NPC_GEIRRVIF, 2, 2, 'There can be only one outcome to such a battle: death for one side or the other. Let $N prove $g himself : herself; upon the bones of those outsiders who have fallen before!', 14, 0, 0, 0, 0, 0, 'Greiff quest 1 say 3'),
(@NPC_GEIRRVIF, 3, 3, 'The fallen heroes of Valhalas emerge from the ground to do battle once more!', 41, 0, 0, 0, 0, 14998, 'Greiff quest 1 say 4'),
(@NPC_GEIRRVIF, 4, 4, '$N has defeated the fallen heroes of Valhalas battles past. This is only a beginning, but it will suffice.', 14, 0, 0, 0, 0, 14998, 'Greiff quest 1 say 5'),
(@NPC_GEIRRVIF, 5, 5, 'Prepare yourself. Khit''rix will be entering Valhalas from the southeast. Remember, do not leave the ring or you will lose the battle.', 12, 0, 0, 0, 0, 0, 'Greiff quest 2 say 1'),
(@NPC_GEIRRVIF, 6, 6, '$N has accepted the challenge of Khit''rix the Dark Master. May the gods show mercy upon $g him : her; for Khit''rix surely will not.', 14, 0, 0, 0, 0, 0, 'Greiff quest 2 say 2'),
(@NPC_GEIRRVIF, 7, 7, 'Khit''rix the Dark Master skitters into Valhalas from the southeast!', 41, 0, 0, 0, 0, 14998, 'Greiff quest 2 say 3'),
(@NPC_GEIRRVIF, 8, 8, 'Khit''rix the Dark Master has been defeated by $N and $g his : her; band of companions. Let the next challenge be issued!', 14, 0, 0, 0, 0, 14998, 'Greiff quest 2 sasy 4'),
(@NPC_GEIRRVIF, 9, 9, 'Sigrid Iceborn has returned to the heights of Jotunheim to prove herself against $N. When last they met, $N bested her in personal combat. Let us see the outcome of this match.', 14, 0, 0, 0, 0, 0, 'Greiff quest 3 say 1'),
(@NPC_GEIRRVIF, 10, 10, 'Circling Valhalas, Sigrid Iceborn approaches to seek her revenge! ', 41, 0, 0, 0, 0, 14998, 'Greiff quest 3 say 2'),
(@NPC_GEIRRVIF, 11, 11, '$N has defeated Sigrid Iceborn for a second time. Well, this time $g he : she; did it with the help of $g his : her; friends, but a win is a win!', 14, 0, 0, 0, 0, 14998, 'Greiff quest 3 say 3'),
(@NPC_GEIRRVIF, 12, 12, 'Carnage is coming! Remember, no matter what you do, do NOT leave the battle ring or I will disqualify you and your group.', 12, 0, 0, 0, 0, 0, 'Greiff quest 4 say 1'),
(@NPC_GEIRRVIF, 13, 13, 'From the bowels of the Underhalls comes Carnage. Brave and foolish $N has accepted the challenge. $G He : She; and $g his : her; group stand ready to face the monstrosity.', 14, 0, 0, 0, 0, 0, 'Greiff quest 4 say 2'),
(@NPC_GEIRRVIF, 14, 14, 'Lumbering in from the south, the smell of Carnage precedes him!', 41, 0, 0, 0, 0, 14998, 'Greiff quest 4 say 3'),
(@NPC_GEIRRVIF, 15, 15, 'The horror known as Carnage is no more. Could it be that $N is truly worthy of battle in Valhalas? We shall see.', 14, 0, 0, 0, 0, 14998, 'Greiff quest 4 say 4'),
(@NPC_GEIRRVIF, 16, 16, 'Look to the southeast and you will see the thane upon the platform near Gjonner the Merciless when he shows himself. Let him come down. Stay within the ring of Valhalas.', 12, 0, 0, 0, 0, 0, 'Greiff quest 5 say 1'),
(@NPC_GEIRRVIF, 17, 17, 'Thane Banahogg returns to Valhalas for the first time in ages to prove that the vrykul are the only beings worthy to fight within its sacred ring. Will $N prove him wrong?', 14, 0, 0, 0, 0, 0, 'Greiff quest 5 say 2'),
(@NPC_GEIRRVIF, 18, 18, 'Thane Banahogg appears upon the overlook to the southeast!', 41, 0, 0, 0, 0, 14998, 'Greiff quest 5 say 3'),
(@NPC_GEIRRVIF, 19, 19, 'Thane Banahogg the Deathblow has fallen to $N and $g his : her; fighting companions. $G He : She; has but one challenge ahead of $g him : her;. Who will it be?', 14, 0, 0, 0, 0, 14998, 'Greiff quest 5 say 4'),
(@NPC_GEIRRVIF, 20, 20, 'It''s too late to run now. Do not leave the ring. Die bravely, $N!', 12, 0, 0, 0, 0, 0, 'Greiff quest 6 say 1'),
(@NPC_GEIRRVIF, 21, 21, 'From the depths of Icecrown Citadel, one of the Lich King''s chosen comes to put an end to the existence of $N and $g his : her; friends.', 14, 0, 0, 0, 0, 0, 'Greiff quest 6 say 2'),
(@NPC_GEIRRVIF, 22, 22, 'Warriors of Jotunheim, I present to you, Blood Prince Sandoval!', 14, 0, 0, 0, 0, 0, 'Greiff quest 6 say 3'),
(@NPC_GEIRRVIF, 23, 23, 'Without warning, Prince Sandoval magically appears within Valhalas! ', 41, 0, 0, 0, 0, 14998, 'Greiff quest 6 say 4'),
(@NPC_GEIRRVIF, 24, 24, 'The unthinkable has happened... $N has slain Prince Sandoval!', 14, 0, 0, 0, 0, 0, 'Greiff quest 6 say 5'),
(@NPC_GEIRRVIF, 25, 25, 'In defeating him, $g he : she; and $g his : her; fighting companions have proven themselves worthy of battle in this most sacred place of vrykul honor.', 14, 0, 0, 0, 0, 0, 'Greiff quest 6 say 6'),
(@NPC_GEIRRVIF, 26, 26, 'ALL HAIL $N, CHAMPION OF VALHALAS!', 14, 0, 0, 0, 0, 14998, 'Greiff quest 6 say 7'),
(@NPC_GEIRRVIF, 27, 27, 'You were not prepared!', 14, 0, 0, 0, 0, 0, 'Greiff kill');
@@ -0,0 +1,4 @@
UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry`=22177;
DELETE FROM `smart_scripts` WHERE `entryorguid`=22177 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(22177,0,0,0,8,0,100,0,38530,0,0,0,33,22177,0,0,0,0,0,7,0,0,0,0,0,0,0,'Eye of Grillok Quest Credit Bunny - On Spellhit (Quest Credit for Eye of Grillok) - Give Kill Credit');
@@ -0,0 +1,7 @@
UPDATE `smart_scripts` SET `link`=3 WHERE `entryorguid` IN (22401,21182,22402,22403) AND `source_type`=0 AND `id`=2 AND `link`=0;
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (22401,21182,22402,22403) AND `source_type`=0 AND `id`=3;
INSERT INTO `smart_scripts` (`entryorguid`, `id`, `event_type`, `action_type`, `action_param1`, `target_type`, `comment`) VALUES
(22401,3,61,33,22401,7,'Zeth''Gor Quest Credit Marker, They Must Burn, Tower North - On spell hit - Give Quest Credit'),
(21182,3,61,33,21182,7,'Zeth''Gor Quest Credit Marker, They Must Burn, Tower South - On spell hit - Give Quest Credit'),
(22402,3,61,33,22402,7,'Zeth''Gor Quest Credit Marker, They Must Burn, Tower Forge - On spell hit - Give Quest Credit'),
(22403,3,61,33,22403,7,'Zeth''Gor Quest Credit Marker, They Must Burn, Tower Foothill - On spell hit - Give Quest Credit');
+2 -1
View File
@@ -508,7 +508,8 @@ namespace VMAP
return false;
}
char ident[8];
char ident[9];
ident[8] = '\0';
int readOperation = 0;
READ_OR_RETURN(&ident, 8);
@@ -699,6 +699,10 @@ void SmartAI::InitializeAI()
void SmartAI::OnCharmed(bool apply)
{
GetScript()->ProcessEventsFor(SMART_EVENT_CHARMED, NULL, 0, 0, apply);
if (!apply && !me->IsInEvadeMode() && me->GetUInt64Value(UNIT_FIELD_CHARMEDBY))
if (Unit* charmer = ObjectAccessor::GetUnit(*me, me->GetUInt64Value(UNIT_FIELD_CHARMEDBY)))
AttackStart(charmer);
}
void SmartAI::DoAction(int32 param)
+24 -11
View File
@@ -1447,7 +1447,6 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
if (!einfo)
{
TC_LOG_ERROR(LOG_FILTER_SQL, "SmartScript: SMART_ACTION_EQUIP uses non-existent equipment info id %u for creature %u", equipId, npc->GetEntry());
delete targets;
break;
}
@@ -1771,10 +1770,14 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
if (!targets)
break;
bool foundTarget = false;
for (ObjectList::const_iterator itr = targets->begin(); itr != targets->end(); ++itr)
{
if (IsCreature((*itr)))
{
foundTarget = true;
if (e.action.moveRandom.distance)
(*itr)->ToCreature()->GetMotionMaster()->MoveRandom((float)e.action.moveRandom.distance);
else
@@ -1782,6 +1785,14 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
}
}
if (!foundTarget && me && IsCreature(me))
{
if (e.action.moveRandom.distance)
me->GetMotionMaster()->MoveRandom((float)e.action.moveRandom.distance);
else
me->GetMotionMaster()->MoveIdle();
}
delete targets;
break;
}
@@ -1991,13 +2002,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
e.GetTargetType() == SMART_TARGET_OWNER_OR_SUMMONER || e.GetTargetType() == SMART_TARGET_ACTION_INVOKER ||
e.GetTargetType() == SMART_TARGET_CLOSEST_ENEMY || e.GetTargetType() == SMART_TARGET_CLOSEST_FRIENDLY)
{
if (ObjectList* targets = GetTargets(e, unit))
{
if (WorldObject* target = targets->front())
(*itr)->ToCreature()->SetHomePosition(target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), target->GetOrientation());
delete targets;
}
(*itr)->ToCreature()->SetHomePosition((*itr)->GetPositionX(), (*itr)->GetPositionY(), (*itr)->GetPositionZ(), (*itr)->GetOrientation());
}
else
TC_LOG_ERROR(LOG_FILTER_SQL, "SmartScript: Action target for SMART_ACTION_SET_HOME_POS is invalid, skipping");
@@ -2294,8 +2299,9 @@ ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*
l->push_back(baseObject);
break;
case SMART_TARGET_VICTIM:
if (me && me->GetVictim())
l->push_back(me->GetVictim());
if (me)
if (Unit* victim = me->GetVictim())
l->push_back(victim);
break;
case SMART_TARGET_HOSTILE_SECOND_AGGRO:
if (me)
@@ -2508,8 +2514,15 @@ ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*
case SMART_TARGET_OWNER_OR_SUMMONER:
{
if (me)
if (Unit* owner = ObjectAccessor::GetUnit(*me, me->GetCharmerOrOwnerGUID()))
{
uint64 charmerOrOwnerGuid = me->GetCharmerOrOwnerGUID();
if (!charmerOrOwnerGuid)
charmerOrOwnerGuid = me->GetCreatorGUID();
if (Unit* owner = ObjectAccessor::GetUnit(*me, charmerOrOwnerGuid))
l->push_back(owner);
}
break;
}
case SMART_TARGET_THREAT_LIST:
@@ -771,6 +771,26 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e)
case SMART_ACTION_SUMMON_CREATURE:
if (!IsCreatureValid(e, e.action.summonCreature.creature))
return false;
for (uint32 i = 0; i < sSpellMgr->GetSpellInfoStoreSize(); ++i)
{
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(i);
if (!spellInfo)
continue;
for (uint32 j = 0; j < MAX_SPELL_EFFECTS; ++j)
{
if (spellInfo->Effects[j].Effect == SPELL_EFFECT_SUMMON)
{
uint32 creatureSummonEntry = spellInfo->Effects[j].MiscValue;
if (e.action.summonCreature.creature == creatureSummonEntry)
TC_LOG_ERROR(LOG_FILTER_SQL, "SmartAIMgr: Entry %d SourceType %u Event %u Action %u creature summon: %u has already summon spell (SpellId: %u effect: %u)",
e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.action.summonCreature.creature, spellInfo->Id, j);
}
}
}
if (e.action.summonCreature.type < TEMPSUMMON_TIMED_OR_DEAD_DESPAWN || e.action.summonCreature.type > TEMPSUMMON_MANUAL_DESPAWN)
{
TC_LOG_ERROR(LOG_FILTER_SQL, "SmartAIMgr: Entry %d SourceType %u Event %u Action %u uses incorrect TempSummonType %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.action.summonCreature.type);
@@ -828,6 +848,25 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e)
case SMART_ACTION_SUMMON_GO:
if (!IsGameObjectValid(e, e.action.summonGO.entry))
return false;
for (uint32 i = 0; i < sSpellMgr->GetSpellInfoStoreSize(); ++i)
{
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(i);
if (!spellInfo)
continue;
for (uint32 j = 0; j < MAX_SPELL_EFFECTS; ++j)
{
if (spellInfo->Effects[j].Effect == SPELL_EFFECT_SUMMON_OBJECT_WILD)
{
uint32 goSummonEntry = spellInfo->Effects[j].MiscValue;
if (e.action.summonGO.entry == goSummonEntry)
TC_LOG_ERROR(LOG_FILTER_SQL, "SmartAIMgr: Entry %d SourceType %u Event %u Action %u gameobject summon: %u has already summon spell (SpellId: %u effect: %u)",
e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.action.summonGO.entry, spellInfo->Id, j);
}
}
}
break;
case SMART_ACTION_ADD_ITEM:
case SMART_ACTION_REMOVE_ITEM:
File diff suppressed because it is too large Load Diff
+47 -78
View File
@@ -82,6 +82,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
switch (criteria->requiredType)
{
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE:
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE:
case ACHIEVEMENT_CRITERIA_TYPE_WIN_BG:
case ACHIEVEMENT_CRITERIA_TYPE_FALL_WITHOUT_DYING:
case ACHIEVEMENT_CRITERIA_TYPE_COMPLETE_QUEST: // only hardcoded list
@@ -116,7 +117,6 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
switch (dataType)
{
case ACHIEVEMENT_CRITERIA_DATA_TYPE_NONE:
case ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE:
case ACHIEVEMENT_CRITERIA_DATA_INSTANCE_SCRIPT:
return true;
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_CREATURE:
@@ -189,6 +189,14 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
return false;
}
return true;
case ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE:
if (value.compType >= COMP_TYPE_MAX)
{
TC_LOG_ERROR(LOG_FILTER_SQL, "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE (%u) has wrong ComparisionType in value2 (%u), ignored.",
value.compType, criteria->requiredType, dataType, value.value);
return false;
}
return true;
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_LEVEL:
if (level.minlevel > STRONG_MAX_LEVEL)
{
@@ -345,7 +353,7 @@ bool AchievementCriteriaData::Meets(uint32 criteria_id, Player const* source, Un
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_AURA:
return target && target->HasAuraEffect(aura.spell_id, aura.effect_idx);
case ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE:
return miscvalue1 >= value.minvalue;
return CompareValues(ComparisionType(value.compType), miscvalue1, value.value);
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_LEVEL:
if (!target)
return false;
@@ -508,103 +516,50 @@ void AchievementMgr::SaveToDB(SQLTransaction& trans)
{
if (!m_completedAchievements.empty())
{
bool need_execute = false;
std::ostringstream ssdel;
std::ostringstream ssins;
for (CompletedAchievementMap::iterator iter = m_completedAchievements.begin(); iter != m_completedAchievements.end(); ++iter)
{
if (!iter->second.changed)
continue;
/// first new/changed record prefix
if (!need_execute)
{
ssdel << "DELETE FROM character_achievement WHERE guid = " << GetPlayer()->GetGUIDLow() << " AND achievement IN (";
ssins << "INSERT INTO character_achievement (guid, achievement, date) VALUES ";
need_execute = true;
}
/// next new/changed record prefix
else
{
ssdel << ',';
ssins << ',';
}
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_ACHIEVEMENT_BY_ACHIEVEMENT);
stmt->setUInt16(0, iter->first);
stmt->setUInt32(1, GetPlayer()->GetGUID());
trans->Append(stmt);
// new/changed record data
ssdel << iter->first;
ssins << '(' << GetPlayer()->GetGUIDLow() << ',' << iter->first << ',' << uint64(iter->second.date) << ')';
stmt = CharacterDatabase.GetPreparedStatement(CHAR_INS_CHAR_ACHIEVEMENT);
stmt->setUInt32(0, GetPlayer()->GetGUID());
stmt->setUInt16(1, iter->first);
stmt->setUInt32(2, uint32(iter->second.date));
trans->Append(stmt);
/// mark as saved in db
iter->second.changed = false;
}
if (need_execute)
{
ssdel << ')';
trans->Append(ssdel.str().c_str());
trans->Append(ssins.str().c_str());
}
}
if (!m_criteriaProgress.empty())
{
/// prepare deleting and insert
bool need_execute_del = false;
bool need_execute_ins = false;
std::ostringstream ssdel;
std::ostringstream ssins;
for (CriteriaProgressMap::iterator iter = m_criteriaProgress.begin(); iter != m_criteriaProgress.end(); ++iter)
{
if (!iter->second.changed)
continue;
// deleted data (including 0 progress state)
{
/// first new/changed record prefix (for any counter value)
if (!need_execute_del)
{
ssdel << "DELETE FROM character_achievement_progress WHERE guid = " << GetPlayer()->GetGUIDLow() << " AND criteria IN (";
need_execute_del = true;
}
/// next new/changed record prefix
else
ssdel << ',';
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_ACHIEVEMENT_PROGRESS_BY_CRITERIA);
stmt->setUInt32(0, GetPlayer()->GetGUID());
stmt->setUInt16(1, iter->first);
trans->Append(stmt);
// new/changed record data
ssdel << iter->first;
if (iter->second.counter)
{
stmt = CharacterDatabase.GetPreparedStatement(CHAR_INS_CHAR_ACHIEVEMENT_PROGRESS);
stmt->setUInt32(0, GetPlayer()->GetGUID());
stmt->setUInt16(1, iter->first);
stmt->setUInt32(2, iter->second.counter);
stmt->setUInt32(3, uint32(iter->second.date));
trans->Append(stmt);
}
// store data only for real progress
if (iter->second.counter != 0)
{
/// first new/changed record prefix
if (!need_execute_ins)
{
ssins << "INSERT INTO character_achievement_progress (guid, criteria, counter, date) VALUES ";
need_execute_ins = true;
}
/// next new/changed record prefix
else
ssins << ',';
// new/changed record data
ssins << '(' << GetPlayer()->GetGUIDLow() << ',' << iter->first << ',' << iter->second.counter << ',' << iter->second.date << ')';
}
/// mark as updated in db
iter->second.changed = false;
}
if (need_execute_del) // DELETE ... IN (.... _)_
ssdel << ')';
if (need_execute_del || need_execute_ins)
{
if (need_execute_del)
trans->Append(ssdel.str().c_str());
if (need_execute_ins)
trans->Append(ssins.str().c_str());
}
}
}
@@ -882,6 +837,20 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
SetCriteriaProgress(achievementCriteria, miscValue2, PROGRESS_ACCUMULATE);
break;
}
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE:
{
// AchievementMgr::UpdateAchievementCriteria might also be called on login - skip in this case
if (!miscValue2)
continue;
// those requirements couldn't be found in the dbc
AchievementCriteriaDataSet const* data = sAchievementMgr->GetCriteriaDataSet(achievementCriteria);
if (!data || !data->Meets(GetPlayer(), unit, miscValue1))
continue;
SetCriteriaProgress(achievementCriteria, miscValue2, PROGRESS_ACCUMULATE);
break;
}
case ACHIEVEMENT_CRITERIA_TYPE_REACH_LEVEL:
if (AchievementCriteriaDataSet const* data = sAchievementMgr->GetCriteriaDataSet(achievementCriteria))
if (!data->Meets(GetPlayer(), unit))
@@ -1301,7 +1270,6 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
SetCriteriaProgress(achievementCriteria, 1);
break;
}
case ACHIEVEMENT_CRITERIA_TYPE_ROLL_NEED_ON_LOOT:
case ACHIEVEMENT_CRITERIA_TYPE_ROLL_GREED_ON_LOOT:
{
@@ -1616,7 +1584,6 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
case ACHIEVEMENT_CRITERIA_TYPE_PLAY_ARENA:
case ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK:
case ACHIEVEMENT_CRITERIA_TYPE_EARNED_PVP_TITLE:
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE:
break; // Not implemented yet :(
}
@@ -1774,6 +1741,7 @@ bool AchievementMgr::IsCompletedCriteria(AchievementCriteriaEntry const* achieve
case ACHIEVEMENT_CRITERIA_TYPE_GOLD_SPENT_AT_BARBER:
case ACHIEVEMENT_CRITERIA_TYPE_GOLD_SPENT_FOR_MAIL:
case ACHIEVEMENT_CRITERIA_TYPE_LOSE_DUEL:
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE:
case ACHIEVEMENT_CRITERIA_TYPE_GOLD_EARNED_BY_AUCTIONS:
case ACHIEVEMENT_CRITERIA_TYPE_CREATE_AUCTION:
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_AUCTION_BID:
@@ -2331,6 +2299,7 @@ void AchievementGlobalMgr::LoadAchievementCriteriaData()
case ACHIEVEMENT_CRITERIA_TYPE_WIN_BG: // any cases
break;
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE:
case ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE:
break; // any cases
case ACHIEVEMENT_CRITERIA_TYPE_COMPLETE_QUEST:
{
@@ -116,7 +116,8 @@ struct AchievementCriteriaData
// ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE = 8
struct
{
uint32 minvalue;
uint32 value;
uint32 compType;
} value;
// ACHIEVEMENT_CRITERIA_DATA_TYPE_T_LEVEL = 9
struct
+5 -5
View File
@@ -82,7 +82,7 @@ bool ArenaTeam::Create(uint64 captainGuid, uint8 type, std::string const& teamNa
// Add captain as member
AddMember(CaptainGuid);
TC_LOG_INFO(LOG_FILTER_ARENAS, "New ArenaTeam created [Id: %u] [Type: %u] [Captain low GUID: %u]", GetId(), GetType(), captainLowGuid);
TC_LOG_INFO(LOG_FILTER_ARENAS, "New ArenaTeam created [Id: %u, Name: %s] [Type: %u] [Captain low GUID: %u]", GetId(), GetName().c_str(), GetType(), captainLowGuid);
return true;
}
@@ -304,9 +304,9 @@ void ArenaTeam::SetCaptain(uint64 guid)
newCaptain->SetArenaTeamInfoField(GetSlot(), ARENA_TEAM_MEMBER, 0);
if (oldCaptain)
{
TC_LOG_DEBUG(LOG_FILTER_BATTLEGROUND, "Player: %s [GUID: %u] promoted player: %s [GUID: %u] to leader of arena team [Id: %u] [Type: %u].",
TC_LOG_DEBUG(LOG_FILTER_BATTLEGROUND, "Player: %s [GUID: %u] promoted player: %s [GUID: %u] to leader of arena team [Id: %u, Name: %s] [Type: %u].",
oldCaptain->GetName().c_str(), oldCaptain->GetGUIDLow(), newCaptain->GetName().c_str(),
newCaptain->GetGUIDLow(), GetId(), GetType());
newCaptain->GetGUIDLow(), GetId(), GetName().c_str(), GetType());
}
}
}
@@ -328,7 +328,7 @@ void ArenaTeam::DelMember(uint64 guid, bool cleanDb)
// delete all info regarding this team
for (uint32 i = 0; i < ARENA_TEAM_END; ++i)
player->SetArenaTeamInfoField(GetSlot(), ArenaTeamInfoType(i), 0);
TC_LOG_DEBUG(LOG_FILTER_ARENAS, "Player: %s [GUID: %u] left arena team type: %u [Id: %u].", player->GetName().c_str(), player->GetGUIDLow(), GetType(), GetId());
TC_LOG_DEBUG(LOG_FILTER_ARENAS, "Player: %s [GUID: %u] left arena team type: %u [Id: %u, Name: %s].", player->GetName().c_str(), player->GetGUIDLow(), GetType(), GetId(), GetName().c_str());
}
// Only used for single member deletion, for arena team disband we use a single query for more efficiency
@@ -353,7 +353,7 @@ void ArenaTeam::Disband(WorldSession* session)
BroadcastEvent(ERR_ARENA_TEAM_DISBANDED_S, 0, 2, session->GetPlayerName(), GetName(), "");
if (Player* player = session->GetPlayer())
TC_LOG_DEBUG(LOG_FILTER_ARENAS, "Player: %s [GUID: %u] disbanded arena team type: %u [Id: %u].", player->GetName().c_str(), player->GetGUIDLow(), GetType(), GetId());
TC_LOG_DEBUG(LOG_FILTER_ARENAS, "Player: %s [GUID: %u] disbanded arena team type: %u [Id: %u, Name: %s].", player->GetName().c_str(), player->GetGUIDLow(), GetType(), GetId(), GetName().c_str());
}
// Update database
@@ -886,9 +886,9 @@ void Battleground::EndBattleground(uint32 winner)
}
}
uint32 winner_kills = player->GetRandomWinner() ? BG_REWARD_WINNER_HONOR_LAST : BG_REWARD_WINNER_HONOR_FIRST;
uint32 loser_kills = player->GetRandomWinner() ? BG_REWARD_LOSER_HONOR_LAST : BG_REWARD_LOSER_HONOR_FIRST;
uint32 winner_arena = player->GetRandomWinner() ? BG_REWARD_WINNER_ARENA_LAST : BG_REWARD_WINNER_ARENA_FIRST;
uint32 winner_kills = player->GetRandomWinner() ? sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_HONOR_LAST) : sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_HONOR_FIRST);
uint32 loser_kills = player->GetRandomWinner() ? sWorld->getIntConfig(CONFIG_BG_REWARD_LOSER_HONOR_LAST) : sWorld->getIntConfig(CONFIG_BG_REWARD_LOSER_HONOR_FIRST);
uint32 winner_arena = player->GetRandomWinner() ? sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_ARENA_LAST) : sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_ARENA_FIRST);
// Reward winner team
if (team == winner)
@@ -143,16 +143,6 @@ enum BattlegroundBuffObjects
BG_OBJECTID_BERSERKERBUFF_ENTRY = 179905
};
enum BattlegroundRandomRewards
{
BG_REWARD_WINNER_HONOR_FIRST = 30,
BG_REWARD_WINNER_ARENA_FIRST = 25,
BG_REWARD_WINNER_HONOR_LAST = 15,
BG_REWARD_WINNER_ARENA_LAST = 0,
BG_REWARD_LOSER_HONOR_FIRST = 5,
BG_REWARD_LOSER_HONOR_LAST = 5
};
const uint32 Buff_Entries[3] = { BG_OBJECTID_SPEEDBUFF_ENTRY, BG_OBJECTID_REGENBUFF_ENTRY, BG_OBJECTID_BERSERKERBUFF_ENTRY };
enum BattlegroundStatus
@@ -262,8 +262,8 @@ void BattlegroundMgr::BuildPvpLogDataPacket(WorldPacket* data, Battleground* bg)
Battleground::BattlegroundScoreMap::const_iterator itr2 = bg->GetPlayerScoresBegin();
for (Battleground::BattlegroundScoreMap::const_iterator itr = itr2; itr != bg->GetPlayerScoresEnd();)
{
BattlegroundScore* score = itr2->second;
itr2 = itr++;
BattlegroundScore* score = itr2->second;
if (!bg->IsPlayerInBattleground(itr2->first))
{
TC_LOG_ERROR(LOG_FILTER_BATTLEGROUND, "Player " UI64FMTD " has scoreboard entry for battleground %u but is not in battleground!", itr->first, bg->GetTypeID(true));
@@ -828,9 +828,9 @@ void BattlegroundMgr::BuildBattlegroundListPacket(WorldPacket* data, uint64 guid
if (!player)
return;
uint32 winner_kills = player->GetRandomWinner() ? BG_REWARD_WINNER_HONOR_LAST : BG_REWARD_WINNER_HONOR_FIRST;
uint32 winner_arena = player->GetRandomWinner() ? BG_REWARD_WINNER_ARENA_LAST : BG_REWARD_WINNER_ARENA_FIRST;
uint32 loser_kills = player->GetRandomWinner() ? BG_REWARD_LOSER_HONOR_LAST : BG_REWARD_LOSER_HONOR_FIRST;
uint32 winner_kills = player->GetRandomWinner() ? sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_HONOR_LAST) : sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_HONOR_FIRST);
uint32 winner_arena = player->GetRandomWinner() ? sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_ARENA_LAST) : sWorld->getIntConfig(CONFIG_BG_REWARD_WINNER_ARENA_FIRST);
uint32 loser_kills = player->GetRandomWinner() ? sWorld->getIntConfig(CONFIG_BG_REWARD_LOSER_HONOR_LAST) : sWorld->getIntConfig(CONFIG_BG_REWARD_LOSER_HONOR_FIRST);
winner_kills = Trinity::Honor::hk_honor_at_level(player->getLevel(), float(winner_kills));
loser_kills = Trinity::Honor::hk_honor_at_level(player->getLevel(), float(loser_kills));
@@ -544,7 +544,11 @@ void BattlegroundIC::EventPlayerClickedOnFlag(Player* player, GameObject* target
float cords[4] = {banner->GetPositionX(), banner->GetPositionY(), banner->GetPositionZ(), banner->GetOrientation() };
DelObject(nodePoint[i].gameobject_type);
AddObject(nodePoint[i].gameobject_type, nodePoint[i].gameobject_entry, cords[0], cords[1], cords[2], cords[3], 0, 0, 0, 0, RESPAWN_ONE_DAY);
if (!AddObject(nodePoint[i].gameobject_type, nodePoint[i].gameobject_entry, cords[0], cords[1], cords[2], cords[3], 0, 0, 0, 0, RESPAWN_ONE_DAY))
{
TC_LOG_ERROR(LOG_FILTER_BATTLEGROUND, "Isle of Conquest: There was an error spawning a banner (type: %u, entry: %u). Isle of Conquest BG cancelled.", nodePoint[i].gameobject_type, nodePoint[i].gameobject_entry);
Battleground::EndBattleground(WINNER_NONE);
}
GetBGObject(nodePoint[i].gameobject_type)->SetUInt32Value(GAMEOBJECT_FACTION, nodePoint[i].faction == TEAM_ALLIANCE ? BG_IC_Factions[1] : BG_IC_Factions[0]);
@@ -641,10 +645,13 @@ void BattlegroundIC::HandleCapturedNodes(ICNodePoint* nodePoint, bool recapture)
for (uint8 u = 0; u < MAX_HANGAR_TELEPORTERS_SPAWNS; ++u)
{
uint8 type = BG_IC_GO_HANGAR_TELEPORTER_1+u;
AddObject(type, (nodePoint->faction == TEAM_ALLIANCE ? GO_ALLIANCE_GUNSHIP_PORTAL : GO_HORDE_GUNSHIP_PORTAL),
if (!AddObject(type, (nodePoint->faction == TEAM_ALLIANCE ? GO_ALLIANCE_GUNSHIP_PORTAL : GO_HORDE_GUNSHIP_PORTAL),
BG_IC_HangarTeleporters[u].GetPositionX(), BG_IC_HangarTeleporters[u].GetPositionY(),
BG_IC_HangarTeleporters[u].GetPositionZ(), BG_IC_HangarTeleporters[u].GetOrientation(),
0, 0, 0, 0, RESPAWN_ONE_DAY);
0, 0, 0, 0, RESPAWN_ONE_DAY))
{
TC_LOG_ERROR(LOG_FILTER_BATTLEGROUND, "Isle of Conquest: There was an error spawning a gunship portal. Type: %u", BG_IC_GO_HANGAR_TELEPORTER_1+u);
}
}
//TC_LOG_ERROR(LOG_FILTER_BATTLEGROUND, "BG_IC_GO_HANGAR_BANNER CAPTURED Faction: %u", nodePoint->faction);
@@ -818,7 +818,7 @@ const Position allianceGunshipPassengers[5] =
struct ICNodePoint
{
uint32 gameobject_type; // with this we will get the GameObject of that point
uint32 gameobject_entry; // what gamoebject entry is active here.
uint32 gameobject_entry; // what gameobject entry is active here.
uint8 faction; // who has this node
ICNodePointType nodeType; // here we can specify if it is graveyards, hangar etc...
uint32 banners[4]; // the banners that have this point
+9 -3
View File
@@ -43,7 +43,9 @@ ChannelMgr* ChannelMgr::forTeam(uint32 team)
Channel* ChannelMgr::GetJoinChannel(std::string const& name, uint32 channelId)
{
std::wstring wname;
Utf8toWStr(name, wname);
if (!Utf8toWStr(name, wname))
return NULL;
wstrToLower(wname);
ChannelMap::const_iterator i = channels.find(wname);
@@ -61,7 +63,9 @@ Channel* ChannelMgr::GetJoinChannel(std::string const& name, uint32 channelId)
Channel* ChannelMgr::GetChannel(std::string const& name, Player* player, bool pkt)
{
std::wstring wname;
Utf8toWStr(name, wname);
if (!Utf8toWStr(name, wname))
return NULL;
wstrToLower(wname);
ChannelMap::const_iterator i = channels.find(wname);
@@ -84,7 +88,9 @@ Channel* ChannelMgr::GetChannel(std::string const& name, Player* player, bool pk
void ChannelMgr::LeftChannel(std::string const& name)
{
std::wstring wname;
Utf8toWStr(name, wname);
if (!Utf8toWStr(name, wname))
return;
wstrToLower(wname);
ChannelMap::const_iterator i = channels.find(wname);
+6 -1
View File
@@ -1500,6 +1500,11 @@ bool ConditionMgr::isSourceTypeValid(Condition* cond)
}
break;
}
case CONDITION_SOURCE_TYPE_PHASE_DEFINITION:
{
TC_LOG_ERROR(LOG_FILTER_SQL, "CONDITION_SOURCE_TYPE_PHASE_DEFINITION:: is only for 4.3.4 branch, skipped");
return false;
}
case CONDITION_SOURCE_TYPE_GOSSIP_MENU:
case CONDITION_SOURCE_TYPE_GOSSIP_MENU_OPTION:
case CONDITION_SOURCE_TYPE_SMART_EVENT:
@@ -1763,7 +1768,7 @@ bool ConditionMgr::isConditionTypeValid(Condition* cond)
{
if (cond->ConditionValue2 >= COMP_TYPE_MAX)
{
TC_LOG_ERROR(LOG_FILTER_SQL, "Level condition has invalid option (%u), skipped", cond->ConditionValue2);
TC_LOG_ERROR(LOG_FILTER_SQL, "Level condition has invalid ComparisionType (%u), skipped", cond->ConditionValue2);
return false;
}
if (cond->ConditionValue3)
+2 -32
View File
@@ -129,17 +129,8 @@ enum ConditionSourceType
CONDITION_SOURCE_TYPE_SMART_EVENT = 22,
CONDITION_SOURCE_TYPE_NPC_VENDOR = 23,
CONDITION_SOURCE_TYPE_SPELL_PROC = 24,
CONDITION_SOURCE_TYPE_MAX = 25 // MAX
};
enum ComparisionType
{
COMP_TYPE_EQ = 0,
COMP_TYPE_HIGH,
COMP_TYPE_LOW,
COMP_TYPE_HIGH_EQ,
COMP_TYPE_LOW_EQ,
COMP_TYPE_MAX
CONDITION_SOURCE_TYPE_PHASE_DEFINITION = 25, // only 4.3.4
CONDITION_SOURCE_TYPE_MAX = 26 // MAX
};
enum RelationType
@@ -273,27 +264,6 @@ class ConditionMgr
SmartEventConditionContainer SmartEventConditionStore;
};
template <class T> bool CompareValues(ComparisionType type, T val1, T val2)
{
switch (type)
{
case COMP_TYPE_EQ:
return val1 == val2;
case COMP_TYPE_HIGH:
return val1 > val2;
case COMP_TYPE_LOW:
return val1 < val2;
case COMP_TYPE_HIGH_EQ:
return val1 >= val2;
case COMP_TYPE_LOW_EQ:
return val1 <= val2;
default:
// incorrect parameter
ASSERT(false);
return false;
}
}
#define sConditionMgr ACE_Singleton<ConditionMgr, ACE_Null_Mutex>::instance()
#endif
+2 -2
View File
@@ -1966,9 +1966,9 @@ struct VehicleSeatEntry
bool CanEnterOrExit() const { return m_flags & VEHICLE_SEAT_FLAG_CAN_ENTER_OR_EXIT; }
bool CanSwitchFromSeat() const { return m_flags & VEHICLE_SEAT_FLAG_CAN_SWITCH; }
bool IsUsableByOverride() const { return (m_flags & VEHICLE_SEAT_FLAG_UNCONTROLLED)
bool IsUsableByOverride() const { return (m_flags & (VEHICLE_SEAT_FLAG_UNCONTROLLED | VEHICLE_SEAT_FLAG_UNK18)
|| (m_flagsB & (VEHICLE_SEAT_FLAG_B_USABLE_FORCED | VEHICLE_SEAT_FLAG_B_USABLE_FORCED_2 |
VEHICLE_SEAT_FLAG_B_USABLE_FORCED_3 | VEHICLE_SEAT_FLAG_B_USABLE_FORCED_4)); }
VEHICLE_SEAT_FLAG_B_USABLE_FORCED_3 | VEHICLE_SEAT_FLAG_B_USABLE_FORCED_4))); }
bool IsEjectable() const { return m_flagsB & VEHICLE_SEAT_FLAG_B_EJECTABLE; }
};
+7 -4
View File
@@ -539,8 +539,11 @@ inline void KillRewarder::_RewardKillCredit(Player* player)
{
// 4.4. Give kill credit (player must not be in group, or he must be alive or without corpse).
if (!_group || player->IsAlive() || !player->GetCorpse())
if (_victim->GetTypeId() == TYPEID_UNIT)
player->KilledMonster(_victim->ToCreature()->GetCreatureTemplate(), _victim->GetGUID());
if (Creature* target = _victim->ToCreature())
{
player->KilledMonster(target->GetCreatureTemplate(), target->GetGUID());
player->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_KILL_CREATURE_TYPE, target->GetCreatureType(), 1, target);
}
}
void KillRewarder::_RewardPlayer(Player* player, bool isDungeon)
@@ -4028,7 +4031,7 @@ void Player::removeSpell(uint32 spell_id, bool disabled, bool learn_low_rank)
itr->second->state = PLAYERSPELL_REMOVED;
}
RemoveAurasDueToSpell(spell_id);
RemoveOwnedAura(spell_id, GetGUID());
// remove pet auras
for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i)
@@ -4713,7 +4716,7 @@ void Player::DeleteFromDB(uint64 playerguid, uint32 accountId, bool updateRealmC
if (uint32 guildId = GetGuildIdFromDB(playerguid))
if (Guild* guild = sGuildMgr->GetGuildById(guildId))
guild->DeleteMember(guid);
guild->DeleteMember(guid, false, false, true);
// remove from arena teams
LeaveAllArenaTeams(playerguid);
+3 -2
View File
@@ -5236,9 +5236,10 @@ void ObjectMgr::ReturnOrDeleteOldMails(bool serverUp)
uint32 oldMSTime = getMSTime();
time_t curTime = time(NULL);
tm* lt = localtime(&curTime);
tm lt;
ACE_OS::localtime_r(&curTime, &lt);
uint64 basetime(curTime);
TC_LOG_INFO(LOG_FILTER_GENERAL, "Returning mails current time: hour: %d, minute: %d, second: %d ", lt->tm_hour, lt->tm_min, lt->tm_sec);
TC_LOG_INFO(LOG_FILTER_GENERAL, "Returning mails current time: hour: %d, minute: %d, second: %d ", lt.tm_hour, lt.tm_min, lt.tm_sec);
// Delete all old mails without item and without body immediately, if starting server
if (!serverUp)
+15 -3
View File
@@ -1943,10 +1943,22 @@ void Group::ResetInstances(uint8 method, bool isRaid, Player* SendMsgTo)
if (SendMsgTo)
{
if (isEmpty)
SendMsgTo->SendResetInstanceSuccess(instanceSave->GetMapId());
else
if (!isEmpty)
SendMsgTo->SendResetInstanceFailed(0, instanceSave->GetMapId());
else if (sWorld->getBoolConfig(CONFIG_INSTANCES_RESET_ANNOUNCE))
{
if (Group* group = SendMsgTo->GetGroup())
{
for (GroupReference* itr = group->GetFirstMember(); itr != NULL; itr = itr->next())
if (Player* player = itr->GetSource())
player->SendResetInstanceSuccess(instanceSave->GetMapId());
}
else
SendMsgTo->SendResetInstanceSuccess(instanceSave->GetMapId());
}
else
SendMsgTo->SendResetInstanceSuccess(instanceSave->GetMapId());
}
if (isEmpty || method == INSTANCE_RESET_GROUP_DISBAND || method == INSTANCE_RESET_CHANGE_DIFFICULTY)
+15 -1
View File
@@ -1578,6 +1578,8 @@ void Guild::HandleAcceptMember(WorldSession* session)
void Guild::HandleLeaveMember(WorldSession* session)
{
Player* player = session->GetPlayer();
bool disband = false;
// If leader is leaving
if (_IsLeader(player))
{
@@ -1585,8 +1587,11 @@ void Guild::HandleLeaveMember(WorldSession* session)
// Leader cannot leave if he is not the last member
SendCommandResult(session, GUILD_COMMAND_QUIT, ERR_GUILD_LEADER_LEAVE);
else
{
// Guild is disbanded if leader leaves.
Disband();
disband = true;
}
}
else
{
@@ -1599,6 +1604,9 @@ void Guild::HandleLeaveMember(WorldSession* session)
}
sCalendarMgr->RemovePlayerGuildEventsAndSignups(player->GetGUID(), GetId());
if (disband)
delete this;
}
void Guild::HandleRemoveMember(WorldSession* session, std::string const& name)
@@ -1754,6 +1762,9 @@ void Guild::HandleMemberDepositMoney(WorldSession* session, uint32 amount)
bool Guild::HandleMemberWithdrawMoney(WorldSession* session, uint32 amount, bool repair)
{
//clamp amount to MAX_MONEY_AMOUNT, Players can't hold more than that anyway
amount = std::min(amount, uint32(MAX_MONEY_AMOUNT));
if (m_bankMoney < amount) // Not enough money in bank
return false;
@@ -1812,6 +1823,7 @@ void Guild::HandleDisband(WorldSession* session)
{
Disband();
TC_LOG_DEBUG(LOG_FILTER_GUILD, "Guild Successfully Disbanded");
delete this;
}
}
@@ -2272,7 +2284,7 @@ bool Guild::AddMember(uint64 guid, uint8 rankId)
return true;
}
void Guild::DeleteMember(uint64 guid, bool isDisbanding, bool isKicked)
void Guild::DeleteMember(uint64 guid, bool isDisbanding, bool isKicked, bool canDeleteGuild)
{
uint32 lowguid = GUID_LOPART(guid);
Player* player = ObjectAccessor::FindPlayer(guid);
@@ -2294,6 +2306,8 @@ void Guild::DeleteMember(uint64 guid, bool isDisbanding, bool isKicked)
if (!newLeader)
{
Disband();
if (canDeleteGuild)
delete this;
return;
}
+1 -1
View File
@@ -727,7 +727,7 @@ public:
// Members
// Adds member to guild. If rankId == GUILD_RANK_NONE, lowest rank is assigned.
bool AddMember(uint64 guid, uint8 rankId = GUILD_RANK_NONE);
void DeleteMember(uint64 guid, bool isDisbanding = false, bool isKicked = false);
void DeleteMember(uint64 guid, bool isDisbanding = false, bool isKicked = false, bool canDeleteGuild = false);
bool ChangeMemberRank(uint64 guid, uint8 newRank);
// Bank
+3 -10
View File
@@ -378,20 +378,13 @@ void GuildMgr::LoadGuilds()
TC_LOG_INFO(LOG_FILTER_GUILD, "Validating data of loaded guilds...");
{
uint32 oldMSTime = getMSTime();
std::set<Guild*> rm; // temporary storage to avoid modifying GuildStore with RemoveGuild() while iterating
for (GuildContainer::iterator itr = GuildStore.begin(); itr != GuildStore.end(); ++itr)
for (GuildContainer::iterator itr = GuildStore.begin(); itr != GuildStore.end();)
{
Guild* guild = itr->second;
++itr;
if (guild && !guild->Validate())
rm.insert(guild);
}
for (std::set<Guild*>::iterator itr = rm.begin(); itr != rm.end(); ++itr)
{
Guild* guild = *itr;
RemoveGuild(guild->GetId());
delete guild;
delete guild;
}
TC_LOG_INFO(LOG_FILTER_SERVER_LOADING, ">> Validated data of loaded guilds in %u ms", GetMSTimeDiffToNow(oldMSTime));
@@ -1918,7 +1918,7 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData)
PreparedQueryResult result = CharacterDatabase.Query(stmt);
if (result)
if (Guild* guild = sGuildMgr->GetGuildById((result->Fetch()[0]).GetUInt32()))
guild->DeleteMember(MAKE_NEW_GUID(lowGuid, 0, HIGHGUID_PLAYER));
guild->DeleteMember(MAKE_NEW_GUID(lowGuid, 0, HIGHGUID_PLAYER), false, false, true);
}
if (!HasPermission(RBAC_PERM_TWO_SIDE_ADD_FRIEND))
+3 -1
View File
@@ -630,7 +630,9 @@ void WorldSession::HandlePetRename(WorldPacket& recvData)
}
std::wstring wname;
Utf8toWStr(name, wname);
if (!Utf8toWStr(name, wname))
return;
if (!ObjectMgr::CheckDeclinedNames(wname, declinedname))
{
SendPetNameInvalid(PET_NAME_DECLENSION_DOESNT_MATCH_BASE_NAME, name, &declinedname);
+3 -1
View File
@@ -548,7 +548,9 @@ void PathGenerator::UpdateFilter()
NavTerrain PathGenerator::GetNavTerrain(float x, float y, float z)
{
LiquidData data;
_sourceUnit->GetBaseMap()->getLiquidStatus(x, y, z, MAP_ALL_LIQUIDS, &data);
ZLiquidStatus liquidStatus = _sourceUnit->GetBaseMap()->getLiquidStatus(x, y, z, MAP_ALL_LIQUIDS, &data);
if (liquidStatus == LIQUID_MAP_NO_WATER)
return NAV_GROUND;
switch (data.type_flags)
{
@@ -59,6 +59,7 @@ void AddSC_event_commandscript();
void AddSC_gm_commandscript();
void AddSC_go_commandscript();
void AddSC_gobject_commandscript();
void AddSC_group_commandscript();
void AddSC_guild_commandscript();
void AddSC_honor_commandscript();
void AddSC_instance_commandscript();
@@ -71,10 +72,12 @@ void AddSC_misc_commandscript();
void AddSC_mmaps_commandscript();
void AddSC_modify_commandscript();
void AddSC_npc_commandscript();
void AddSC_pet_commandscript();
void AddSC_quest_commandscript();
void AddSC_rbac_commandscript();
void AddSC_reload_commandscript();
void AddSC_reset_commandscript();
void AddSC_send_commandscript();
void AddSC_server_commandscript();
void AddSC_tele_commandscript();
void AddSC_ticket_commandscript();
@@ -740,6 +743,7 @@ void AddCommandScripts()
AddSC_gm_commandscript();
AddSC_go_commandscript();
AddSC_gobject_commandscript();
AddSC_group_commandscript();
AddSC_guild_commandscript();
AddSC_honor_commandscript();
AddSC_instance_commandscript();
@@ -753,9 +757,11 @@ void AddCommandScripts()
AddSC_modify_commandscript();
AddSC_npc_commandscript();
AddSC_quest_commandscript();
AddSC_pet_commandscript();
AddSC_rbac_commandscript();
AddSC_reload_commandscript();
AddSC_reset_commandscript();
AddSC_send_commandscript();
AddSC_server_commandscript();
AddSC_tele_commandscript();
AddSC_ticket_commandscript();
@@ -1254,9 +1254,9 @@ void AuraEffect::HandleShapeshiftBoosts(Unit* target, bool apply) const
else
{
if (spellId)
target->RemoveAurasDueToSpell(spellId);
target->RemoveOwnedAura(spellId, target->GetGUID());
if (spellId2)
target->RemoveAurasDueToSpell(spellId2);
target->RemoveOwnedAura(spellId2, target->GetGUID());
// Improved Barkskin - apply/remove armor bonus due to shapeshift
if (Player* player=target->ToPlayer())
@@ -5113,7 +5113,7 @@ void AuraEffect::HandleAuraLinked(AuraApplication const* aurApp, uint8 mode, boo
{
if (apply)
{
Unit* caster = triggeredSpellInfo->NeedsToBeTriggeredByCaster() ? GetCaster() : target;
Unit* caster = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? GetCaster() : target;
if (!caster)
return;
@@ -5125,13 +5125,13 @@ void AuraEffect::HandleAuraLinked(AuraApplication const* aurApp, uint8 mode, boo
}
else
{
uint64 casterGUID = triggeredSpellInfo->NeedsToBeTriggeredByCaster() ? GetCasterGUID() : target->GetGUID();
uint64 casterGUID = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? GetCasterGUID() : target->GetGUID();
target->RemoveAura(triggeredSpellId, casterGUID, 0, aurApp->GetRemoveMode());
}
}
else if (mode & AURA_EFFECT_HANDLE_REAPPLY && apply)
{
uint64 casterGUID = triggeredSpellInfo->NeedsToBeTriggeredByCaster() ? GetCasterGUID() : target->GetGUID();
uint64 casterGUID = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? GetCasterGUID() : target->GetGUID();
// change the stack amount to be equal to stack amount of our aura
if (Aura* triggeredAura = target->GetAura(triggeredSpellId, casterGUID))
triggeredAura->ModStackAmount(GetBase()->GetStackAmount() - triggeredAura->GetStackAmount());
@@ -5733,7 +5733,7 @@ void AuraEffect::HandlePeriodicTriggerSpellAuraTick(Unit* target, Unit* caster)
if (triggeredSpellInfo)
{
if (Unit* triggerCaster = triggeredSpellInfo->NeedsToBeTriggeredByCaster() ? caster : target)
if (Unit* triggerCaster = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? caster : target)
{
triggerCaster->CastSpell(target, triggeredSpellInfo, true, NULL, this);
TC_LOG_DEBUG(LOG_FILTER_SPELLS_AURAS, "AuraEffect::HandlePeriodicTriggerSpellAuraTick: Spell %u Trigger %u", GetId(), triggeredSpellInfo->Id);
@@ -5753,7 +5753,7 @@ void AuraEffect::HandlePeriodicTriggerSpellWithValueAuraTick(Unit* target, Unit*
uint32 triggerSpellId = GetSpellInfo()->Effects[m_effIndex].TriggerSpell;
if (SpellInfo const* triggeredSpellInfo = sSpellMgr->GetSpellInfo(triggerSpellId))
{
if (Unit* triggerCaster = triggeredSpellInfo->NeedsToBeTriggeredByCaster() ? caster : target)
if (Unit* triggerCaster = triggeredSpellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) ? caster : target)
{
int32 basepoints = GetAmount();
triggerCaster->CastCustomSpell(target, triggerSpellId, &basepoints, &basepoints, &basepoints, true, 0, this);
+5 -57
View File
@@ -917,13 +917,13 @@ void Spell::EffectTriggerSpell(SpellEffIndex effIndex)
SpellCastTargets targets;
if (effectHandleMode == SPELL_EFFECT_HANDLE_LAUNCH_TARGET)
{
if (!spellInfo->NeedsToBeTriggeredByCaster())
if (!spellInfo->NeedsToBeTriggeredByCaster(m_spellInfo))
return;
targets.SetUnitTarget(unitTarget);
}
else //if (effectHandleMode == SPELL_EFFECT_HANDLE_LAUNCH)
{
if (spellInfo->NeedsToBeTriggeredByCaster() && (m_spellInfo->Effects[effIndex].GetProvidedTargetMask() & TARGET_FLAG_UNIT_MASK))
if (spellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) && (m_spellInfo->Effects[effIndex].GetProvidedTargetMask() & TARGET_FLAG_UNIT_MASK))
return;
if (spellInfo->GetExplicitTargetMask() & TARGET_FLAG_DEST_LOCATION)
@@ -969,13 +969,13 @@ void Spell::EffectTriggerMissileSpell(SpellEffIndex effIndex)
SpellCastTargets targets;
if (effectHandleMode == SPELL_EFFECT_HANDLE_HIT_TARGET)
{
if (!spellInfo->NeedsToBeTriggeredByCaster())
if (!spellInfo->NeedsToBeTriggeredByCaster(m_spellInfo))
return;
targets.SetUnitTarget(unitTarget);
}
else //if (effectHandleMode == SPELL_EFFECT_HANDLE_HIT)
{
if (spellInfo->NeedsToBeTriggeredByCaster() && (m_spellInfo->Effects[effIndex].GetProvidedTargetMask() & TARGET_FLAG_UNIT_MASK))
if (spellInfo->NeedsToBeTriggeredByCaster(m_spellInfo) && (m_spellInfo->Effects[effIndex].GetProvidedTargetMask() & TARGET_FLAG_UNIT_MASK))
return;
if (spellInfo->GetExplicitTargetMask() & TARGET_FLAG_DEST_LOCATION)
@@ -1133,29 +1133,6 @@ void Spell::EffectTeleportUnits(SpellEffIndex /*effIndex*/)
if (!unitTarget || unitTarget->IsInFlight())
return;
// Pre effects
switch (m_spellInfo->Id)
{
case 66550: // teleports outside (Isle of Conquest)
if (Player* target = unitTarget->ToPlayer())
{
if (target->GetTeamId() == TEAM_ALLIANCE)
m_targets.SetDst(442.24f, -835.25f, 44.30f, 0.06f, 628);
else
m_targets.SetDst(1120.43f, -762.11f, 47.92f, 2.94f, 628);
}
break;
case 66551: // teleports inside (Isle of Conquest)
if (Player* target = unitTarget->ToPlayer())
{
if (target->GetTeamId() == TEAM_ALLIANCE)
m_targets.SetDst(389.57f, -832.38f, 48.65f, 3.00f, 628);
else
m_targets.SetDst(1174.85f, -763.24f, 48.72f, 6.26f, 628);
}
break;
}
// If not exist data for dest location - return
if (!m_targets.HasDst())
{
@@ -3902,15 +3879,6 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex)
npc->LoadEquipment();
return;
}
// Emblazon Runeblade
case 51770:
{
if (!m_originalCaster)
return;
m_originalCaster->CastSpell(m_originalCaster, damage, false);
break;
}
// Deathbolt from Thalgran Blightbringer
// reflected by Freya's Ward
// Retribution by Sevenfold Retribution
@@ -3985,26 +3953,6 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex)
return;
}
case 58941: // Rock Shards
if (unitTarget && m_originalCaster)
{
for (uint32 i = 0; i < 3; ++i)
{
m_originalCaster->CastSpell(unitTarget, 58689, true);
m_originalCaster->CastSpell(unitTarget, 58692, true);
}
if (((InstanceMap*)m_originalCaster->GetMap())->GetDifficulty() == REGULAR_DIFFICULTY)
{
m_originalCaster->CastSpell(unitTarget, 58695, true);
m_originalCaster->CastSpell(unitTarget, 58696, true);
}
else
{
m_originalCaster->CastSpell(unitTarget, 60883, true);
m_originalCaster->CastSpell(unitTarget, 60884, true);
}
}
return;
case 58983: // Big Blizzard Bear
{
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_PLAYER)
@@ -5656,7 +5604,7 @@ void Spell::EffectActivateRune(SpellEffIndex effIndex)
// Blood Tap
if (m_spellInfo->Id == 45529 && count > 0)
{
for (uint32 l = 0; l < MAX_RUNES && count > 0; ++l)
for (uint32 l = 0; l + 1 < MAX_RUNES && count > 0; ++l)
{
// Check if both runes are on cd as that is the only time when this needs to come into effect
if ((player->GetRuneCooldown(l) && player->GetCurrentRune(l) == RuneType(m_spellInfo->Effects[effIndex].MiscValueB)) && (player->GetRuneCooldown(l+1) && player->GetCurrentRune(l+1) == RuneType(m_spellInfo->Effects[effIndex].MiscValueB)))

Some files were not shown because too many files have changed in this diff Show More