Merge branch 'master' of github.com:TrinityCore/TrinityCore into 4.3.4

Conflicts:
	src/server/game/World/World.h
This commit is contained in:
Vincent-Michael
2014-06-25 19:51:27 +02:00
27 changed files with 417 additions and 50 deletions
+14 -14
View File
@@ -1,8 +1,8 @@
-- MySQL dump 10.15 Distrib 10.0.10-MariaDB, for Win64 (x86)
-- MySQL dump 10.15 Distrib 10.0.12-MariaDB, for Win64 (x86)
--
-- Host: localhost Database: auth_4x
-- ------------------------------------------------------
-- Server version 10.0.10-MariaDB
-- Server version 10.0.12-MariaDB
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
@@ -391,17 +391,17 @@ DROP TABLE IF EXISTS `logs_ip_actions`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `logs_ip_actions` (
`id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT 'Unique Identifier',
`account_id` INT(10) UNSIGNED NOT NULL COMMENT 'Account ID',
`character_guid` INT(10) UNSIGNED NOT NULL COMMENT 'Character Guid',
`type` TINYINT(3) UNSIGNED NOT NULL,
`ip` VARCHAR(15) NOT NULL DEFAULT '127.0.0.1',
`systemnote` TEXT NULL COMMENT 'Notes inserted by system',
`unixtime` INT(10) UNSIGNED NOT NULL COMMENT 'Unixtime',
`time` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Timestamp',
`comment` TEXT NULL COMMENT 'Allows users to add a comment',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8
`id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Unique Identifier',
`account_id` int(10) unsigned NOT NULL COMMENT 'Account ID',
`character_guid` int(10) unsigned NOT NULL COMMENT 'Character Guid',
`type` tinyint(3) unsigned NOT NULL,
`ip` varchar(15) NOT NULL DEFAULT '127.0.0.1',
`systemnote` text COMMENT 'Notes inserted by system',
`unixtime` int(10) unsigned NOT NULL COMMENT 'Unixtime',
`time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Timestamp',
`comment` text COMMENT 'Allows users to add a comment',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Used to log ips of individual actions';
/*!40101 SET character_set_client = @saved_cs_client */;
--
@@ -616,4 +616,4 @@ UNLOCK TABLES;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2014-04-28 13:43:54
-- Dump completed on 2014-06-25 18:37:31
@@ -1,5 +1,4 @@
ALTER TABLE `account`
ADD COLUMN `last_attempt_ip` VARCHAR(15) NOT NULL DEFAULT '127.0.0.1' AFTER `last_ip`;
ALTER TABLE `account` ADD COLUMN `last_attempt_ip` VARCHAR(15) NOT NULL DEFAULT '127.0.0.1' AFTER `last_ip`;
CREATE TABLE `logs_ip_actions` (
`id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT 'Unique Identifier',
@@ -0,0 +1,68 @@
-- Add support for quest Changing the Wind's Course - ID: 13058 /Horde/
SET @Stormhoof := 30388;
SET @VehicleSpell := 56863;
SET @Ride := 46598;
SET @Wind := 30474;
SET @DropHorn := 56892;
SET @Stun := 62794;
SET @Guid := 40509; -- Set by TDB
-- Add spawn in phase 256 for The Wind of North
DELETE FROM `creature` WHERE `guid`=@Guid;
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
(@Guid,@Wind,571,1,256,0,0,7942.61,-2723.29,1138,6.09394,60,0,0,63000,19970,0,0,0,0);
-- SAI and spell support for StormHoof
UPDATE `creature_template` SET `AIName`='SmartAI',`spell1`=56897,`spell2`=61668,`spell3`=56896 WHERE `entry`=30388;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@Stormhoof;
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
(@Stormhoof,0,0,1,54,0,100,0,0,0,0,0,85,56900,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - On summoned - Cast power of Lorehammer on invoker /used to store invoker/'),
(@Stormhoof,0,1,0,61,0,100,0,0,0,0,0,85,@Ride,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - Linked with previous event - Ivoker cast Ride hardcoded on Stormhoof '),
(@Stormhoof,0,2,0,4,0,100,1,0,0,0,0,20,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - On aggro - Disable auto attacks'),
(@Stormhoof,0,3,0,8,0,100,0,@Ride,0,0,0,2,2141,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - On hit by spell Ride - Change faction to hostile towards Wind'),
(@Stormhoof,0,4,5,38,0,100,0,0,1,0,0,18,8196,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - On data set 0 1 - Set unit flags for No move, Silence and Pacified'),
(@Stormhoof,0,5,0,61,0,100,0,0,0,0,0,1,0,1000,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - Linked with previous event - Say text 1'),
(@Stormhoof,0,6,7,38,0,100,0,0,2,0,0,75,@Stun,0,0,0,0,0,19,@Wind,30,0,0,0,0,0,'Stormhoof - On Data set 0 2 - Set stun on wind'),
(@Stormhoof,0,7,8,61,0,100,0,0,0,0,0,37,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - Linked with previous event - Die'),
(@Stormhoof,0,8,0,61,0,100,0,0,0,0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - Linked with previous event - Set unseen'),
(@Stormhoof,0,9,10,6,0,100,0,0,0,0,0,19,8196,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - On death - Remove unit_flags'),
(@Stormhoof,0,10,0,61,0,100,0,0,0,0,0,2,35,0,0,0,0,0,1,0,0,0,0,0,0,0,'Stormhoof - Linkedw with previous event - Change faction to 35');
-- Add SAI support for North Wind
UPDATE `creature_template` SET `mindmg`=327,`maxdmg`=362,`faction`=16,`AIName`='SmartAI' WHERE `entry`=@Wind;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@Wind;
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
(@Wind,0,0,0,0,0,100,0,1000,3000,8000,11000,11,61662,0,0,0,0,0,2,0,0,0,0,0,0,0,'North Wind - IC - Cast Cyclone'),
(@Wind,0,1,0,0,0,100,0,1000,8000,12000,16000,11,61663,0,0,0,0,0,2,0,0,0,0,0,0,0,'North Wind - IC - Gust of Wind'),
(@Wind,0,2,3,2,0,100,1,10,20,20000,20000,11,@DropHorn,0,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - Between 10 and 20% HP - Drop Horn'),
(@Wind,0,3,4,61,0,100,0,0,0,0,0,18,139270,0,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - Linked with previous event - Set unit flags for No move, Silence and Pacified'),
(@Wind,0,4,0,61,0,100,0,0,0,0,0,1,0,1200,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - Linked with previous event - Say text 0'),
(@Wind,0,5,6,52,0,100,0,0,@Wind,0,0,45,0,1,0,0,0,0,19,@Stormhoof,30,0,0,0,0,0,'North Wind - On text 0 over - Set data 0 1 on Stormhoof'),
(@Wind,0,6,0,61,0,100,0,0,0,0,0,1,1,4000,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - Linked with previous event - Say text 1'),
(@Wind,0,7,0,52,0,100,0,1,@Wind,0,0,45,0,2,0,0,0,0,19,@Stormhoof,30,0,0,0,0,0,'North Wind - On text over 1 - Data set 0 2 on Stormhoof'),
(@Wind,0,8,9,38,0,100,1,0,2,0,0,1,2,1000,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - On data set 0 2 - Say text 2'),
(@Wind,0,9,0,61,0,100,0,0,0,0,0,37,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - Linked with previous event - Die'),
(@Wind,0,10,0,6,0,100,0,0,0,0,0,19,139270,0,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - On death - Remove unit_flags'),
(@Wind,0,11,0,4,0,100,0,0,0,0,0,20,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'North Wind - On Agro - Disable Auto Attack');
-- Texts
DELETE FROM `creature_text` WHERE `entry` IN (@Wind,@Stormhoof);
INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextID`) VALUES
(@Stormhoof, 0, 0, 'The horn! Use the horn on it while it''s weak!', 14, 0, 100, 1, 1000, 0, 'Stormhoof', 31183),
(@Wind, 2, 0, 'That horn is... MINE!', 14, 0, 100, 1, 2000, 0, 'North Wind', 31195),
(@Wind, 1, 0, 'I will never allow you to use the Horn of Elemental Fury against us! Die, weakling!', 14, 0, 100, 1, 3000, 0, 'North Wind', 31181),
(@Wind, 0, 0, 'Fool! You will never defeat me!', 14, 0, 100, 1, 1200, 0, 'North Wind', 31180);
-- Add SAI for Horn of Elemental Fury
SET @GO := 194123;
UPDATE `gameobject_template` SET `AIName`= 'SmartGameObjectAI' WHERE `entry`=@GO;
DELETE FROM `smart_scripts` WHERE `source_type`=1 AND `entryorguid`=@GO;
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
(@GO,1,0,0,70,0,100,0,2,0,0,0,45,0,2,0,0,0,0,19,@Wind,30,0,0,0,0,0,'Horn of Elemental Fury - On state changed - Data set 0 2 on The Winf of North');
-- Add Npc_spell_click data
UPDATE `creature_template` SET `npcflag`=16777216 WHERE `entry`=@Stormhoof;
DELETE FROM `npc_spellclick_spells` WHERE `npc_entry`=@Stormhoof;
INSERT INTO `npc_spellclick_spells` (`npc_entry`,`spell_id`,`cast_flags`,`user_type`) VALUES
(@Stormhoof,@Ride,1,0);
@@ -0,0 +1,12 @@
--
SET @GRICKSBONESAW :=43286;
SET @DERANGEDEXPLORER :=23967;
DELETE FROM `conditions` WHERE `SourceEntry`=@GRICKSBONESAW AND `SourceTypeOrReferenceId`=17;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(17,0,@GRICKSBONESAW ,0,0,36,1,0,0,0,1,0,'', 'Gricks Bonesaw can target only a corpse'),
(17,0,@GRICKSBONESAW ,0,0,31,1,3,@DERANGEDEXPLORER,0,0,0,'', 'Gricks Bonesaw can target only Deranged Explorer');
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry` = @DERANGEDEXPLORER;
DELETE FROM `smart_scripts` WHERE `entryorguid` = @DERANGEDEXPLORER 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
(@DERANGEDEXPLORER,0,0,1,8,0,100,1,@GRICKSBONESAW,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Deranged Explorer - On Spellhit Despawn after 1 second');
@@ -0,0 +1,5 @@
-- Improved Mana Gems
DELETE FROM `spell_proc_event` WHERE `entry` IN (37447, 61062);
INSERT INTO `spell_proc_event` (`entry`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`procFlags`,`procEx`,`ppmRate`,`CustomChance`,`Cooldown`) VALUES
(37447, 0, 3, 0, 0x00000100, 0, 0x04000, 0, 0, 0, 0), -- Serpent-Coil Braid
(61062, 0, 3, 0, 0x00000100, 0, 0x04000, 0, 0, 0, 0); -- 2/5 Frostfire Garb
@@ -0,0 +1,15 @@
-- Disable Midsummer Fire Festival quests that were removed in patch 2.4.0
DELETE FROM `disables` WHERE `sourceType`=1 AND `entry` IN (9367,9368,9319,9386,9322,9323,9388,9389);
INSERT INTO `disables` (`sourceType`,`entry`,`flags`,`params_0`,`params_1`,`comment`) VALUES
(1,9367,0,0,0,'Quest: The Festival of Fire {A}, removed in patch 2.4.0'),
(1,9368,0,0,0,'Quest: The Festival of Fire {H}, removed in patch 2.4.0'),
(1,9319,0,0,0,'Quest: A Light in Dark Places, removed in patch 2.4.0'),
(1,9386,0,0,0,'Quest: A Light in Dark Places {Daily}, removed in patch 2.4.0'),
(1,9322,0,0,0,'Quest: Wild Fires in Kalimdor, removed in patch 2.4.0'),
(1,9323,0,0,0,'Quest: Wild Fires in the Eastern Kingdoms, removed in patch 2.4.0'),
(1,9388,0,0,0,'Quest: Flickering Flames in Kalimdor, removed in patch 2.4.0'),
(1,9389,0,0,0,'Quest: Flickering Flames in the Eastern Kingdoms, removed in patch 2.4.0');
-- Remove above mentioned quests from QuestStarters and QuestEnders
DELETE FROM `creature_queststarter` WHERE `quest` IN (9367,9368,9319,9386,9322,9323,9388,9389);
DELETE FROM `creature_questender` WHERE `quest` IN (9367,9368,9319,9386,9322,9323,9388,9389);
@@ -0,0 +1,99 @@
--
SET @CGuid := 71997;
UPDATE `gameobject_template` SET `AIName`='SmartGameObjectAI', `ScriptName`='' WHERE `entry`=164911;
UPDATE `creature_template` SET `AIName`= 'SmartAI',`unit_flags`=0 WHERE `entry` IN(9537,9541);
DELETE FROM `smart_scripts` WHERE `source_type`=1 AND `entryorguid`=164911;
DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`IN(9537,-@CGuid,-@CGuid-1,-@CGuid-2);
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
(164911, 1, 0 ,0, 70, 0, 100, 0, 2, 0, 0,0,45,1,1,0,0,0,0,13,164911,0,200,0,0,0,0, 'Thunderbrew Lager Keg - On State Changed - Set Data'),
(164911, 1, 1 ,0, 70, 2, 100, 0, 2, 0, 0,0,45,1,1,0,0,0,0,9,9537,0,200,0,0,0,0, 'Thunderbrew Lager Keg - On State Changed - Set Data'),
(164911, 1, 2 ,0, 38, 0, 100, 0, 1, 1, 0,0,23,1,0,0,0,0,0,9,9537,0,200,0,0,0,0, 'Thunderbrew Lager Keg - On Data Set - Increment Phase'),
--
(9537, 0, 0 ,1, 11, 0, 100, 0, 0, 0, 0,0,18,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - On Spawn - Set Unit Flags'),
(9537, 0, 1 ,0, 61, 0, 100, 0, 0, 0, 0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Set Invisible'),
(9537, 0, 3 ,4, 38, 0, 100, 1, 1, 1, 0,0,47,1,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - On Data Set - Set Visible'),
(9537, 0, 4 ,6, 61, 0, 100, 0, 0, 0, 0,0,45,1,1,0,0,0,0,9,9541,0,200,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Set Data'),
(9537, 0, 6 ,7, 61, 0, 100, 0, 0, 0, 0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Say'),
(9537, 0, 7 ,0, 61, 0, 100, 0, 0, 0, 0,0,53,0,9537,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Start WP'),
(9537, 0, 8 ,9, 40, 0, 100, 0, 3, 0, 0,0,101,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - On Reached WP 3 - Set Home Position'),
(9537, 0, 9 ,10, 61, 0, 100, 0, 0, 0, 0,0,19,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Set Unit Flags'),
(9537, 0, 10 ,15, 61, 0, 100, 0, 0, 0, 0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Say'),
(9537, 0, 11 ,0, 2, 0, 100, 0, 0, 30, 30000,45000,11,14872,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - On Less than 30% HP - Cast Drunken Rage'),
(9537, 0, 12 ,0, 9, 0, 100, 0, 0, 5, 10000,15000,11,9573,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Hurley Blackbreath - On Range - Cast Flame Breath'),
(9537, 0, 13 ,0, 0, 0, 100, 0, 5000, 6000, 10000,14000,11,26211,0,0,0,0,0,2,0,0,0,0,0,0,0, 'Hurley Blackbreath - IC - Cast Hamstring'),
(9537, 0, 14 ,0, 0, 0, 100, 0, 5000, 8000, 8000,13000,11,16856,0,0,0,0,0,2,0,0,0,0,0,0,0, 'Hurley Blackbreath - IC - Cast Mortal Strike'),
(9537, 0, 15 ,0, 61, 0, 100, 0, 0, 0, 0,0,89,3,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Set Random Movement'),
(9537, 0, 16 ,17, 4, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9541,0,200,0,0,0,0, 'Hurley Blackbreath - On Agro - Set Set Data'),
(9537, 0, 17 ,0, 61, 0, 100, 0, 0, 0, 0,0,49,0,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Attack'),
(9537, 0, 18 ,0, 38, 0, 100, 0, 1, 2, 0,0,49,0,0,0,0,0,0,21,200,0,0,0,0,0,0, 'Hurley Blackbreath - On Data Set - Attack'),
--
(-@CGuid, 0, 0 ,1, 11, 0, 100, 0, 0, 0, 0,0,18,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Spawn - Set Unit Flags'),
(-@CGuid, 0, 1 ,0, 61, 0, 100, 0, 0, 0, 0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Invisible'),
(-@CGuid, 0, 2 ,4, 38, 0, 100, 0, 1, 1, 0,0,47,1,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Data Set - Set visible'),
(-@CGuid, 0, 4 ,0, 61, 0, 100, 0, 0, 0, 0,0,53,0,9541,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Start WP'),
(-@CGuid, 0, 5 ,6, 40, 0, 100, 0, 3, 0, 0,0,101,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Reached WP 5 - Set Home Position'),
(-@CGuid, 0, 6 ,7, 61, 0, 100, 0, 0, 0, 0,0,19,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Unit Flags'),
(-@CGuid, 0, 7 ,0, 61, 0, 100, 0, 0, 0, 0,0,89,3,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Random Movement'),
(-@CGuid, 0, 8, 0, 0, 0, 100, 0, 1000, 3000, 4000, 7000, 11, 15581, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blackbreath Crony - IC - Cast Sinister Strike'),
(-@CGuid, 0, 9, 0, 0, 0, 100, 0, 2000, 2000, 11000, 12000, 11, 15583, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blackbreath Crony - IC - Cast Rupture'),
(-@CGuid, 0, 10 ,11, 4, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9541,0,200,0,0,0,0, 'Hurley Blackbreath - On Agro - Set Set Data'),
(-@CGuid, 0, 11 ,12,61, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9537,0,200,0,0,0,0, 'Hurley Blackbreath - On Agro - Set Set Data'),
(-@CGuid, 0, 12 ,0, 61, 0, 100, 0, 0, 0, 0,0,49,0,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Hurley Blackbreath - Linked with Previous Event - Attack'),
(-@CGuid, 0, 13 ,0, 38, 0, 100, 0, 1, 2, 0,0,49,0,0,0,0,0,0,21,200,0,0,0,0,0,0, 'Hurley Blackbreath - On Data Set - Attack'),
--
(-@CGuid-1, 0, 0 ,1, 11, 0, 100, 0, 0, 0, 0,0,18,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Spawn - Set Unit Flags'),
(-@CGuid-1, 0, 1 ,0, 61, 0, 100, 0, 0, 0, 0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Invisible'),
(-@CGuid-1, 0, 2 ,4, 38, 0, 100, 0, 1, 1, 0,0,47,1,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Data Set - Set visible'),
(-@CGuid-1, 0, 4 ,0, 61, 0, 100, 0, 0, 0, 0,0,53,0,9541000,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Start WP'),
(-@CGuid-1, 0, 5 ,6, 40, 0, 100, 0, 3, 0, 0,0,101,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Reached WP 5 - Set Home Position'),
(-@CGuid-1, 0, 6 ,7, 61, 0, 100, 0, 0, 0, 0,0,19,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Unit Flags'),
(-@CGuid-1, 0, 7 ,0, 61, 0, 100, 0, 0, 0, 0,0,89,3,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Random Movement'),
(-@CGuid-1, 0, 8, 0, 0, 0, 100, 0, 1000, 3000, 4000, 7000, 11, 15581, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blackbreath Crony - IC - Cast Sinister Strike'),
(-@CGuid-1, 0, 9, 0, 0, 0, 100, 0, 2000, 2000, 11000, 12000, 11, 15583, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blackbreath Crony - IC - Cast Rupture'),
(-@CGuid-1, 0, 10 ,11, 4, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9541,0,200,0,0,0,0, 'Blackbreath Crony - On Agro - Set Set Data'),
(-@CGuid-1, 0, 11 ,12,61, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9537,0,200,0,0,0,0, 'Blackbreath Crony - On Agro - Set Set Data'),
(-@CGuid-1, 0, 12 ,0, 61, 0, 100, 0, 0, 0, 0,0,49,0,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Attack'),
(-@CGuid-1, 0, 13 ,0, 38, 0, 100, 0, 1, 2, 0,0,49,0,0,0,0,0,0,21,200,0,0,0,0,0,0, 'Blackbreath Crony - On Data Set - Attack'),
--
(-@CGuid-2, 0, 0 ,1, 11, 0, 100, 0, 0, 0, 0,0,18,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Spawn - Set Unit Flags'),
(-@CGuid-2, 0, 1 ,0, 61, 0, 100, 0, 0, 0, 0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Invisible'),
(-@CGuid-2, 0, 2 ,4, 38, 0, 100, 0, 1, 1, 0,0,47,1,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Data Set - Set visible'),
(-@CGuid-2, 0, 4 ,0, 61, 0, 100, 0, 0, 0, 0,0,53,0,9541001,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Start WP'),
(-@CGuid-2, 0, 5 ,6, 40, 0, 100, 0, 3, 0, 0,0,101,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - On Reached WP 5 - Set Home Position'),
(-@CGuid-2, 0, 6 ,7, 61, 0, 100, 0, 0, 0, 0,0,19,320,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Unit Flags'),
(-@CGuid-2, 0, 7 ,0, 61, 0, 100, 0, 0, 0, 0,0,89,3,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Set Random Movement'),
(-@CGuid-2, 0, 8, 0, 0, 0, 100, 0, 2000, 2000, 11000, 12000, 11, 15581, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blackbreath Crony - IC - Cast Sinister Strike'),
(-@CGuid-2, 0, 9, 0, 0, 0, 100, 0, 3000, 5000, 15000, 20000, 11, 15583, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blackbreath Crony - IC - Cast Rupture'),
(-@CGuid-2, 0, 10 ,11, 4, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9541,0,200,0,0,0,0, 'Blackbreath Crony - On Agro - Set Set Data'),
(-@CGuid-2, 0, 11 ,12,61, 0, 100, 0, 0, 0, 0,0,45,1,2,0,0,0,0,9,9537,0,200,0,0,0,0, 'Blackbreath Crony - On Agro - Set Set Data'),
(-@CGuid-2, 0, 12 ,0, 61, 0, 100, 0, 0, 0, 0,0,49,0,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Blackbreath Crony - Linked with Previous Event - Attack'),
(-@CGuid-2, 0, 13 ,0, 38, 0, 100, 0, 1, 2, 0,0,49,0,0,0,0,0,0,21,200,0,0,0,0,0,0, 'Blackbreath Crony - On Data Set - Attack');
DELETE FROM `creature_text` WHERE `entry` =9537;
INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextID`) VALUES
(9537, 1, 0, 'You''ll pay for that!', 12, 0, 100, 0, 0, 0, 'Hurley Blackbreath', 4936),
(9537, 0, 0, 'Get away from those kegs!', 14, 0, 100, 0, 0, 0, 'Hurley Blackbreath', 4934);
DELETE FROM `waypoints` WHERE `entry`IN (9537,9541,9541000,9541001);
INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES
(9537, 1, 886.916870,-149.176147,-49.760010, 'Hurley Blackbreath'),
(9537, 2, 897.698730,-137.324112,-49.752193, 'Hurley Blackbreath'),
(9537, 3, 898.569946,-141.830872,-49.755016, 'Hurley Blackbreath'),
(9541, 1, 885.926453,-145.907608,-49.760010, 'Blackbreath Crony'),
(9541, 2, 891.983093,-138.613907,-49.754261, 'Blackbreath Crony'),
(9541, 3, 896.412170,-144.160172,-49.757446, 'Blackbreath Crony'),
(9541000, 1, 888.984070,-152.598846,-49.760010, 'Blackbreath Crony'),
(9541000, 2, 895.560303,-134.140274,-49.748451, 'Blackbreath Crony'),
(9541000, 3, 897.199036,-139.512802,-49.755379, 'Blackbreath Crony'),
(9541001, 1, 886.916870,-149.176147,-49.760010, 'Blackbreath Crony'),
(9541001, 2, 899.913330,-133.534821,-49.747944, 'Blackbreath Crony'),
(9541001, 3, 901.009399,-139.603699,-49.755054, 'Blackbreath Crony');
DELETE FROM `creature` WHERE `id` IN(9537,9541);
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, 9541, 230, 1, 1, 0, 1, 879.018, -155.273, -49.7591, 0.57177, 300, 0, 0, 7359, 0, 0, 0, 0, 0),
(@CGuid+1, 9541, 230, 1, 1, 0, 1, 876.961, -151.796, -49.7591, 0.499513, 300, 0, 0, 7359, 0, 0, 0, 0, 0),
(@CGuid+2, 9541, 230, 1, 1, 0, 1, 876.535, -154.334, -49.7586, 0.339292, 300, 0, 0, 7359, 0, 0, 0, 0, 0),
(@CGuid+3, 9537, 230, 1, 1, 0, 1, 878.121, -153.074, -49.76, 0.527783, 300, 0, 0, 13070, 0, 0, 0, 0, 0);
@@ -0,0 +1,2 @@
--
UPDATE `quest_template` SET `SpecialFlags`=0 WHERE `Id`=8490;
@@ -0,0 +1,33 @@
--
SET @CGUID := 127340;
INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `MovementType`) VALUES
(@CGUID+0, 32801, 571, 1, 1, 4131.279, 5394.604, 26.09047, 3.595378, 120, 0, 0), -- 32801
(@CGUID+1, 32809, 571, 1, 1, 4454.667, 5623.537, 56.91562, 4.13643, 120, 0, 0), -- 32809
(@CGUID+2, 32810, 571, 1, 1, 5499.812, 4878.976, -197.8652, 3.176499, 120, 0, 0), -- 32810
(@CGUID+3, 32802, 571, 1, 1, 5360.002, 4834.393, -196.3981, 5.550147, 120, 0, 0), -- 32802
(@CGUID+4, 32811, 571, 1, 1, 3762.387, 1481.287, 92.8882, 3.438299, 120, 0, 0), -- 32811
(@CGUID+5, 32803, 571, 1, 1, 3936.924, -595.4437, 241.1534, 5.951573, 120, 0, 0), -- 32803
(@CGUID+6, 32812, 571, 1, 1, 2586.682, -4337.068, 276.0698, 4.13643, 120, 0, 0), -- 32812
(@CGUID+7, 32804, 571, 1, 1, 2466.965, -4892.675, 262.5474, 2.303835, 120, 0, 0), -- 32804
(@CGUID+8, 32813, 571, 1, 1, 3376.009, -2124.778, 124.664, 0.1396263, 120, 0, 0), -- 32813
(@CGUID+9, 32805, 571, 1, 1, 3400.944, -2890.375, 201.4968, 2.303835, 120, 0, 0), -- 32805
(@CGUID+10, 32814, 571, 1, 1, 6150.945, -1023.05, 408.3642, 1.43117, 120, 0, 0), -- 32814
(@CGUID+11, 32806, 571, 1, 1, 6087.442, -1105.523, 418.2672, 1.099557, 120, 0, 0), -- 32806
(@CGUID+12, 32815, 571, 1, 1, 5536.516, -733.7185, 149.6217, 3.124139, 120, 0, 0), -- 32815
(@CGUID+13, 32807, 571, 1, 1, 5141.776, -685.0027, 170.2738, 5.951573, 120, 0, 0), -- 32807
(@CGUID+14, 32816, 571, 1, 1, 5280.307, -2766.146, 292.5019, 2.303835, 120, 0, 0), -- 32816
(@CGUID+15, 32808, 571, 1, 1, 5627.932, -2616.493, 292.5019, 1.518436, 120, 0, 0), -- 32808
(@CGUID+16, 25892, 0, 1, 1, -8258.798, -2618.704, 133.3752, 1.343904, 120, 0, 0), -- 25892
(@CGUID+17, 25899, 1, 1, 1, -4391.495, 2187.865, 12.22644, 5.864306, 120, 0, 0), -- 25899
(@CGUID+18, 25936, 1, 1, 1, -2321.744, -619.7491, -9.089149, 5.67232, 120, 0, 0), -- 25936
(@CGUID+19, 25888, 530, 1, 1, -4219.219, -12310.55, 2.439188, 5.934119, 120, 0, 0), -- 25888
(@CGUID+20, 25891, 530, 1, 1, -2234.83, -11895.94, 26.62421, 4.694936, 120, 0, 0), -- 25891
(@CGUID+21, 25907, 530, 1, 1, -2998.854, 4164.042, 5.169014, 0.5934119, 120, 0, 0), -- 25907
(@CGUID+22, 25938, 530, 1, 1, -3067.278, 2387.903, 62.19349, 3.368485, 120, 0, 0), -- 25938
(@CGUID+23, 25905, 530, 1, 1, -3951.305, 2045.65, 95.14804, 4.520403, 120, 0, 0), -- 25905
(@CGUID+24, 25912, 530, 1, 1, 193.7309, 6016.713, 22.73373, 6.161012, 120, 0, 0), -- 25912
(@CGUID+25, 25903, 530, 1, 1, -2517.064, 7555.085, -1.793157, 5.375614, 120, 0, 0), -- 25903
(@CGUID+26, 25889, 530, 1, 1, 2024.906, 6590.532, 135.3214, 5.934119, 120, 0, 0), -- 25889
(@CGUID+27, 25926, 530, 1, 1, 2286.707, 6137.618, 136.3056, 1.570796, 120, 0, 0), -- 25926
(@CGUID+28, 25913, 530, 1, 1, 3127.551, 3743.148, 141.7706, 6.161012, 120, 0, 0), -- 25913
(@CGUID+29, 25918, 530, 1, 1, 2917.222, 3693.411, 143.7703, 2.932153, 120, 0, 0); -- 25918
@@ -0,0 +1,6 @@
--
SET @CGUID := 72776;
INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `MovementType`) VALUES
(@CGUID+0, 23108, 530, 1, 1, -493.0895, 7448.848, 178.6083, 4.83718, 120, 5, 1), -- 23108 (Area: 0)
(@CGUID+1, 23107, 530, 1, 1, -475.5646, 7463.805, 181.9694, 1.496497, 120, 5, 1), -- 23107 (Area: 0)
(@CGUID+2, 23106, 530, 1, 1, -511.7721, 7500.889, 183.1165, 5.096361, 120, 0, 0); -- 23106 (Area: 0)
@@ -0,0 +1,40 @@
-- Add support for {Q} A Tangled Skein ID: 12555
-- rewritten from sniff: thx Pitcrawler
SET @Sprayer := 28274;
SET @Thrower := 51165; -- Throws a web
SET @Summon := 51314; -- Summons Broken Sprayer GO
SET @Explosion := 53236; -- Explosion on fall
SET @Credit := 28289; -- Kill Credit
SET @Trigger := 29457; -- Trigger to permit explosion only when Sprayer reach him
SET @SpellTrigger := 51173; -- A Tangled Skein: Encasing Webs - Effect that procs from @Thrower
SET @EncasingWebs := 51168; -- The visual that A Tangled Skein: Encasing Webs - Effect should apply
SET @SummonTrigger := 54496;
SET @Script := 2827400;
-- Add SAI support for Plague Sprayer
UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@Sprayer; -- they shouldn't be attackable, but unit_flag 2 cause evade
UPDATE `creature_template` SET `AIName`='SmartAI',`InhabitType`=1 WHERE `entry`=@Trigger; -- need this to make trigger (while guardian) stay at ground
DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@Sprayer,@Trigger) AND `source_type`=0;
DELETE FROM `smart_scripts` WHERE `entryorguid`=@Script AND `source_type`=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
(@Trigger,0,0,0,54,0,100,0,0,0,0,0,75,@EncasingWebs,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Plagued Sprayer - On just summoned - Cast Encasing Webs'),
(@Sprayer,0,0,0,25,0,100,0,0,0,0,0,8,0,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Plagued Sprayer - On spawn/reset - Set react state passive'),
(@Sprayer,0,1,0,8,0,100,1,@Thrower,0,0,0,64,1,0,0,0,0,0,7,0,0,0,0,0,0,0, 'Plagued Sprayer - On spell hit by player with thrower - Store invoker as target'),
(@Sprayer,0,2,3,8,0,100,1,@SpellTrigger,0,0,0,11,@SummonTrigger,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Plagued Sprayer - On spell hit by item spell - Cast summon trigger'),
(@Sprayer,0,3,0,61,0,100,1,0,0,0,0,59,1,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Plagued Sprayer - Linked with previous event - Set run on'),
(@Sprayer,0,4,0,23,0,100,1,@EncasingWebs,1,0,0,69,1,0,0,0,0,0,19,@Trigger,20,0,0,0,0,0, 'Plagued Sprayer - On creature has aura Encasing Webs - Move to closest trigger in 20 yards'),
(@Sprayer,0,5,0,34,0,100,1,8,1,0,0,80,@Script,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Plagued Sprayer - On point 1 reached - Start action list'),
-- Script
(@Script,9,0,0,0,0,100,0,0,0,0,0,11,@Explosion,0,0,0,0,0,1,0,0,0,0,0,0,0,'Plagued Sprayer - Action 0 - Cast huge explosion on self'),
(@Script,9,1,0,0,0,100,0,300,300,0,0,33,@Credit,0,0,0,0,0,12,1,0,0,0,0,0,0,'Plagued Sprayer - Action 1 - Give credit to stored invoker'),
(@Script,9,2,0,0,0,100,0,0,0,0,0,11,@Summon,0,0,0,0,0,1,0,0,0,0,0,0,0,'Plagued Sprayer - Action 2 - Cast summon broken GO sprayer on self'), -- need small delay for the explosion to be displayed
(@Script,9,3,0,0,0,100,0,0,0,0,0,37,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Plagued Sprayer - Action 3 - Die'),
(@Script,9,4,0,0,0,100,0,0,0,0,0,47,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Plagued Sprayer - Action 4 - Set unseen');
-- Conditions
DELETE FROM `conditions` WHERE `SourceEntry`=@Thrower AND `SourceTypeOrReferenceId`=17;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(17,0,@Thrower,0,0,31,1,3,@Sprayer,0,0,0,'', 'Thrower can target only Plague Sprayer');
-- Delete wrong, nonexistant Trigger spawn
DELETE FROM `creature` WHERE `id`=@Trigger;
-- Update creature data for plague sprayers they should have movement type 0
UPDATE `creature` SET `spawndist`=0,`MovementType`=0 WHERE `id`=@Sprayer;
UPDATE `creature_template` SET `InhabitType`=4 WHERE `entry`=28274;
@@ -0,0 +1,10 @@
-- Fix for ... and a Batch of Ooze (4294) and ... and a Batch of Ooze (4293)
UPDATE `quest_template` SET `PrevQuestId`=0 WHERE `Id`=4661; -- Testing for Impurities - Un'Goro Crater
UPDATE `quest_template` SET `PrevQuestId`=0 WHERE `Id`=4561; -- Testing for Corruption - Felwood
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN(19,20) AND `SourceEntry` IN (4661,4561);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(19, 0, 4561, 0, 0, 9, 0, 4294, 0, 0, 0, 0, 0, '', 'player needs to be on quest ... and a Batch of Ooze to see Testing for Impurities - UnGoro Crater'),
(19, 0, 4661, 0, 0, 9, 0, 4293, 0, 0, 0, 0, 0, '', 'player needs to be on quest and a batch of slime to see Testing for Corruption - Felwood'),
(20, 0, 4561, 0, 0, 9, 0, 4294, 0, 0, 0, 0, 0, '', 'player needs to be on quest ... and a Batch of Ooze to see Testing for Impurities - UnGoro Crater'),
(20, 0, 4661, 0, 0, 9, 0, 4293, 0, 0, 0, 0, 0, '', 'player needs to be on quest and a batch of slime to see Testing for Corruption - Felwood');
@@ -0,0 +1,17 @@
UPDATE `creature_template` SET `AIName`= 'SmartAI',`ScriptName`='' WHERE `entry` =17542;
DELETE FROM `smart_scripts` WHERE `entryorguid` =17542;
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
(17542,0,0,1,8,0,100,0,8593,0,0,0,33,17542,0,0,0,0,0,7,0,0,0,0,0,0,0,'Young Furbolg Shaman - On Spell Hit - Give Kill Credit'),
(17542,0,1,2,61,0,100,0,0,0,0,0,28,29266,0,0,0,0,0,1,0,0,0,0,0,0,0,'Young Furbolg Shaman - Linked with Previous Event - Remove permament Feign Death'),
(17542,0,2,0,61,0,100,0,0,0,0,0,23,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Young Furbolg Shaman - Linked with Previous Event - Set Phase 2'),
(17542,0,4,5, 1,2,100,0,60000,60000,60000,60000,11,29266,2,0,0,0,0,1,0,0,0,0,0,0,0,'Young Furbolg Shaman - OOC - Cast Permament Feign Death'),
(17542,0,5,0,61,2,100,0,0,0,0,0,23,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Young Furbolg Shaman - Linked with Previous Event - Set Phase 1'),
(17542,0,6,0,25,0,100,0,0,0,0,0,11,29266,2,0,0,0,0,1,0,0,0,0,0,0,0,'Young Furbolg Shaman - On Spawn - Cast Permament Feign Death');
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=8593;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(13, 1, 8593, 0, 0, 31, 0, 3, 17542, 0, 0, 0, 0, '', 'Symbol of Life can be casted on Young Furbolg Shaman'),
(13, 1, 8593, 0, 1, 31, 0, 3, 6172, 0, 0, 0, 0, '', 'Symbol of Life can be casted on Henze Faulk'),
(13, 1, 8593, 0, 2, 31, 0, 3, 6177, 0, 0, 0, 0, '', 'Symbol of Life can be casted on Narm Faulk');
@@ -0,0 +1,4 @@
--
DELETE FROM `conditions` WHERE `SourceEntry`=28700 AND `SourceTypeOrReferenceId`=17;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `Comment`) VALUES
(17,0,28700,0,0,30,0,181433,15,0,0,0,0,'Disperse Neutralizing Agent (28700) can be used only near the Irradiated Power Crystal (181433)');
@@ -0,0 +1,5 @@
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=8593;
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(13, 1, 8593, 0, 0, 31, 0, 3, 17542, 0, 0, 0, 0, '', 'Symbol of Life can be casted on Young Furbolg Shaman'),
(13, 1, 8593, 0, 1, 31, 0, 3, 6172, 0, 0, 0, 0, '', 'Symbol of Life can be casted on Henze Faulk'),
(13, 1, 8593, 0, 2, 31, 0, 3, 6177, 0, 0, 0, 0, '', 'Symbol of Life can be casted on Narm Faulk');
+1 -1
View File
@@ -537,9 +537,9 @@ void SmartAI::JustRespawned()
me->SetVisible(true);
if (me->getFaction() != me->GetCreatureTemplate()->faction)
me->RestoreFaction();
GetScript()->ProcessEventsFor(SMART_EVENT_RESPAWN);
mJustReset = true;
JustReachedHome();
GetScript()->ProcessEventsFor(SMART_EVENT_RESPAWN);
mFollowGuid = 0;//do not reset follower on Reset(), we need it after combat evade
mFollowDist = 0;
mFollowAngle = 0;
+22 -10
View File
@@ -142,7 +142,7 @@ bool ForcedDespawnDelayEvent::Execute(uint64 /*e_time*/, uint32 /*p_time*/)
}
Creature::Creature(bool isWorldObject): Unit(isWorldObject), MapObject(),
lootForPickPocketed(false), lootForBody(false), m_groupLootTimer(0), lootingGroupLowGUID(0),
lootForPickPocketed(false), _pickpocketLootRestore(0), lootForBody(false), lootForSkinned(false), _skinner(0), m_groupLootTimer(0), lootingGroupLowGUID(0),
m_PlayerDamageReq(0), m_lootRecipient(0), m_lootRecipientGroup(0), m_corpseRemoveTime(0), m_respawnTime(0),
m_respawnDelay(300), m_corpseDelay(60), m_respawnradius(0.0f), m_reactState(REACT_AGGRESSIVE),
m_defaultMovementType(IDLE_MOTION_TYPE), m_DBTableGuid(0), m_equipmentId(0), m_originalEquipmentId(0), m_AlreadyCallAssistance(false),
@@ -548,6 +548,15 @@ void Creature::Update(uint32 diff)
if (!IsAlive())
break;
time_t now = time(NULL);
// Check if we should refill the pickpocketing loot
if (lootForPickPocketed && _pickpocketLootRestore && _pickpocketLootRestore <= now)
{
lootForPickPocketed = false;
_pickpocketLootRestore = 0;
}
if (m_regenTimer > 0)
{
if (diff >= m_regenTimer)
@@ -1538,9 +1547,10 @@ void Creature::Respawn(bool force)
TC_LOG_DEBUG("entities.unit", "Respawning creature %s (GuidLow: %u, Full GUID: " UI64FMTD " Entry: %u)",
GetName().c_str(), GetGUIDLow(), GetGUID(), GetEntry());
m_respawnTime = 0;
_pickpocketLootRestore = 0;
lootForPickPocketed = false;
lootForBody = false;
lootForBody = false;
lootForSkinned = false;
if (m_originalEntry != GetEntry())
UpdateEntry(m_originalEntry);
@@ -2280,19 +2290,16 @@ void Creature::AllLootRemovedFromCorpse()
if (m_corpseRemoveTime <= now)
return;
float decayRate;
float decayRate = sWorld->getRate(RATE_CORPSE_DECAY_LOOTED);
CreatureTemplate const* cinfo = GetCreatureTemplate();
decayRate = sWorld->getRate(RATE_CORPSE_DECAY_LOOTED);
uint32 diff = uint32((m_corpseRemoveTime - now) * decayRate);
m_respawnTime -= diff;
// corpse skinnable, but without skinning flag, and then skinned, corpse will despawn next update
if (cinfo && cinfo->SkinLootId)
m_corpseRemoveTime = time(NULL);
else
m_corpseRemoveTime -= diff;
m_corpseRemoveTime = now + m_corpseDelay * decayRate;
m_respawnTime = m_corpseRemoveTime + m_respawnTime;
}
}
@@ -2614,3 +2621,8 @@ void Creature::ReleaseFocus(Spell const* focusSpell)
ClearUnitState(UNIT_STATE_ROTATING);
}
void Creature::StartPickPocketRefillTimer()
{
_pickpocketLootRestore = time(NULL) + sWorld->getIntConfig(CONFIG_CREATURE_PICKPOCKET_REFILL);
}
@@ -550,6 +550,11 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject
Loot loot;
bool lootForPickPocketed;
bool lootForBody;
bool lootForSkinned;
void StartPickPocketRefillTimer();
void ResetPickPocketRefillTimer() { _pickpocketLootRestore = 0; }
void SetSkinner(uint64 guid) { _skinner = guid; }
uint64 GetSkinner() const { return _skinner; } // Returns the player who skinned this creature
Player* GetLootRecipient() const;
Group* GetLootRecipientGroup() const;
bool hasLootRecipient() const { return m_lootRecipient || m_lootRecipientGroup; }
@@ -685,8 +690,10 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject
uint64 m_lootRecipient;
uint32 m_lootRecipientGroup;
uint64 _skinner;
/// Timers
time_t _pickpocketLootRestore;
time_t m_corpseRemoveTime; // (msecs)timer for death or corpse disappearance
time_t m_respawnTime; // (secs) time of next respawn
uint32 m_respawnDelay; // (secs) delay between corpse disappearance and respawning
+11 -7
View File
@@ -2987,11 +2987,10 @@ void Player::UninviteFromGroup()
void Player::RemoveFromGroup(Group* group, uint64 guid, RemoveMethod method /* = GROUP_REMOVEMETHOD_DEFAULT*/, uint64 kicker /* = 0 */, const char* reason /* = NULL */)
{
if (group)
{
group->RemoveMember(guid, method, kicker, reason);
group = NULL;
}
if (!group)
return;
group->RemoveMember(guid, method, kicker, reason);
}
void Player::SendLogXPGain(uint32 GivenXP, Unit* victim, uint32 BonusXP, bool recruitAFriend, float /*group_rate*/)
@@ -9186,6 +9185,7 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
if (!creature->lootForPickPocketed)
{
creature->lootForPickPocketed = true;
creature->StartPickPocketRefillTimer();
loot->clear();
if (uint32 lootid = creature->GetCreatureTemplate()->pickpocketLootId)
@@ -9234,8 +9234,12 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
// possible only if creature->lootForBody && loot->empty() at spell cast check
if (loot_type == LOOT_SKINNING)
{
loot->clear();
loot->FillLoot(creature->GetCreatureTemplate()->SkinLootId, LootTemplates_Skinning, this, true);
if (!creature->lootForSkinned)
{
creature->lootForSkinned = true;
loot->clear();
loot->FillLoot(creature->GetCreatureTemplate()->SkinLootId, LootTemplates_Skinning, this, true);
}
permission = OWNER_PERMISSION;
}
// set group rights only for loot_type != LOOT_SKINNING
+3
View File
@@ -13670,7 +13670,10 @@ void Unit::Kill(Unit* victim, bool durabilityLoss)
{
Loot* loot = &creature->loot;
if (creature->lootForPickPocketed)
{
creature->ResetPickPocketRefillTimer();
creature->lootForPickPocketed = false;
}
loot->clear();
if (uint32 lootid = creature->GetCreatureTemplate()->lootid)
+5 -1
View File
@@ -364,11 +364,15 @@ void WorldSession::DoLootRelease(uint64 lguid)
loot = &creature->loot;
if (loot->isLooted())
{
creature->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
if (loot->loot_type == LOOT_SKINNING)
creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_SKINNABLE);
// skip pickpocketing loot for speed, skinning timer reduction is no-op in fact
if (!creature->IsAlive())
creature->AllLootRemovedFromCorpse();
creature->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
loot->clear();
}
else
+4 -2
View File
@@ -5120,11 +5120,13 @@ SpellCastResult Spell::CheckCast(bool strict)
return SPELL_FAILED_TARGET_UNSKINNABLE;
Creature* creature = m_targets.GetUnitTarget()->ToCreature();
if (creature->GetCreatureType() != CREATURE_TYPE_CRITTER && !creature->loot.isLooted())
if (creature->GetCreatureType() != CREATURE_TYPE_CRITTER && creature->loot.loot_type != LOOT_SKINNING && !creature->loot.isLooted())
return SPELL_FAILED_TARGET_NOT_LOOTED;
uint32 skill = creature->GetCreatureTemplate()->GetRequiredLootSkill();
bool alreadySkinned = creature->loot.loot_type == LOOT_SKINNING && creature->GetSkinner() == m_caster->GetGUID();
int32 skillValue = m_caster->ToPlayer()->GetSkillValue(skill);
int32 TargetLevel = m_targets.GetUnitTarget()->getLevel();
int32 ReqValue = (skillValue < 100 ? (TargetLevel-10) * 10 : TargetLevel * 5);
@@ -5134,7 +5136,7 @@ SpellCastResult Spell::CheckCast(bool strict)
// chance for fail at orange skinning attempt
if ((m_selfContainer && (*m_selfContainer) == this) &&
skillValue < sWorld->GetConfigMaxSkillValue() &&
(ReqValue < 0 ? 0 : ReqValue) > irand(skillValue - 25, skillValue + 37))
(ReqValue < 0 ? 0 : ReqValue) > irand(skillValue - 25, skillValue + 37) && !alreadySkinned)
return SPELL_FAILED_TRY_AGAIN;
break;
+15 -2
View File
@@ -4427,15 +4427,28 @@ void Spell::EffectSkinning(SpellEffIndex /*effIndex*/)
uint32 skill = creature->GetCreatureTemplate()->GetRequiredLootSkill();
bool awardPoints = true;
// Check if a skinning loot table was already generated for this creature
if (creature->loot.loot_type == LOOT_SKINNING)
{
if (creature->GetSkinner() != m_caster->GetGUID())
return;
awardPoints = false; // Do not grant skill points for this loot, they were already granted the first time.
}
else
creature->SetSkinner(m_caster->GetGUID());
m_caster->ToPlayer()->SendLoot(creature->GetGUID(), LOOT_SKINNING);
creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_SKINNABLE);
int32 reqValue = targetLevel < 10 ? 0 : targetLevel < 20 ? (targetLevel-10)*10 : targetLevel*5;
int32 skillValue = m_caster->ToPlayer()->GetPureSkillValue(skill);
// Double chances for elites
m_caster->ToPlayer()->UpdateGatherSkill(skill, skillValue, reqValue, creature->isElite() ? 2 : 1);
if (awardPoints)
m_caster->ToPlayer()->UpdateGatherSkill(skill, skillValue, reqValue, creature->isElite() ? 2 : 1);
}
void Spell::EffectCharge(SpellEffIndex /*effIndex*/)
+2
View File
@@ -1078,6 +1078,8 @@ void World::LoadConfigSettings(bool reload)
m_bool_configs[CONFIG_OFFHAND_CHECK_AT_SPELL_UNLEARN] = sConfigMgr->GetBoolDefault("OffhandCheckAtSpellUnlearn", true);
m_int_configs[CONFIG_CREATURE_PICKPOCKET_REFILL] = sConfigMgr->GetIntDefault("Creature.PickPocketRefillDelay", 10 * MINUTE);
if (int32 clientCacheId = sConfigMgr->GetIntDefault("ClientCacheVersion", 0))
{
// overwrite DB/old value
+1
View File
@@ -349,6 +349,7 @@ enum WorldIntConfigs
CONFIG_BG_REWARD_LOSER_HONOR_LAST,
CONFIG_BG_REWARD_WINNER_CONQUEST_FIRST,
CONFIG_BG_REWARD_WINNER_CONQUEST_LAST,
CONFIG_CREATURE_PICKPOCKET_REFILL,
INT_CONFIG_VALUE_COUNT
};
@@ -190,6 +190,9 @@ enum InfusedCrystal
// Quest
QUEST_POWERING_OUR_DEFENSES = 8490,
// Quest Credit
QUEST_POD_CREDIT = 16364,
// Says
EMOTE = 0,
@@ -266,24 +269,17 @@ public:
summoned->AI()->AttackStart(me);
}
void JustDied(Unit* /*killer*/) override
{
if (PlayerGUID && !Completed)
if (Player* player = ObjectAccessor::GetPlayer(*me, PlayerGUID))
player->FailQuest(QUEST_POWERING_OUR_DEFENSES);
}
void UpdateAI(uint32 diff) override
{
if (EndTimer < diff && Progress)
{
Talk(EMOTE);
Completed = true;
if (PlayerGUID)
if (Player* player = ObjectAccessor::GetPlayer(*me, PlayerGUID))
player->CompleteQuest(QUEST_POWERING_OUR_DEFENSES);
me->DealDamage(me, me->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
{
Talk(EMOTE, player);
player->KilledMonsterCredit(QUEST_POD_CREDIT);
}
me->RemoveCorpse();
} else EndTimer -= diff;
@@ -1317,6 +1317,14 @@ Rate.Creature.Elite.RARE.HP = 1
Rate.Creature.Elite.RAREELITE.HP = 1
Rate.Creature.Elite.WORLDBOSS.HP = 1
#
# Creature.PickPocketRefillDelay
# Description: Time in seconds that the server will wait before refilling the pickpocket loot
# for a creature
# Default: 600
Creature.PickPocketRefillDelay = 600
#
# ListenRange.Say
# Description: Distance in which players can read say messages from creatures or