diff options
38 files changed, 319 insertions, 290 deletions
diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 00000000000..9be57a5afb6 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,23 @@ +language: cpp +compiler: + - clang + +before_install: + - echo "yes" | sudo add-apt-repository ppa:kalakris/cmake + - echo "yes" | sudo add-apt-repository ppa:boost-latest/ppa + - echo "yes" | sudo add-apt-repository ppa:ubuntu-toolchain-r/test + - sudo apt-get update -qq + - sudo apt-get install build-essential libtool gcc-4.8 g++-4.8 make cmake openssl libssl-dev libmysqlclient15-dev libmysql++-dev libreadline6-dev zlib1g-dev libbz2-dev libboost1.55-dev libboost-thread1.55-dev libboost-system1.55-dev libboost-program-options1.55-dev + - mkdir bin + - cd bin + - cmake ../ -DWITH_WARNINGS=1 -DWITH_COREDEBUG=1 -DUSE_COREPCH=0 -DUSE_SCRIPTPCH=0 -DTOOLS=1 -DSCRIPTS=1 -DSERVERS=1 -DCMAKE_BUILD_TYPE=Release + +script: make -j 8 + +branches: + only: + - master + - 4.3.4 + +git: + depth: 1 diff --git a/README.md b/README.md index 80eb03d9879..d89fd842687 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ #  TrinityCore +[](https://travis-ci.org/TrinityCore/TrinityCore) +[](https://scan.coverity.com/projects/435) ## Introduction diff --git a/sql/updates/world/2014_07_20_03_world_misc.sql b/sql/updates/world/2014_07_20_03_world_misc.sql new file mode 100644 index 00000000000..f81666d035b --- /dev/null +++ b/sql/updates/world/2014_07_20_03_world_misc.sql @@ -0,0 +1,8 @@ +-- +DELETE FROM `gossip_menu` WHERE `entry`=24 and `text_id`=521; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(24, 521); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=24 AND `SourceEntry`=521; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 24, 521, 0, 0, 8, 0, 770, 0, 0, 0, 0, 0, '', 'Show gossip text if player has quest 770 completed'); diff --git a/sql/updates/world/2014_07_20_04_world_misc.sql b/sql/updates/world/2014_07_20_04_world_misc.sql new file mode 100644 index 00000000000..7c6fb4638f2 --- /dev/null +++ b/sql/updates/world/2014_07_20_04_world_misc.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=7353; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 7353, 8776, 0, 0, 8, 0, 9312, 0, 0, 0, 0, 0, '', 'Show gossip text if player has quest 9312 completed'), +(14, 7353, 8777, 0, 0, 8, 0, 9305, 0, 0, 0, 0, 0, '', 'Show gossip text if player has quest 9305 completed'); diff --git a/sql/updates/world/2014_07_20_05_world_misc.sql b/sql/updates/world/2014_07_20_05_world_misc.sql new file mode 100644 index 00000000000..b7e95ae645d --- /dev/null +++ b/sql/updates/world/2014_07_20_05_world_misc.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `flags_extra`=128 WHERE `entry`=37610; diff --git a/sql/updates/world/2014_07_21_00_world_misc.sql b/sql/updates/world/2014_07_21_00_world_misc.sql new file mode 100644 index 00000000000..4e649dc52d4 --- /dev/null +++ b/sql/updates/world/2014_07_21_00_world_misc.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `creature_addon` WHERE `guid` IN (SELECT `guid` FROM `creature` WHERE `id` = 19768); +UPDATE creature_template_addon SET `bytes1`=0, `bytes2`=0 WHERE `entry` IN (19762, 19768, 19784); diff --git a/sql/updates/world/2014_07_21_01_world_misc.sql b/sql/updates/world/2014_07_21_01_world_misc.sql new file mode 100644 index 00000000000..46d6e43ab63 --- /dev/null +++ b/sql/updates/world/2014_07_21_01_world_misc.sql @@ -0,0 +1,2 @@ +-- +UPDATE `quest_template` SET `RequiredRaces`=0 WHERE `Id` IN (834,835); diff --git a/sql/updates/world/2014_07_21_02_world_creature_template.sql b/sql/updates/world/2014_07_21_02_world_creature_template.sql new file mode 100644 index 00000000000..cb616c84033 --- /dev/null +++ b/sql/updates/world/2014_07_21_02_world_creature_template.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `resistance6`=0 WHERE `entry` IN (15649,15650); diff --git a/sql/updates/world/2014_07_21_03_world_creature.sql b/sql/updates/world/2014_07_21_03_world_creature.sql new file mode 100644 index 00000000000..a5604a4cb0a --- /dev/null +++ b/sql/updates/world/2014_07_21_03_world_creature.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature` SET `position_z`=120.9 WHERE `guid`=93289; diff --git a/sql/updates/world/2014_07_21_04_world_spell_script_names.sql b/sql/updates/world/2014_07_21_04_world_spell_script_names.sql new file mode 100644 index 00000000000..c7080adb88e --- /dev/null +++ b/sql/updates/world/2014_07_21_04_world_spell_script_names.sql @@ -0,0 +1,6 @@ +DELETE FROM spell_script_names WHERE spell_id IN (69507, 71213, 73189, 73190); +INSERT INTO spell_script_names VALUES +(69507, 'spell_rotface_slime_spray'), +(71213, 'spell_rotface_slime_spray'), +(73189, 'spell_rotface_slime_spray'), +(73190, 'spell_rotface_slime_spray'); diff --git a/sql/updates/world/2014_07_21_05_world_misc.sql b/sql/updates/world/2014_07_21_05_world_misc.sql new file mode 100644 index 00000000000..7b6acc1e80d --- /dev/null +++ b/sql/updates/world/2014_07_21_05_world_misc.sql @@ -0,0 +1,89 @@ +-- +DELETE FROM `creature_text` WHERE `entry` IN(18303,18668,18669,18724,18671,18337); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextID`) VALUES +(18303, 0, 0, 'My brothers and sisters. Listen to me. We must speak of the survival of our people. We have narrowly survived one calamity, but I fear the next shall destroy us.', 12, 0, 100, 1, 0, 0, 'Lyria Skystrider', 15673), +(18303, 1, 0, 'Can you not see what is happening? Open your eyes. It is laid bare for all to see. What is this new alliance? Why have we betrayed our allies of old, only to take up with the enemies of all that live?', 12, 0, 100, 1, 0, 0, 'Lyria Skystrider', 15674), +(18668, 0, 0, 'No, you''re wrong! We were the ones betrayed!', 12, 0, 100, 22, 0, 0, 'Vaeron Kormar', 15675), +(18669, 0, 0, 'When have the dwarves ever been our friends?', 12, 0, 100, 11, 0, 0, 'Terric Brightwind', 15676), +(18724, 0, 0, 'The humans abandoned us in our darkest hour! Their prince himself led the assault on our lands.', 12, 0, 100, 25, 0, 0, 'Melaya Tassier', 15677), +(18671, 0, 0, 'You fool! The prince''s minions were the very Forsaken we have now allied ourselves with, and now he has betrayed us!', 12, 0, 100, 5, 0, 0, 'Priest Ennas', 15678), +(18668, 1, 0, 'The Ranger-General of Silvermoon will be a loyal ally!', 12, 0, 100, 1, 0, 0, 'Vaeron Kormar',15679), +(18303, 2, 0, 'You speak of her as friend? You are a fool. This "Dark Lady" is not Sylvanas.', 12, 0, 100, 1, 0, 0, 'Lyria Skystrider', 15680), +(18668, 2, 0, 'Blood will be true. We can trust in none but our own!', 12, 0, 100, 25, 0, 0, 'Vaeron Kormar', 15738), +(18303, 3, 0, 'Blood? And these orcs, these fair weather friends? They will aid us?', 12, 0, 100, 11, 0, 0, 'Lyria Skystrider', 15743), +(18671, 1, 0, 'A great blight lies across our land! It grows every day. Our need for magic weakens us, and will bring us to destruction, just as it has before!', 12, 0, 100, 25, 0, 0, 'Priest Ennas', 15744), +(18669, 1, 0, 'How are we to live without magic?', 12, 0, 100, 5, 0, 0, 'Terric Brightwind', 15745), +(18724, 1, 0, 'Look at the wonders of this city! This is magic.', 12, 0, 100, 5, 0, 0, 'Melaya Tassier', 15747), +(18671, 2, 0, 'But at what cost? You''ve all been blinded. We have all been blinded.', 12, 0, 100, 1, 0, 0, 'Priest Ennas', 15748), +(18668, 3, 0, 'You call us traitors?', 12, 0, 100, 25, 0, 0, 'Vaeron Kormar', 15749), +(18303, 4, 0, 'The magisters are the traitors! They have sealed our doom.', 12, 0, 100, 25, 0, 0, 'Lyria Skystrider', 15750), +(18669, 2, 0, 'Idealistic blather. Go back to your forests!', 12, 0, 100, 3, 0, 0, 'Terric Brightwind', 15751), +(18724, 2, 0, 'You would have us live like the savages!', 12, 0, 100, 5, 0, 0, 'Melaya Tassier', 15752), +(18671, 3, 0, 'No, not savagery! Conscience. The excesses of our people will destroy us, and all that we have struggled to build.', 12, 0, 100, 1, 0, 0, 'Priest Ennas', 15753), +(18303, 5, 0, 'We have not struggled so hard to survive, only to bring about the true destruction.', 12, 0, 100, 1, 0, 0, 'Lyria Skystrider', 15754), +(18671, 4, 0, 'We stand on the brink of destruction. We must reconsider this rash course of action.', 12, 0, 100, 5, 0, 0, 'Priest Ennas', 15756), +-- Summon +(18303, 6, 0, 'If we speak as one, we cannot be ignored!', 12, 0, 100, 1, 0, 0, 'Lyria Skystrider', 15917), +(18671, 5, 0, 'Lend us your voices! Now is the time we must act to save our people.', 12, 0, 100, 1, 0, 0, 'Priest Ennas', 15918), +(18671, 6, 0, 'Lor''themar must hear us! We will not be silenced!', 12, 0, 100, 5, 0, 0, 'Priest Ennas', 15919), +-- Mind Control +(18337, 0, 0, 'That should take care of that. Summon me if you have further need of my services.', 12, 0, 100, 11, 0, 0, 'Priest Kath''mar', 15922), +(18303, 7, 0, 'We will repay the betrayal of the Alliance! We shall never forget, and never forgive!', 12, 1, 100, 21, 0, 0, 'Lyria Skystrider', 15930), +(18671, 7, 0, 'Lor''themar has remade Silvermoon into something we may truly be proud of.', 12, 1, 100, 21, 0, 0, 'Priest Ennas', 15924), +(18671, 8, 0, 'The magisters are wise and will plot a prosperous course for our future.', 12, 1, 100, 21, 0, 0, 'Priest Ennas', 15926); + +UPDATE `creature_template` SET AIName='SmartAI' WHERE `entry`IN(18303,18782,18336,18337,18671,18337, 18799); + +DELETE FROM `smart_scripts` WHERE (`entryorguid` IN(18303,18782,18336,19337,18671,18337, 18799) AND `source_type`=0); +DELETE FROM `smart_scripts` WHERE (`entryorguid` IN(1830300, 1833700) 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 +(18303, 0, 0, 0, 1, 0, 100, 0, 15000, 30000, 300000, 450000, 80, 1830300, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - OOC - Run Script'), +(18782, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 32948, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Silvermoon Ritual of Summoning Dummy - On Data Set - Cast Ritual of Summoning'), +(18336, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 32928, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sivermoon Magister - On Data Set - Cast Ritual of Summoning'), +(18336, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 11, 32899, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Sivermoon Magister - On Data Set - Cast Ritual of Summoning'), +(18337, 0, 0, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, 1833700, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Priest Kath''mar - On Spawn - Run Script'), +(18671, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 28, 32976, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Priest Ennas - On Data Set - Remove Aura Cinematic - Mind Control'), +(18671, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 11, 32976, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Priest Ennas - On Data Set - Cast Cinematic - Mind Control'), +(18303, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 11, 32976, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - On Data Set - Cast Cinematic - Mind Control'), +(18799, 0, 0, 0, 1, 0, 100, 0, 0, 5000, 25000, 40000, 5, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Silvermoon Citizen - OOC - One shot cheer'), +(1833700, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 19, 18303, 0, 0, 0, 0, 0, 0, 'Priest Kath''mar - Script - Cast Cinematic - Mind Control'), +(1833700, 9, 1, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 45, 2, 2, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Priest Kath''mar - Script - Cast Cinematic - Mind Control'), +(1833700, 9, 2, 0, 0, 0, 100, 0, 30000, 30000, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Priest Kath''mar - Script - Despawn'), +(1830300, 9, 0, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 1'), +(1830300, 9, 1, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 2'), +(1830300, 9, 2, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 19, 18668, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 1 (Vaeron Kormar)'), +(1830300, 9, 3, 0, 0, 0, 100, 0, 7000, 7000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 19, 18669, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 1 (Terric Brightwind)'), +(1830300, 9, 4, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 19, 18724, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 1 (Melaya Tassier)'), +(1830300, 9, 5, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 1 (Priest Ennas)'), +(1830300, 9, 6, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 19, 18668, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 2 (Vaeron Kormar)'), +(1830300, 9, 7, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 3'), +(1830300, 9, 8, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 19, 18668, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 3 (Vaeron Kormar)'), +(1830300, 9, 9, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 4'), +(1830300, 9, 10, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 2 (Priest Ennas)'), +(1830300, 9, 11, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 19, 18669, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 2 (Terric Brightwind)'), +(1830300, 9, 12, 0, 0, 0, 100, 0, 8000, 8000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 19, 18724, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 2 (Melaya Tassier)'), +(1830300, 9, 13, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 3 (Priest Ennas)'), +(1830300, 9, 14, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 3, 0, 0, 0, 0, 0, 19, 18668, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 4 (Vaeron Kormar)'), +(1830300, 9, 15, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 5'), +(1830300, 9, 16, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 19, 18669, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 3 (Terric Brightwind)'), +(1830300, 9, 17, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 19, 18724, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 3 (Melaya Tassier)'), +(1830300, 9, 18, 0, 0, 0, 100, 0, 10000, 10000, 0, 0, 1, 3, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 4 (Priest Ennas)'), +(1830300, 9, 19, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 6'), +(1830300, 9, 20, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, 65672, 18336, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Set Data Silvermoon Magister 1'), +(1830300, 9, 21, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 65674, 18336, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Set Data Silvermoon Magister 2'), +(1830300, 9, 22, 0, 0, 0, 100, 0, 500, 500, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 65673, 18336, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Set Data Silvermoon Magister 3'), +(1830300, 9, 23, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 18782, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Set Data Silvermoon Ritual of Summoning Dummy'), +(1830300, 9, 24, 0, 0, 0, 100, 0, 5500, 5500, 0, 0, 1, 6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 7'), +(1830300, 9, 25, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 4, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 5 (Priest Ennas)'), +(1830300, 9, 26, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 5, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 6 (Priest Ennas)'), +(1830300, 9, 27, 0, 0, 0, 100, 0, 6500, 6500, 0, 0, 45, 2, 2, 0, 0, 0, 0, 19, 18782, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Set Data Silvermoon Ritual of Summoning Dummy'), +(1830300, 9, 28, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 6, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 7 (Priest Ennas)'), +(1830300, 9, 29, 0, 0, 0, 100, 0, 0, 0, 0, 0, 12, 18337, 1, 60000, 0, 0, 0, 8, 0, 0, 0, 9518.375, -7103.683, 14.33718, 2.251475, 'Lyria Skystrider - Script - Spawn Priest Kath''mar'), +(1830300, 9, 30, 0, 0, 0, 100, 0, 7000, 7000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 19, 18337, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 1 (Priest Kath''mar)'), +(1830300, 9, 31, 0, 0, 0, 100, 0, 7000, 7000, 0, 0, 1, 7, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 8'), +(1830300, 9, 32, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 7, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 8 (Priest Ennas)'), +(1830300, 9, 33, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 8, 0, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Say Line 9 (Priest Ennas)'), +(1830300, 9, 34, 0, 0, 0, 100, 0, 60000, 60000, 0, 0, 28, 32976, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Remove Aura Cinematic - Mind Control'), +(1830300, 9, 35, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 18671, 0, 0, 0, 0, 0, 0, 'Lyria Skystrider - Script - Set Data (Priest Ennas)'); + + diff --git a/sql/updates/world/2014_07_21_06_world_misc.sql b/sql/updates/world/2014_07_21_06_world_misc.sql new file mode 100644 index 00000000000..5d66620740d --- /dev/null +++ b/sql/updates/world/2014_07_21_06_world_misc.sql @@ -0,0 +1,9 @@ +-- +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=1467; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 1467, 2135, 0, 0, 9, 0, 836, 0, 0, 1, 0, 0, '', 'Show gossip text if player has not completed Rescue OOX-09/HL!'), -- AND +(14, 1467, 2135, 0, 0, 9, 0, 648, 0, 0, 1, 0, 0, '', 'Show gossip text if player has not completed Rescue OOX-09/TN!'), -- AND +(14, 1467, 2135, 0, 0, 9, 0, 2767, 0, 0, 1, 0, 0, '', 'Show gossip text if player has not completed Rescue OOX-09/FE!'), -- AND +(14, 1467, 2136, 0, 0, 9, 0, 836, 0, 0, 0, 0, 0, '', 'Show gossip text if player has completed Rescue OOX-09/HL!'), -- OR +(14, 1467, 2136, 0, 1, 9, 0, 648, 0, 0, 0, 0, 0, '', 'Show gossip text if player has completed Rescue OOX-09/TN!'), -- OR +(14, 1467, 2136, 0, 2, 9, 0, 2767, 0, 0, 0, 0, 0, '', 'Show gossip text if player has completed Rescue OOX-09/FE!'); -- OR diff --git a/sql/updates/world/2014_07_21_07_world_misc.sql b/sql/updates/world/2014_07_21_07_world_misc.sql new file mode 100644 index 00000000000..7150a21e1ce --- /dev/null +++ b/sql/updates/world/2014_07_21_07_world_misc.sql @@ -0,0 +1,21 @@ +DELETE FROM `smart_scripts` WHERE `entryorguid`=5697 AND `source_type`=0 AND `id` IN(14,15); +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 +(5697, 0, 14, 0, 61, 0, 100, 0, 0, 0, 0, 0, 90, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Theresa - On Reached WP18 - Kneel'), +(5697, 0, 15, 0, 61, 0, 100, 0, 0, 0, 0, 0, 91, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Theresa - On Text Over - Stand'); + +UPDATE `smart_scripts` SET `link`=14 WHERE `entryorguid`=5697 AND `source_type`=0 AND `id`=9; +UPDATE `smart_scripts` SET `link`=15 WHERE `entryorguid`=5697 AND `source_type`=0 AND `id`=10; + +UPDATE `smart_scripts` SET `event_param3`=300000, `event_param4`=450000 WHERE `entryorguid`=5696 AND `source_type`=0 AND `id`=0; + +DELETE FROM `creature_text` WHERE `entry`=5700 AND `id`=16; +DELETE FROM `creature_text` WHERE `entry`=5696 AND `groupid`=2 AND `id`=4; +DELETE FROM `creature_text` WHERE `entry`=5698 AND `groupid`=0 AND `id` IN(6,7); + +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextID`) VALUES +(5700, 0, 16, 'Back to the drawing board.', 12, 33, 100, 1, 0, 0, 'Samantha Shackleton', 2044), +(5696, 2, 4, 'Isn''t she just the most amazing little creation?', 12, 33, 100, 1, 0, 0, 'Gerard Abernathy', 2001), +(5698, 0, 6, 'Very nice, Gerard. Next you will be breeding them.', 12, 33, 100, 1, 0, 0, 'Joanna Whitehall', 2022), +(5698, 0, 7, 'Your pet is wonderful, Gerard, but she needs a collar with a bell I think.', 12, 33, 100, 1, 0, 0, 'Joanna Whitehall', 2026); + +UPDATE `smart_scripts` SET `link`=0 WHERE `entryorguid`=23967 AND `source_type`=0 AND `id`=0 AND `link`=1; diff --git a/sql/updates/world/2014_07_21_08_world_misc.sql b/sql/updates/world/2014_07_21_08_world_misc.sql new file mode 100644 index 00000000000..08665638fc9 --- /dev/null +++ b/sql/updates/world/2014_07_21_08_world_misc.sql @@ -0,0 +1,6 @@ +-- +UPDATE `npc_trainer` SET `spellcost`=100 WHERE `spell`=688; +DELETE FROM `creature_queststarter` WHERE `quest` IN (1598,1599,1470,1485,8344); +DELETE FROM `creature_questender` WHERE `quest` IN (1598,1599,1470,1485,8344); +UPDATE `creature` SET `position_z`=118.247 WHERE `guid`=93289; +UPDATE `creature` SET `position_z`=120.9 WHERE `guid`=92879; diff --git a/sql/updates/world/2014_07_21_09_world_creature_template.sql b/sql/updates/world/2014_07_21_09_world_creature_template.sql new file mode 100644 index 00000000000..88770a3f3c4 --- /dev/null +++ b/sql/updates/world/2014_07_21_09_world_creature_template.sql @@ -0,0 +1,2 @@ +-- +UPDATE creature_template_addon SET `bytes2`=1 WHERE `entry` IN (19762, 19768, 19784); diff --git a/src/server/authserver/Realms/RealmList.cpp b/src/server/authserver/Realms/RealmList.cpp index fe1a43a34c6..bea775d9d83 100644 --- a/src/server/authserver/Realms/RealmList.cpp +++ b/src/server/authserver/Realms/RealmList.cpp @@ -16,6 +16,7 @@ * with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <boost/asio/ip/tcp.hpp> #include "Common.h" #include "RealmList.h" #include "BattlenetManager.h" diff --git a/src/server/game/Battlefield/BattlefieldMgr.h b/src/server/game/Battlefield/BattlefieldMgr.h index ca057367e5a..0fa4add13a8 100644 --- a/src/server/game/Battlefield/BattlefieldMgr.h +++ b/src/server/game/Battlefield/BattlefieldMgr.h @@ -32,7 +32,7 @@ class BattlefieldMgr static BattlefieldMgr instance; return &instance; } - + // create battlefield events void InitBattlefield(); diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp index 7c03776ccec..10ede74685c 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp @@ -103,12 +103,19 @@ bool BattlegroundSA::ResetObjs() for (uint8 i = 0; i < 6; i++) GateStatus[i] = BG_SA_GATE_OK; - AddCreature(BG_SA_NpcEntries[BG_SA_NPC_KANRETHAD], BG_SA_NPC_KANRETHAD, BG_SA_NpcSpawnlocs[BG_SA_NPC_KANRETHAD]); + if (!AddCreature(BG_SA_NpcEntries[BG_SA_NPC_KANRETHAD], BG_SA_NPC_KANRETHAD, BG_SA_NpcSpawnlocs[BG_SA_NPC_KANRETHAD])) + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn Kanrethad, aborted. Entry: %u", BG_SA_NpcEntries[BG_SA_NPC_KANRETHAD]); + return false; + } for (uint8 i = 0; i <= BG_SA_PORTAL_DEFFENDER_RED; i++) { if (!AddObject(i, BG_SA_ObjEntries[i], BG_SA_ObjSpawnlocs[i], 0, 0, 0, 0, RESPAWN_ONE_DAY)) - return false; + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn BG_SA_PORTAL_DEFFENDER_RED, Entry: %u", BG_SA_ObjEntries[i]); + continue; + } } for (uint8 i = BG_SA_BOAT_ONE; i <= BG_SA_BOAT_TWO; i++) @@ -129,13 +136,19 @@ bool BattlegroundSA::ResetObjs() BG_SA_ObjSpawnlocs[i].GetPositionY(), BG_SA_ObjSpawnlocs[i].GetPositionZ() + (Attackers ? -3.750f: 0), BG_SA_ObjSpawnlocs[i].GetOrientation(), 0, 0, 0, 0, RESPAWN_ONE_DAY)) - return false; + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn one of the BG_SA_BOAT, Entry: %u", boatid); + continue; + } } for (uint8 i = BG_SA_SIGIL_1; i <= BG_SA_LEFT_FLAGPOLE; i++) { if (!AddObject(i, BG_SA_ObjEntries[i], BG_SA_ObjSpawnlocs[i], 0, 0, 0, 0, RESPAWN_ONE_DAY)) - return false; + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn Sigil, Entry: %u", BG_SA_ObjEntries[i]); + continue; + } } // MAD props for Kiper for discovering those values - 4 hours of his work. @@ -149,7 +162,10 @@ bool BattlegroundSA::ResetObjs() for (uint8 i = 0; i < BG_SA_DEMOLISHER_5; i++) { if (!AddCreature(BG_SA_NpcEntries[i], i, BG_SA_NpcSpawnlocs[i], Attackers == TEAM_ALLIANCE ? TEAM_HORDE : TEAM_ALLIANCE, 600)) - return false; + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn Cannon or demolisher, Entry: %u, Attackers: %s", BG_SA_NpcEntries[i], Attackers == TEAM_ALLIANCE ? "Horde(1)" : "Alliance(0)"); + continue; + } } OverrideGunFaction(); @@ -198,13 +214,21 @@ bool BattlegroundSA::ResetObjs() //GY capture points for (uint8 i = BG_SA_CENTRAL_FLAG; i <= BG_SA_LEFT_FLAG; i++) { - AddObject(i, (BG_SA_ObjEntries[i] - (Attackers == TEAM_ALLIANCE ? 1 : 0)), BG_SA_ObjSpawnlocs[i], 0, 0, 0, 0, RESPAWN_ONE_DAY); + if (!AddObject(i, (BG_SA_ObjEntries[i] - (Attackers == TEAM_ALLIANCE ? 1 : 0)), BG_SA_ObjSpawnlocs[i], 0, 0, 0, 0, RESPAWN_ONE_DAY)) + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn Central Flag Entry: %u", BG_SA_ObjEntries[i] - (Attackers == TEAM_ALLIANCE ? 1 : 0)); + continue; + } GetBGObject(i)->SetFaction(atF); } for (uint8 i = BG_SA_BOMB; i < BG_SA_MAXOBJ; i++) { - AddObject(i, BG_SA_ObjEntries[BG_SA_BOMB], BG_SA_ObjSpawnlocs[i], 0, 0, 0, 0, RESPAWN_ONE_DAY); + if (!AddObject(i, BG_SA_ObjEntries[BG_SA_BOMB], BG_SA_ObjSpawnlocs[i], 0, 0, 0, 0, RESPAWN_ONE_DAY)) + { + TC_LOG_ERROR("bg.battleground", "SOTA: couldn't spawn SA Bomb Entry: %u", BG_SA_ObjEntries[BG_SA_BOMB] + i); + continue; + } GetBGObject(i)->SetFaction(atF); } diff --git a/src/server/game/Globals/ObjectAccessor.cpp b/src/server/game/Globals/ObjectAccessor.cpp index d2426effa8e..a464d0c57eb 100644 --- a/src/server/game/Globals/ObjectAccessor.cpp +++ b/src/server/game/Globals/ObjectAccessor.cpp @@ -218,7 +218,7 @@ Unit* ObjectAccessor::FindUnit(uint64 guid) Player* ObjectAccessor::FindPlayerByName(std::string const& name) { boost::shared_lock<boost::shared_mutex> lock(*HashMapHolder<Player>::GetLock()); - + std::string nameStr = name; std::transform(nameStr.begin(), nameStr.end(), nameStr.begin(), ::tolower); HashMapHolder<Player>::MapType const& m = GetPlayers(); diff --git a/src/server/game/Grids/Notifiers/GridNotifiers.h b/src/server/game/Grids/Notifiers/GridNotifiers.h index 48ae15285a9..d4b75b026f6 100644 --- a/src/server/game/Grids/Notifiers/GridNotifiers.h +++ b/src/server/game/Grids/Notifiers/GridNotifiers.h @@ -633,7 +633,7 @@ namespace Trinity if (go->GetGOInfo()->spellFocus.focusId != i_focusId) return false; - float dist = (float)((go->GetGOInfo()->spellFocus.dist)/2); + float dist = go->GetGOInfo()->spellFocus.dist / 2.f; return go->IsWithinDistInMap(i_unit, dist); } diff --git a/src/server/game/Instances/InstanceSaveMgr.h b/src/server/game/Instances/InstanceSaveMgr.h index 75dd8ef3f74..701776bb57d 100644 --- a/src/server/game/Instances/InstanceSaveMgr.h +++ b/src/server/game/Instances/InstanceSaveMgr.h @@ -80,10 +80,10 @@ class InstanceSave /* online players bound to the instance (perm/solo) does not include the members of the group unless they have permanent saves */ - void AddPlayer(Player* player) - { + void AddPlayer(Player* player) + { std::lock_guard<std::mutex> lock(_playerListLock); - m_playerList.push_back(player); + m_playerList.push_back(player); } bool RemovePlayer(Player* player) diff --git a/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp index 89cb5745267..aee8c497247 100755 --- a/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp @@ -166,7 +166,10 @@ bool WaypointMovementGenerator<Creature>::StartMove(Creature* creature) //Call for creature group update if (creature->GetFormation() && creature->GetFormation()->getLeader() == creature) + { + creature->SetWalk(!node->run); creature->GetFormation()->LeaderMoveTo(formationDest.x, formationDest.y, formationDest.z); + } return true; } diff --git a/src/server/game/Movement/Spline/MovementTypedefs.h b/src/server/game/Movement/Spline/MovementTypedefs.h index 57958f604d2..134e7a45425 100644 --- a/src/server/game/Movement/Spline/MovementTypedefs.h +++ b/src/server/game/Movement/Spline/MovementTypedefs.h @@ -23,14 +23,12 @@ namespace G3D { - class Vector2; class Vector3; class Vector4; } namespace Movement { - using G3D::Vector2; using G3D::Vector3; using G3D::Vector4; diff --git a/src/server/game/Scripting/ScriptLoader.cpp b/src/server/game/Scripting/ScriptLoader.cpp index 6c77daa19d2..c9b65c3a046 100644 --- a/src/server/game/Scripting/ScriptLoader.cpp +++ b/src/server/game/Scripting/ScriptLoader.cpp @@ -269,7 +269,6 @@ void AddSC_eastern_plaguelands(); void AddSC_eversong_woods(); void AddSC_ghostlands(); void AddSC_hinterlands(); -void AddSC_ironforge(); void AddSC_isle_of_queldanas(); void AddSC_loch_modan(); void AddSC_redridge_mountains(); @@ -280,7 +279,6 @@ void AddSC_swamp_of_sorrows(); void AddSC_tirisfal_glades(); void AddSC_undercity(); void AddSC_western_plaguelands(); -void AddSC_westfall(); void AddSC_wetlands(); //kalimdor @@ -992,7 +990,6 @@ void AddEasternKingdomsScripts() AddSC_eversong_woods(); AddSC_ghostlands(); AddSC_hinterlands(); - AddSC_ironforge(); AddSC_isle_of_queldanas(); AddSC_loch_modan(); AddSC_redridge_mountains(); @@ -1003,7 +1000,6 @@ void AddEasternKingdomsScripts() AddSC_tirisfal_glades(); AddSC_undercity(); AddSC_western_plaguelands(); - AddSC_westfall(); AddSC_wetlands(); #endif } diff --git a/src/server/scripts/EasternKingdoms/CMakeLists.txt b/src/server/scripts/EasternKingdoms/CMakeLists.txt index 1e0e05840c4..118d2498727 100644 --- a/src/server/scripts/EasternKingdoms/CMakeLists.txt +++ b/src/server/scripts/EasternKingdoms/CMakeLists.txt @@ -106,7 +106,6 @@ set(scripts_STAT_SRCS EasternKingdoms/Gnomeregan/gnomeregan.cpp EasternKingdoms/Gnomeregan/gnomeregan.h EasternKingdoms/zone_redridge_mountains.cpp - EasternKingdoms/zone_ironforge.cpp EasternKingdoms/ScarletEnclave/chapter2.cpp EasternKingdoms/ScarletEnclave/chapter5.cpp EasternKingdoms/ScarletEnclave/chapter1.cpp @@ -189,8 +188,6 @@ set(scripts_STAT_SRCS EasternKingdoms/ZulAman/zulaman.h EasternKingdoms/zone_hinterlands.cpp EasternKingdoms/zone_western_plaguelands.cpp - EasternKingdoms/zone_alterac_mountains.cpp - EasternKingdoms/zone_westfall.cpp EasternKingdoms/zone_silverpine_forest.cpp EasternKingdoms/Karazhan/instance_karazhan.cpp EasternKingdoms/Karazhan/boss_nightbane.cpp diff --git a/src/server/scripts/EasternKingdoms/zone_alterac_mountains.cpp b/src/server/scripts/EasternKingdoms/zone_alterac_mountains.cpp deleted file mode 100644 index 3df4fddf69f..00000000000 --- a/src/server/scripts/EasternKingdoms/zone_alterac_mountains.cpp +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (C) 2008-2014 TrinityCore <http://www.trinitycore.org/> - * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see <http://www.gnu.org/licenses/>. - */ - -/* ScriptData -SDName: Alterac_Mountains -SD%Complete: 0 -SDComment: Placeholder -SDCategory: Alterac Mountains -EndScriptData */ - -/* ContentData -EndContentData */ - -#include "ScriptMgr.h" -#include "ScriptedCreature.h" - -/*void AddSC_alterac_mountains() -{ - Script* newscript; -}*/ diff --git a/src/server/scripts/EasternKingdoms/zone_westfall.cpp b/src/server/scripts/EasternKingdoms/zone_westfall.cpp deleted file mode 100644 index 7f0fbd8f97b..00000000000 --- a/src/server/scripts/EasternKingdoms/zone_westfall.cpp +++ /dev/null @@ -1,207 +0,0 @@ -/* - * Copyright (C) 2008-2014 TrinityCore <http://www.trinitycore.org/> - * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see <http://www.gnu.org/licenses/>. - */ - -/* ScriptData -SDName: Westfall -SD%Complete: 90 -SDComment: Quest support: 1651 -SDCategory: Westfall -EndScriptData */ - -/* ContentData -npc_daphne_stilwell -EndContentData */ - -#include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "ScriptedEscortAI.h" -#include "Player.h" - -/*###### -## npc_daphne_stilwell -######*/ - -enum DaphneStilwell -{ - // Yells - SAY_DS_START = 0, - SAY_DS_DOWN_1 = 1, - SAY_DS_DOWN_2 = 2, - SAY_DS_DOWN_3 = 3, - SAY_DS_PROLOGUE = 4, - - // Spells - SPELL_SHOOT = 6660, - - // Quests - QUEST_TOME_VALOR = 1651, - - // Creatures - NPC_DEFIAS_RAIDER = 6180, - - // Equips - EQUIP_ID_RIFLE = 2511 -}; - -class npc_daphne_stilwell : public CreatureScript -{ -public: - npc_daphne_stilwell() : CreatureScript("npc_daphne_stilwell") { } - - bool OnQuestAccept(Player* player, Creature* creature, const Quest* quest) override - { - if (quest->GetQuestId() == QUEST_TOME_VALOR) - { - creature->AI()->Talk(SAY_DS_START); - - if (npc_escortAI* pEscortAI = CAST_AI(npc_daphne_stilwell::npc_daphne_stilwellAI, creature->AI())) - pEscortAI->Start(true, true, player->GetGUID()); - } - - return true; - } - - CreatureAI* GetAI(Creature* creature) const override - { - return new npc_daphne_stilwellAI(creature); - } - - struct npc_daphne_stilwellAI : public npc_escortAI - { - npc_daphne_stilwellAI(Creature* creature) : npc_escortAI(creature) { } - - uint32 uiWPHolder; - uint32 uiShootTimer; - - void Reset() override - { - if (HasEscortState(STATE_ESCORT_ESCORTING)) - { - switch (uiWPHolder) - { - case 7: - Talk(SAY_DS_DOWN_1); - break; - case 8: - Talk(SAY_DS_DOWN_2); - break; - case 9: - Talk(SAY_DS_DOWN_3); - break; - } - } - else - uiWPHolder = 0; - - uiShootTimer = 0; - } - - void WaypointReached(uint32 waypointId) override - { - Player* player = GetPlayerForEscort(); - if (!player) - return; - - uiWPHolder = waypointId; - - switch (waypointId) - { - case 4: - SetEquipmentSlots(false, EQUIP_NO_CHANGE, EQUIP_NO_CHANGE, EQUIP_ID_RIFLE); - me->SetSheath(SHEATH_STATE_RANGED); - me->HandleEmoteCommand(EMOTE_STATE_USE_STANDING_NO_SHEATHE); - break; - case 7: - me->SummonCreature(NPC_DEFIAS_RAIDER, -11450.836f, 1569.755f, 54.267f, 4.230f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11449.697f, 1569.124f, 54.421f, 4.206f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11448.237f, 1568.307f, 54.620f, 4.206f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - break; - case 8: - me->SetSheath(SHEATH_STATE_RANGED); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11450.836f, 1569.755f, 54.267f, 4.230f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11449.697f, 1569.124f, 54.421f, 4.206f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11448.237f, 1568.307f, 54.620f, 4.206f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11448.037f, 1570.213f, 54.961f, 4.283f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - break; - case 9: - me->SetSheath(SHEATH_STATE_RANGED); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11450.836f, 1569.755f, 54.267f, 4.230f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11449.697f, 1569.124f, 54.421f, 4.206f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11448.237f, 1568.307f, 54.620f, 4.206f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11448.037f, 1570.213f, 54.961f, 4.283f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - me->SummonCreature(NPC_DEFIAS_RAIDER, -11449.018f, 1570.738f, 54.828f, 4.220f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000); - break; - case 10: - SetRun(false); - break; - case 11: - Talk(SAY_DS_PROLOGUE); - break; - case 13: - SetEquipmentSlots(true); - me->SetSheath(SHEATH_STATE_UNARMED); - me->HandleEmoteCommand(EMOTE_STATE_USE_STANDING_NO_SHEATHE); - break; - case 17: - player->GroupEventHappens(QUEST_TOME_VALOR, me); - break; - } - } - - void AttackStart(Unit* who) override - { - if (!who) - return; - - if (me->Attack(who, false)) - { - me->AddThreat(who, 0.0f); - me->SetInCombatWith(who); - who->SetInCombatWith(me); - - me->GetMotionMaster()->MoveChase(who, 30.0f); - } - } - - void JustSummoned(Creature* summoned) override - { - summoned->AI()->AttackStart(me); - } - - void Update(const uint32 diff) - { - npc_escortAI::UpdateAI(diff); - - if (!UpdateVictim()) - return; - - if (uiShootTimer <= diff) - { - uiShootTimer = 1500; - - if (!me->IsWithinDist(me->GetVictim(), ATTACK_DISTANCE)) - DoCastVictim(SPELL_SHOOT); - } else uiShootTimer -= diff; - } - }; -}; - -void AddSC_westfall() -{ - new npc_daphne_stilwell(); -} diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp index 4e45d72cadf..90d91199e7a 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp @@ -20,6 +20,7 @@ #include "ScriptedCreature.h" #include "SpellAuras.h" #include "icecrown_citadel.h" +#include "Player.h" enum ScriptTexts { @@ -457,11 +458,39 @@ class spell_festergut_blighted_spores : public SpellScriptLoader if (InstanceScript* instance = GetTarget()->GetInstanceScript()) if (Creature* festergut = ObjectAccessor::GetCreature(*GetTarget(), instance->GetData64(DATA_FESTERGUT))) festergut->AI()->SetData(DATA_INOCULATED_STACK, GetStackAmount()); + + HandleResidue(); + } + + void HandleResidue() + { + Player* target = GetUnitOwner()->ToPlayer(); + if (!target) + return; + + if (target->HasAura(SPELL_ORANGE_BLIGHT_RESIDUE)) + return; + + if (target->GetMap() && !target->GetMap()->Is25ManRaid()) + { + if (target->GetQuestStatus(QUEST_RESIDUE_RENDEZVOUS_10) != QUEST_STATUS_INCOMPLETE) + return; + + target->CastSpell(target, SPELL_ORANGE_BLIGHT_RESIDUE, TRIGGERED_FULL_MASK); + } + + if (target->GetMap() && target->GetMap()->Is25ManRaid()) + { + if (target->GetQuestStatus(QUEST_RESIDUE_RENDEZVOUS_25) != QUEST_STATUS_INCOMPLETE) + return; + + target->CastSpell(target, SPELL_ORANGE_BLIGHT_RESIDUE, TRIGGERED_FULL_MASK); + } } void Register() override { - AfterEffectApply += AuraEffectApplyFn(spell_festergut_blighted_spores_AuraScript::ExtraEffect, EFFECT_0, SPELL_AURA_PERIODIC_DAMAGE, AURA_EFFECT_HANDLE_REAL_OR_REAPPLY_MASK); + OnEffectRemove += AuraEffectApplyFn(spell_festergut_blighted_spores_AuraScript::ExtraEffect, EFFECT_0, SPELL_AURA_PERIODIC_DAMAGE, AURA_EFFECT_HANDLE_REAL_OR_REAPPLY_MASK); } }; diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp index c1ee616218c..2f2889a9cf3 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp @@ -862,6 +862,53 @@ class spell_rotface_vile_gas_trigger : public SpellScriptLoader } }; +class spell_rotface_slime_spray : public SpellScriptLoader +{ + public: + spell_rotface_slime_spray() : SpellScriptLoader("spell_rotface_slime_spray") { } + + class spell_rotface_slime_spray_SpellScript : public SpellScript + { + PrepareSpellScript(spell_rotface_slime_spray_SpellScript); + + void HandleResidue() + { + Player* target = GetHitPlayer(); + if (!target) + return; + + if (target->HasAura(SPELL_GREEN_BLIGHT_RESIDUE)) + return; + + if (target->GetMap() && !target->GetMap()->Is25ManRaid()) + { + if (target->GetQuestStatus(QUEST_RESIDUE_RENDEZVOUS_10) != QUEST_STATUS_INCOMPLETE) + return; + + target->CastSpell(target, SPELL_GREEN_BLIGHT_RESIDUE, TRIGGERED_FULL_MASK); + } + + if (target->GetMap() && target->GetMap()->Is25ManRaid()) + { + if (target->GetQuestStatus(QUEST_RESIDUE_RENDEZVOUS_25) != QUEST_STATUS_INCOMPLETE) + return; + + target->CastSpell(target, SPELL_GREEN_BLIGHT_RESIDUE, TRIGGERED_FULL_MASK); + } + } + + void Register() override + { + OnHit += SpellHitFn(spell_rotface_slime_spray_SpellScript::HandleResidue); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_rotface_slime_spray_SpellScript(); + } +}; + void AddSC_boss_rotface() { new boss_rotface(); @@ -877,4 +924,5 @@ void AddSC_boss_rotface() new spell_rotface_unstable_ooze_explosion(); new spell_rotface_unstable_ooze_explosion_suicide(); new spell_rotface_vile_gas_trigger(); + new spell_rotface_slime_spray(); } diff --git a/src/server/shared/Configuration/Config.cpp b/src/server/shared/Configuration/Config.cpp index 5cd7ef52f82..ecebf30182e 100644 --- a/src/server/shared/Configuration/Config.cpp +++ b/src/server/shared/Configuration/Config.cpp @@ -103,6 +103,6 @@ std::list<std::string> ConfigMgr::GetKeysByString(std::string const& name) for (const ptree::value_type& child : _config) if (child.first.compare(0, name.length(), name) == 0) keys.push_back(child.first); - + return keys; } diff --git a/src/server/shared/Database/DatabaseWorkerPool.h b/src/server/shared/Database/DatabaseWorkerPool.h index f0b540022da..a1ee6407fea 100644 --- a/src/server/shared/Database/DatabaseWorkerPool.h +++ b/src/server/shared/Database/DatabaseWorkerPool.h @@ -59,6 +59,11 @@ class DatabaseWorkerPool ~DatabaseWorkerPool() { + _queue->Cancel(); + + delete _queue; + + delete _connectionInfo; } bool Open(const std::string& infoString, uint8 async_threads, uint8 synch_threads) @@ -122,12 +127,7 @@ class DatabaseWorkerPool for (uint8 i = 0; i < _connectionCount[IDX_SYNCH]; ++i) _connections[IDX_SYNCH][i]->Close(); - delete _queue; - TC_LOG_INFO("sql.driver", "All connections on DatabasePool '%s' closed.", GetDatabaseName()); - - delete _connectionInfo; - _connectionInfo = NULL; } /** diff --git a/src/server/shared/Database/PreparedStatement.cpp b/src/server/shared/Database/PreparedStatement.cpp index fb1bfa687d0..23c50ac2ef8 100644 --- a/src/server/shared/Database/PreparedStatement.cpp +++ b/src/server/shared/Database/PreparedStatement.cpp @@ -446,8 +446,8 @@ std::string MySQLPreparedStatement::getQueryString(std::string const& sqlPattern //- Execution PreparedStatementTask::PreparedStatementTask(PreparedStatement* stmt, bool async) : -m_stmt(stmt) -{ +m_stmt(stmt), m_result(nullptr) +{ m_has_result = async; // If it's async, then there's a result if (async) m_result = new PreparedQueryResultPromise(); diff --git a/src/server/shared/Logging/Log.cpp b/src/server/shared/Logging/Log.cpp index 65cf930a634..a7b6b418cc4 100644 --- a/src/server/shared/Logging/Log.cpp +++ b/src/server/shared/Logging/Log.cpp @@ -278,7 +278,7 @@ void Log::write(LogMessage* msg) const auto logOperation = std::shared_ptr<LogOperation>(new LogOperation(logger, msg)); _ioService->post(_strand->wrap([logOperation](){ logOperation->call(); })); - + } else { diff --git a/src/server/shared/Logging/Log.h b/src/server/shared/Logging/Log.h index 8ae8db5bf5f..78e7e012bbe 100644 --- a/src/server/shared/Logging/Log.h +++ b/src/server/shared/Logging/Log.h @@ -50,7 +50,7 @@ class Log instance._ioService = ioService; instance._strand = new boost::asio::strand(*ioService); } - + return &instance; } diff --git a/src/server/shared/Threading/ProducerConsumerQueue.h b/src/server/shared/Threading/ProducerConsumerQueue.h index 3fefd27ba6e..98a0188b6b5 100644 --- a/src/server/shared/Threading/ProducerConsumerQueue.h +++ b/src/server/shared/Threading/ProducerConsumerQueue.h @@ -76,7 +76,7 @@ public: { _condition.wait(lock); } - + if (_queue.empty()) return; @@ -106,6 +106,6 @@ public: } }; -#endif +#endif diff --git a/src/server/shared/Utilities/ServiceWin32.cpp b/src/server/shared/Utilities/ServiceWin32.cpp index f4a0339d9e6..ecf403423f7 100644 --- a/src/server/shared/Utilities/ServiceWin32.cpp +++ b/src/server/shared/Utilities/ServiceWin32.cpp @@ -24,11 +24,6 @@ #include <windows.h> #include <winsvc.h> -// stupid ACE define -#ifdef main -#undef main -#endif //main - #if !defined(WINADVAPI) #if !defined(_ADVAPI32_) #define WINADVAPI DECLSPEC_IMPORT diff --git a/src/server/worldserver/worldserver.conf.dist b/src/server/worldserver/worldserver.conf.dist index a048a7d3a80..e482e3d4c37 100644 --- a/src/server/worldserver/worldserver.conf.dist +++ b/src/server/worldserver/worldserver.conf.dist @@ -146,7 +146,7 @@ BindIP = "0.0.0.0" # # ThreadPool -# Description: Number of threads to be used for the global thread pool +# Description: Number of threads to be used for the global thread pool # The thread pool is currently used for the signal handler and remote access # Default: 1 @@ -170,7 +170,7 @@ UseProcessors = 0 # # ProcessPriority # Description: Process priority setting for Windows and Linux based systems. -# Details: On Linux, a nice value of -15 is used. (requires superuser). +# Details: On Linux, a nice value of -15 is used. (requires superuser). # On Windows, process is set to HIGH class. # Default: 0 - (Normal) # 1 - (High) @@ -1052,7 +1052,7 @@ Account.PasswordChangeSecurity = 0 # # BirthdayTime -# Description: Set to date of project's birth in UNIX time. By default the date when +# Description: Set to date of project's birth in UNIX time. By default the date when # TrinityCore was started (Thu Oct 2, 2008) # Default: 1222964635 # @@ -2605,9 +2605,9 @@ UI.ShowQuestLevelsInDialogs = 0 # 1 - Prefix Timestamp to the text # 2 - Prefix Log Level to the text # 4 - Prefix Log Filter type to the text -# 8 - Append timestamp to the log file name. Format: YYYY-MM-DD_HH-MM-SS +# 8 - Append timestamp to the log file name. Format: YYYY-MM-DD_HH-MM-SS # (Only used with Type = 2) -# 16 - Make a backup of existing file before overwrite +# 16 - Make a backup of existing file before overwrite # (Only used with Mode = w) # # Colors (read as optional1 if Type = Console) @@ -2724,7 +2724,7 @@ Log.Async.Enable = 0 # # Allow.IP.Based.Action.Logging -# Description: Logs actions, e.g. account login and logout to name a few, based on IP of +# Description: Logs actions, e.g. account login and logout to name a few, based on IP of # current session. # Default: 0 - (Disabled) # 1 - (Enabled) diff --git a/src/tools/mmaps_generator/MapBuilder.h b/src/tools/mmaps_generator/MapBuilder.h index 944d03968b5..1d688ccfa77 100644 --- a/src/tools/mmaps_generator/MapBuilder.h +++ b/src/tools/mmaps_generator/MapBuilder.h @@ -35,8 +35,6 @@ using namespace VMAP; -// G3D namespace typedefs conflicts with ACE typedefs - namespace MMAP { struct MapTiles |