aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmake/compiler/clang/settings.cmake2
-rw-r--r--cmake/macros/FindPCHSupport.cmake71
-rw-r--r--revision_data.h.in.cmake4
-rw-r--r--sql/updates/world/2016_02_22_00_world.sql2
-rw-r--r--sql/updates/world/2016_02_22_01_world.sql26
-rw-r--r--sql/updates/world/2016_02_22_02_world.sql34
-rw-r--r--sql/updates/world/2016_02_23_00_world.sql1
-rw-r--r--sql/updates/world/2016_02_23_01_world.sql119
-rw-r--r--sql/updates/world/2016_02_23_02_world.sql6
-rw-r--r--src/common/Configuration/BuiltInConfig.cpp52
-rw-r--r--src/common/Configuration/BuiltInConfig.h42
-rw-r--r--src/common/Configuration/Config.cpp8
-rw-r--r--src/common/Configuration/Config.h8
-rw-r--r--src/common/GitRevision.cpp20
-rw-r--r--src/common/GitRevision.h4
-rw-r--r--src/common/Threading/MPSCQueue.h83
-rw-r--r--src/server/authserver/CMakeLists.txt4
-rw-r--r--src/server/authserver/Server/AuthSession.cpp5
-rw-r--r--src/server/authserver/Server/AuthSocketMgr.h15
-rw-r--r--src/server/authserver/authserver.conf.dist40
-rw-r--r--src/server/database/Updater/DBUpdater.cpp33
-rw-r--r--src/server/database/Updater/DBUpdater.h4
-rw-r--r--src/server/database/Updater/UpdateFetcher.cpp37
-rw-r--r--src/server/database/Updater/UpdateFetcher.h8
-rw-r--r--src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp2
-rw-r--r--src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp2
-rw-r--r--src/server/game/AI/SmartScripts/SmartAI.cpp3
-rw-r--r--src/server/game/Achievements/AchievementMgr.cpp122
-rw-r--r--src/server/game/Battlefield/Battlefield.cpp16
-rw-r--r--src/server/game/Battlegrounds/BattlegroundMgr.cpp16
-rw-r--r--src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp22
-rw-r--r--src/server/game/Chat/Chat.cpp14
-rw-r--r--src/server/game/Entities/Corpse/Corpse.cpp2
-rw-r--r--src/server/game/Entities/Item/Item.cpp3
-rw-r--r--src/server/game/Entities/Player/Player.cpp228
-rw-r--r--src/server/game/Entities/Unit/Unit.cpp2
-rw-r--r--src/server/game/Events/GameEventMgr.cpp100
-rw-r--r--src/server/game/Handlers/MailHandler.cpp6
-rw-r--r--src/server/game/Mails/Mail.cpp4
-rw-r--r--src/server/game/Movement/MotionMaster.cpp52
-rw-r--r--src/server/game/Scripting/ScriptLoader.cpp1396
-rw-r--r--src/server/game/Scripting/ScriptLoader.h12
-rw-r--r--src/server/game/Server/WorldSocket.cpp98
-rw-r--r--src/server/game/Server/WorldSocket.h4
-rw-r--r--src/server/game/Server/WorldSocketMgr.cpp12
-rw-r--r--src/server/game/Server/WorldSocketMgr.h2
-rw-r--r--src/server/game/Skills/SkillDiscovery.cpp16
-rw-r--r--src/server/game/Skills/SkillExtraItems.cpp18
-rw-r--r--src/server/game/Spells/SpellEffects.cpp34
-rw-r--r--src/server/game/Spells/SpellMgr.cpp156
-rw-r--r--src/server/game/Weather/Weather.cpp2
-rw-r--r--src/server/scripts/CMakeLists.txt32
-rw-r--r--src/server/scripts/Commands/CMakeLists.txt18
-rw-r--r--src/server/scripts/Commands/cs_character.cpp12
-rw-r--r--src/server/scripts/Commands/cs_script_loader.cpp104
-rw-r--r--src/server/scripts/Commands/cs_send.cpp10
-rw-r--r--src/server/scripts/Commands/cs_titles.cpp2
-rw-r--r--src/server/scripts/Custom/CMakeLists.txt18
-rw-r--r--src/server/scripts/Custom/custom_script_loader.cpp25
-rw-r--r--src/server/scripts/EasternKingdoms/CMakeLists.txt204
-rw-r--r--src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp372
-rw-r--r--src/server/scripts/Events/CMakeLists.txt18
-rw-r--r--src/server/scripts/Events/events_script_loader.cpp26
-rw-r--r--src/server/scripts/Kalimdor/CMakeLists.txt121
-rw-r--r--src/server/scripts/Kalimdor/kalimdor_script_loader.cpp206
-rw-r--r--src/server/scripts/Northrend/CMakeLists.txt199
-rw-r--r--src/server/scripts/Northrend/northrend_script_loader.cpp374
-rw-r--r--src/server/scripts/OutdoorPvP/CMakeLists.txt27
-rw-r--r--src/server/scripts/OutdoorPvP/OutdoorPvPScriptLoader.cpp36
-rw-r--r--src/server/scripts/Outland/CMakeLists.txt128
-rw-r--r--src/server/scripts/Outland/outland_script_loader.cpp256
-rw-r--r--src/server/scripts/Outland/zone_terokkar_forest.cpp61
-rw-r--r--src/server/scripts/Pet/CMakeLists.txt21
-rw-r--r--src/server/scripts/Pet/pet_script_loader.cpp36
-rw-r--r--src/server/scripts/Spells/CMakeLists.txt30
-rw-r--r--src/server/scripts/Spells/spell_script_loader.cpp52
-rw-r--r--src/server/scripts/World/CMakeLists.txt18
-rw-r--r--src/server/scripts/World/world_script_loader.cpp59
-rw-r--r--src/server/shared/Networking/AsyncAcceptor.h40
-rw-r--r--src/server/shared/Networking/MessageBuffer.h2
-rw-r--r--src/server/shared/Networking/NetworkThread.h84
-rw-r--r--src/server/shared/Networking/Socket.h74
-rw-r--r--src/server/shared/Networking/SocketMgr.h37
-rw-r--r--src/server/worldserver/CMakeLists.txt4
-rw-r--r--src/server/worldserver/worldserver.conf.dist59
-rw-r--r--src/tools/mmaps_generator/MapBuilder.cpp4
86 files changed, 2733 insertions, 3008 deletions
diff --git a/cmake/compiler/clang/settings.cmake b/cmake/compiler/clang/settings.cmake
index 4dad4cb7820..261a55b285f 100644
--- a/cmake/compiler/clang/settings.cmake
+++ b/cmake/compiler/clang/settings.cmake
@@ -1,5 +1,5 @@
# Set build-directive (used in core to tell which buildtype we used)
-add_definitions(-D_BUILD_DIRECTIVE='"$(CONFIGURATION)"')
+add_definitions(-D_BUILD_DIRECTIVE='"${CMAKE_BUILD_TYPE}"')
if(WITH_WARNINGS)
set(WARNING_FLAGS "-W -Wall -Wextra -Winit-self -Wfatal-errors -Wno-mismatched-tags")
diff --git a/cmake/macros/FindPCHSupport.cmake b/cmake/macros/FindPCHSupport.cmake
index b068b69c26b..49d4be904d1 100644
--- a/cmake/macros/FindPCHSupport.cmake
+++ b/cmake/macros/FindPCHSupport.cmake
@@ -11,7 +11,7 @@ FUNCTION(GET_COMMON_PCH_PARAMS PCH_HEADER PCH_FE INCLUDE_PREFIX)
SET(INCLUDE_FLAGS ${INCLUDE_FLAGS_LIST} PARENT_SCOPE)
ENDFUNCTION(GET_COMMON_PCH_PARAMS)
-FUNCTION(GENERATE_CXX_PCH_COMMAND TARGET_NAME INCLUDE_FLAGS IN PCH_SRC OUT)
+FUNCTION(GENERATE_CXX_PCH_COMMAND TARGET_NAME_LIST INCLUDE_FLAGS IN PCH_SRC OUT)
IF (CMAKE_BUILD_TYPE)
STRING(TOUPPER _${CMAKE_BUILD_TYPE} CURRENT_BUILD_TYPE)
ENDIF ()
@@ -55,50 +55,69 @@ FUNCTION(GENERATE_CXX_PCH_COMMAND TARGET_NAME INCLUDE_FLAGS IN PCH_SRC OUT)
DEPENDS ${OUT}
)
- ADD_DEPENDENCIES(${TARGET_NAME} generate_${PCH_SRC_N})
+ FOREACH(TARGET_NAME ${TARGET_NAME_LIST})
+ ADD_DEPENDENCIES(${TARGET_NAME} generate_${PCH_SRC_N})
+ ENDFOREACH()
+
ENDFUNCTION(GENERATE_CXX_PCH_COMMAND)
-FUNCTION(ADD_CXX_PCH_GCC TARGET_NAME PCH_HEADER PCH_SOURCE)
+FUNCTION(ADD_CXX_PCH_GCC TARGET_NAME_LIST PCH_HEADER PCH_SOURCE)
GET_COMMON_PCH_PARAMS(${PCH_HEADER} "gch" "-I")
- GENERATE_CXX_PCH_COMMAND(${TARGET_NAME} "${INCLUDE_FLAGS}" ${PCH_HEADER} ${PCH_SOURCE} ${PCH_HEADER_OUT})
- SET_TARGET_PROPERTIES(
- ${TARGET_NAME} PROPERTIES
- COMPILE_FLAGS "-include ${CMAKE_CURRENT_BINARY_DIR}/${PCH_HEADER_NAME}"
- )
+ GENERATE_CXX_PCH_COMMAND("${TARGET_NAME_LIST}" "${INCLUDE_FLAGS}" ${PCH_HEADER} ${PCH_SOURCE} ${PCH_HEADER_OUT})
+
+ FOREACH(TARGET_NAME ${TARGET_NAME_LIST})
+ SET_TARGET_PROPERTIES(
+ ${TARGET_NAME} PROPERTIES
+ COMPILE_FLAGS "-include ${CMAKE_CURRENT_BINARY_DIR}/${PCH_HEADER_NAME}"
+ )
+ ENDFOREACH()
ENDFUNCTION(ADD_CXX_PCH_GCC)
-FUNCTION(ADD_CXX_PCH_CLANG TARGET_NAME PCH_HEADER PCH_SOURCE)
+FUNCTION(ADD_CXX_PCH_CLANG TARGET_NAME_LIST PCH_HEADER PCH_SOURCE)
GET_COMMON_PCH_PARAMS(${PCH_HEADER} "pch" "-I")
- GENERATE_CXX_PCH_COMMAND(${TARGET_NAME} "${INCLUDE_FLAGS}" ${PCH_HEADER} ${PCH_SOURCE} ${PCH_HEADER_OUT})
- SET_TARGET_PROPERTIES(
- ${TARGET_NAME} PROPERTIES
- COMPILE_FLAGS "-include-pch ${PCH_HEADER_OUT}"
- )
+ GENERATE_CXX_PCH_COMMAND("${TARGET_NAME_LIST}" "${INCLUDE_FLAGS}" ${PCH_HEADER} ${PCH_SOURCE} ${PCH_HEADER_OUT})
+
+ FOREACH(TARGET_NAME ${TARGET_NAME_LIST})
+ SET_TARGET_PROPERTIES(
+ ${TARGET_NAME} PROPERTIES
+ COMPILE_FLAGS "-include-pch ${PCH_HEADER_OUT}"
+ )
+ ENDFOREACH()
ENDFUNCTION(ADD_CXX_PCH_CLANG)
-FUNCTION(ADD_CXX_PCH_MSVC TARGET_NAME PCH_HEADER PCH_SOURCE)
+FUNCTION(ADD_CXX_PCH_MSVC TARGET_NAME_LIST PCH_HEADER PCH_SOURCE)
GET_COMMON_PCH_PARAMS(${PCH_HEADER} "pch" "/I")
- SET_TARGET_PROPERTIES(
- ${TARGET_NAME} PROPERTIES
- COMPILE_FLAGS "/FI${PCH_HEADER_NAME} /Yu${PCH_HEADER_NAME}"
- )
+
+ FOREACH(TARGET_NAME ${TARGET_NAME_LIST})
+ SET_TARGET_PROPERTIES(
+ ${TARGET_NAME} PROPERTIES
+ COMPILE_FLAGS "/FI${PCH_HEADER_NAME} /Yu${PCH_HEADER_NAME}"
+ )
+ ENDFOREACH()
+
SET_SOURCE_FILES_PROPERTIES(
${PCH_SOURCE} PROPERTIES
COMPILE_FLAGS "/Yc${PCH_HEADER_NAME}"
)
ENDFUNCTION(ADD_CXX_PCH_MSVC)
-FUNCTION(ADD_CXX_PCH TARGET_NAME PCH_HEADER PCH_SOURCE)
- IF (MSVC)
- ADD_CXX_PCH_MSVC(${TARGET_NAME} ${PCH_HEADER} ${PCH_SOURCE})
- ELSEIF ("${CMAKE_GENERATOR}" MATCHES "Xcode")
- SET_TARGET_PROPERTIES(${TARGET_NAME} PROPERTIES
+FUNCTION(ADD_CXX_PCH_XCODE TARGET_NAME_LIST PCH_HEADER PCH_SOURCE)
+ FOREACH(TARGET_NAME ${TARGET_NAME_LIST})
+ SET_TARGET_PROPERTIES("${TARGET_NAME}" PROPERTIES
XCODE_ATTRIBUTE_GCC_PRECOMPILE_PREFIX_HEADER YES
XCODE_ATTRIBUTE_GCC_PREFIX_HEADER "${CMAKE_CURRENT_SOURCE_DIR}/${PCH_HEADER}"
)
+ ENDFOREACH()
+ENDFUNCTION(ADD_CXX_PCH_XCODE)
+
+FUNCTION(ADD_CXX_PCH TARGET_NAME_LIST PCH_HEADER PCH_SOURCE)
+ IF (MSVC)
+ ADD_CXX_PCH_MSVC("${TARGET_NAME_LIST}" ${PCH_HEADER} ${PCH_SOURCE})
+ ELSEIF ("${CMAKE_GENERATOR}" MATCHES "Xcode")
+ ADD_CXX_PCH_XCODE("${TARGET_NAME_LIST}" ${PCH_HEADER} ${PCH_SOURCE})
ELSEIF ("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
- ADD_CXX_PCH_CLANG(${TARGET_NAME} ${PCH_HEADER} ${PCH_SOURCE})
+ ADD_CXX_PCH_CLANG("${TARGET_NAME_LIST}" ${PCH_HEADER} ${PCH_SOURCE})
ELSEIF ("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU")
- ADD_CXX_PCH_GCC(${TARGET_NAME} ${PCH_HEADER} ${PCH_SOURCE})
+ ADD_CXX_PCH_GCC("${TARGET_NAME_LIST}" ${PCH_HEADER} ${PCH_SOURCE})
ENDIF ()
ENDFUNCTION(ADD_CXX_PCH)
diff --git a/revision_data.h.in.cmake b/revision_data.h.in.cmake
index 64c754c700b..2e2fe2c318c 100644
--- a/revision_data.h.in.cmake
+++ b/revision_data.h.in.cmake
@@ -3,7 +3,9 @@
#define _HASH "@rev_hash@"
#define _DATE "@rev_date@"
#define _BRANCH "@rev_branch@"
+ #define _CMAKE_COMMAND "@CMAKE_COMMAND@"
#define _SOURCE_DIRECTORY "@CMAKE_SOURCE_DIR@"
+ #define _BUILD_DIRECTORY "@BUILDDIR@"
#define _MYSQL_EXECUTABLE "@MYSQL_EXECUTABLE@"
#define _FULL_DATABASE "TDB_full_world_335.60_2015_11_07.sql"
#define VER_COMPANYNAME_STR "TrinityCore Developers"
@@ -12,6 +14,4 @@
#define VER_FILEVERSION_STR "@rev_hash@ @rev_date@ (@rev_branch@ branch)"
#define VER_PRODUCTVERSION VER_FILEVERSION
#define VER_PRODUCTVERSION_STR VER_FILEVERSION_STR
- #define COMPILER_C_FLAGS "@CMAKE_C_FLAGS@"
- #define COMPILER_CXX_FLAGS "@CMAKE_CXX_FLAGS@"
#endif // __REVISION_DATA_H__
diff --git a/sql/updates/world/2016_02_22_00_world.sql b/sql/updates/world/2016_02_22_00_world.sql
new file mode 100644
index 00000000000..d92ea91681a
--- /dev/null
+++ b/sql/updates/world/2016_02_22_00_world.sql
@@ -0,0 +1,2 @@
+-- baron geddon & ragnaros do pure fire elemental damage with melee attacks
+UPDATE `creature_template` SET `dmgschool`=2 WHERE `entry` in (12056,11502);
diff --git a/sql/updates/world/2016_02_22_01_world.sql b/sql/updates/world/2016_02_22_01_world.sql
new file mode 100644
index 00000000000..b1345bb1aab
--- /dev/null
+++ b/sql/updates/world/2016_02_22_01_world.sql
@@ -0,0 +1,26 @@
+UPDATE`spell_dbc` SET `Effect1`=28, `EffectMiscValueB1`=64 WHERE `Id`IN(38953,38955,38956,38957,38958,38978);
+UPDATE `creature_template` SET `AIName`='SmartAI', `ScriptName`='' WHERE `entry` =22355;
+DELETE FROM `smart_scripts` WHERE `entryorguid` =22355 AND `source_type`=0;
+DELETE FROM `smart_scripts` WHERE `source_type`=9 AND `entryorguid` BETWEEN 2235500 AND 2235505;
+
+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
+(22355, 0, 0, 1, 11, 0, 100, 1, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On Respawn - Disable Combat Movement (No Repeat)'),
+(22355, 0, 1, 2, 61, 0, 100, 0, 0, 0, 0, 0, 18, 2097152, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On Respawn - Set Flag Disarmed (No Repeat)'),
+(22355, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 42, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On Respawn - Set Invincibility HP'),
+(22355, 0, 3, 0, 4, 0, 100, 0, 0, 0, 0, 0, 64, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On Agro - Store Target List (No Repeat)'),
+(22355, 0, 4, 5, 2, 0, 100, 1, 0, 0, 0, 0, 11, 38949, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On 1% HP - Cast Terokkar Free Webbed Creature (No Repeat)'),
+(22355, 0, 5, 6,61, 0, 100, 1, 0, 0, 0, 0, 11, 38950, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On 1% HP - Cast Terokkar Free Webbed Creature ON QUEST (No Repeat)'),
+(22355, 0, 6, 0,61, 0, 100, 1, 0, 0, 0, 0, 87, 2233500, 2233501, 2233502, 2233503, 2233504, 2233505, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - On 1% HP - Run Random Script (No Repeat)'),
+(2235500, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 38953, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 1 - Cast Terokkar Free Webbed Creature '),
+(2235500, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 1 - Die'),
+(2235501, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 38955, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 2 - Cast Terokkar Free Webbed Creature '),
+(2235501, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 2 - Die'),
+(2235502, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 38956, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 3 - Cast Terokkar Free Webbed Creature '),
+(2235502, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 3 - Die'),
+(2235503, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 38957, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 4 - Cast Terokkar Free Webbed Creature '),
+(2235503, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 4 - Die'),
+(2235504, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 38958, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 5 - Cast Terokkar Free Webbed Creature '),
+(2235504, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 5 - Die'),
+(2235505, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 33, 22459, 2, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 6 - Kill Credit'),
+(2235505, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 38978, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 6 - Cast Terokkar Free Webbed Creature '),
+(2235505, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 37, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Netherweb Victim - Script 6 - Die');
diff --git a/sql/updates/world/2016_02_22_02_world.sql b/sql/updates/world/2016_02_22_02_world.sql
new file mode 100644
index 00000000000..dd62e6dce29
--- /dev/null
+++ b/sql/updates/world/2016_02_22_02_world.sql
@@ -0,0 +1,34 @@
+SET @OGUID := 74901;
+
+UPDATE `gameobject` SET `spawntimesecs`=120 WHERE `id`=188441;
+DELETE FROM `gameobject` WHERE `id`=188441 AND `guid` BETWEEN @OGUID+0 AND @OGUID+28;
+INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES
+(@OGUID+0 , 188441, 571, 1, 1, 4599.037, 285.0833, 95.23787, 0.4188786, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+1 , 188441, 571, 1, 1, 4556.1, 231.2934, 96.77894, 0.4537851, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+2 , 188441, 571, 1, 1, 4499.447, 108.0523, 89.83501, 3.996807, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+3 , 188441, 571, 1, 1, 4481.178, 127.8052, 88.98753, 5.044002, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+4 , 188441, 571, 1, 1, 4518.543, 226.8698, 90.04359, 4.97419, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+5 , 188441, 571, 1, 1, 4476.379, 92.48655, 88.96384, 2.321287, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+6 , 188441, 571, 1, 1, 4599.19, 760.0677, 93.87521, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+7, 188441, 571, 1, 1, 4593.348, 741.4844, 95.79951, 3.735006, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+8, 188441, 571, 1, 1, 4751.073, 453.6788, 126.705, 0.6806767, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+9, 188441, 571, 1, 1, 4682.298, 401.2016, 113.0896, 0.9075702, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+10, 188441, 571, 1, 1, 4751.073, 453.6788, 126.705, 0.6806767, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+11, 188441, 571, 1, 1, 4682.298, 401.2016, 113.0896, 0.9075702, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+12, 188441, 571, 1, 1, 4607.061, 650.2381, 99.33231, 0.3141584, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+13, 188441, 571, 1, 1, 4617.78, 647.2289, 100.198, 6.161013, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+14, 188441, 571, 1, 1, 4603.35, 646.6047, 99.39375, 3.281239, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+15, 188441, 571, 1, 1, 4599.037, 285.0833, 95.23787, 0.4188786, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+16, 188441, 571, 1, 1, 4601.033, 262.5729, 94.59935, 3.595379, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+17, 188441, 571, 1, 1, 4578.877, 274.382, 94.57744, 1.256636, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+18, 188441, 571, 1, 1, 4516.654, 214.9381, 90.17368, 4.76475, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+19, 188441, 571, 1, 1, 4570.082, 246.2316, 90.96891, 4.869471, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+20, 188441, 571, 1, 1, 4553.599, 249.401, 91.1224, 3.857183, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+21, 188441, 571, 1, 1, 4532.682, 221.2274, 92.86555, 5.340709, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+22, 188441, 571, 1, 1, 4481.178, 127.8052, 88.98753, 5.044002, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+23, 188441, 571, 1, 1, 4499.447, 108.0523, 89.83501, 3.996807, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+24, 188441, 571, 1, 1, 4505.154, 59.0905, 86.1317, 5.078908, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+25, 188441, 571, 1, 1, 4458.161, 127.8561, 89.45293, 5.881761, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+26, 188441, 571, 1, 1, 4556.1, 231.2934, 96.77894, 0.4537851, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+27, 188441, 571, 1, 1, 4556.1, 231.2934, 96.77894, 0.4537851, 0, 0, 0, 1, 120, 255, 1), -- 188441 (Area: 65)
+(@OGUID+28, 188441, 571, 1, 1, 4583.655, 232.1632, 95.92954, 4.729844, 0, 0, 0, 1, 120, 255, 1); -- 188441 (Area: 65)
diff --git a/sql/updates/world/2016_02_23_00_world.sql b/sql/updates/world/2016_02_23_00_world.sql
new file mode 100644
index 00000000000..871ce608f1c
--- /dev/null
+++ b/sql/updates/world/2016_02_23_00_world.sql
@@ -0,0 +1 @@
+UPDATE `smart_scripts` SET `action_param1`=2235500, `action_param2`=2235501, `action_param3`=2235502, `action_param4`=2235503, `action_param5`=2235504, `action_param6`=2235505 WHERE `entryorguid`=22355 AND `source_type`=0 AND `id`=6 AND `link`=0;
diff --git a/sql/updates/world/2016_02_23_01_world.sql b/sql/updates/world/2016_02_23_01_world.sql
new file mode 100644
index 00000000000..0773487dbc7
--- /dev/null
+++ b/sql/updates/world/2016_02_23_01_world.sql
@@ -0,0 +1,119 @@
+SET @OGUID:=82948;
+SET @CGUID:=85532;
+SET @Event:=7;
+
+-- Add missing lunar objects
+DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+89;
+INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES
+(@OGUID+0 , 180879, 530, 1, 1, -4021.671, -11847.32, 0.006294, 1.902409, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 0) -- exodar
+(@OGUID+1 , 180777, 530, 1, 1, -4016.04, -11831.66, 0.122772, 1.605702, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0)
+(@OGUID+2 , 180777, 530, 1, 1, -4019.716, -11831.79, 0.095343, 4.694937, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0)
+(@OGUID+3 , 180880, 530, 1, 1, -4021.575, -11847.88, 1.865077, 3.42085, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 0)
+(@OGUID+4 , 180881, 530, 1, 1, -4021.983, -11847.42, 1.806305, 4.799657, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 0)
+(@OGUID+5 , 180882, 530, 1, 1, -4021.177, -11847.73, 1.821342, 3.769912, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 0)
+(@OGUID+6 , 180883, 530, 1, 1, -4021.107, -11847.26, 1.800923, 5.811947, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 0)
+(@OGUID+7 , 180883, 530, 1, 1, -4021.65, -11846.95, 1.829355, 5.445428, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 0)
+(@OGUID+8 , 180869, 530, 1, 1, -4023.456, -11837.75, 0.015313, 4.747296, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 0)
+(@OGUID+9 , 180869, 530, 1, 1, -4011.058, -11837.71, 0.147322, 4.694937, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 0)
+(@OGUID+10, 180766, 530, 1, 1, -4012.713, -11842.4, 0.117445, 0.802851, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+11, 180766, 530, 1, 1, -4020.125, -11847.21, 0.023653, 4.642576, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+12, 180766, 530, 1, 1, -4014.778, -11847.44, 0.082153, 1.623156, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+13, 180766, 530, 1, 1, -4022.487, -11842.52, 0.009148, 5.305802, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+14, 180766, 530, 1, 1, -4008.917, -11837.83, 0.170679, 1.361356, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+15, 180766, 530, 1, 1, -4012.804, -11831.57, 0.146643, 2.146753, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+16, 180766, 530, 1, 1, -4025.327, -11837.02, 0.008528, 4.677484, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+17, 180766, 530, 1, 1, -4023.502, -11831.39, 0.072735, 4.06662, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0)
+(@OGUID+18, 180878, 530, 1, 1, -4022.725, -11846.54, -0.003436, 4.502952, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+19, 180878, 530, 1, 1, -4023.054, -11847.33, -0.00903, 3.543024, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+20, 180878, 530, 1, 1, -4022.056, -11846.02, 0.005262, 2.687807, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+21, 180878, 530, 1, 1, -4021.267, -11845.9, 0.014263, 5.567601, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+22, 180878, 530, 1, 1, -4021.343, -11848.85, 0.009881, 4.869471, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+23, 180878, 530, 1, 1, -4022.729, -11848.02, -0.005639, 2.129301, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+24, 180878, 530, 1, 1, -4022.064, -11848.56, 0.00076, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 0)
+(@OGUID+25, 180766, 1, 1, 1, 10147.02, 2574.3, 1320.719, 1.186823, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 1659) -- darnassus
+(@OGUID+26, 180766, 1, 1, 1, 10149.6, 2592.33, 1330.62, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 1659)
+(@OGUID+27, 180766, 1, 1, 1, 10154.62, 2593.352, 1330.546, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 1659)
+(@OGUID+28, 180766, 1, 1, 1, 10148.55, 2610.374, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 1658)
+(@OGUID+29, 180766, 1, 1, 1, 10159.98, 2604.604, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 1658)
+(@OGUID+30, 180766, 1, 1, 1, 10141.72, 2600.144, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 1658)
+(@OGUID+31, 180765, 1, 1, 1, 10040.4, 2478.42, 1353.98, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 0)
+(@OGUID+32, 180765, 1, 1, 1, 10050.7, 2510.37, 1353.98, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 0)
+(@OGUID+33, 180765, 1, 1, 1, 10170.16, 2554.241, 1344.727, 5.846854, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+34, 180765, 1, 1, 1, 10088.98, 2580.349, 1341.743, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+35, 180765, 1, 1, 1, 10170.96, 2556.492, 1366.235, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+36, 180765, 1, 1, 1, 10163.1, 2568.72, 1353.59, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+37, 180765, 1, 1, 1, 10156.62, 2582.27, 1345.43, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+38, 180765, 1, 1, 1, 10107.72, 2590.667, 1341.86, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+39, 180765, 1, 1, 1, 10106.9, 2600.88, 1340.55, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+40, 180765, 1, 1, 1, 10080.89, 2586.866, 1340.509, 5.201083, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+41, 180765, 1, 1, 1, 10185.6, 2561.11, 1366.71, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+42, 180765, 1, 1, 1, 10165.39, 2580.426, 1361.882, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+43, 180765, 1, 1, 1, 10162.87, 2569.218, 1366.497, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1659)
+(@OGUID+44, 180765, 1, 1, 1, 10180.73, 2583.701, 1364.723, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1658)
+(@OGUID+45, 180765, 1, 1, 1, 10185.8, 2575.52, 1366.34, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 1658)
+(@OGUID+46, 180878, 1, 1, 1, 10147.58, 2574.047, 1320.637, 2.129301, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+47, 180878, 1, 1, 1, 10145.04, 2573.837, 1321.027, 5.567601, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+48, 180878, 1, 1, 1, 10146.93, 2572.094, 1320.741, 3.543024, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+49, 180878, 1, 1, 1, 10147.89, 2574.833, 1320.575, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+50, 180878, 1, 1, 1, 10145.3, 2572.096, 1320.981, 4.502952, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+51, 180878, 1, 1, 1, 10144.76, 2572.774, 1321.074, 2.687807, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+52, 180878, 1, 1, 1, 10148.35, 2574.187, 1320.516, 4.869471, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 1659)
+(@OGUID+53, 180879, 1, 1, 1, 10146.29, 2573.105, 1320.675, 5.864307, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 1659)
+(@OGUID+54, 180777, 1, 1, 1, 10155.51, 2571.573, 1320.54, 4.031712, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 1659)
+(@OGUID+55, 180777, 1, 1, 1, 10146.33, 2574.491, 1320.823, 1.169369, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 1659)
+(@OGUID+56, 180777, 1, 1, 1, 10148.78, 2592.293, 1330.527, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 1659)
+(@OGUID+57, 180777, 1, 1, 1, 10155.43, 2593.67, 1330.43, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 1659)
+(@OGUID+58, 180881, 1, 1, 1, 10146.31, 2573.473, 1322.492, 4.799657, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 1659)
+(@OGUID+59, 180882, 1, 1, 1, 10146.49, 2573.022, 1322.495, 4.450591, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 1659)
+(@OGUID+60, 180883, 1, 1, 1, 10145.72, 2573.401, 1322.479, 5.445428, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 1659)
+(@OGUID+61, 180883, 1, 1, 1, 10145.87, 2572.747, 1322.489, 5.811947, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 1659)
+(@OGUID+62, 180868, 1, 1, 1, 10148.56, 2596.947, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 1659)
+(@OGUID+63, 180868, 1, 1, 1, 10154.36, 2598.172, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 1658)
+(@OGUID+64, 180868, 1, 1, 1, 10152.6, 2607.9, 1330.82, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 1658)
+(@OGUID+65, 180868, 1, 1, 1, 10145.24, 2600.956, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 1658)
+(@OGUID+66, 180868, 1, 1, 1, 10146.67, 2607.012, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 1658)
+(@OGUID+67, 180868, 1, 1, 1, 10156.24, 2603.661, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 1658)
+(@OGUID+68, 180869, 1, 1, 1, 10147.5, 2600.15, 1330.82, 1.588249, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 1658)
+(@OGUID+69, 180869, 1, 1, 1, 10153.85, 2601.112, 1330.823, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 1658)
+(@OGUID+70, 180884, 0, 1, 1, -4643.956, -952.7753, 501.6609, 1.675514, 0, 0, 0, 1, 120, 255, 1), -- 180884 (Area: 4679) -- ironforge
+(@OGUID+71, 180777, 0, 1, 1, -4657.851, -970.8358, 502.1435, 1.780234, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 4679)
+(@OGUID+72, 180777, 0, 1, 1, -4647.056, -954.0901, 502.1464, 3.246347, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 4679)
+(@OGUID+73, 180777, 0, 1, 1, -4657.756, -940.899, 502.1457, 1.291542, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 4679)
+(@OGUID+74, 180777, 0, 1, 1, -4676.447, -948.0982, 502.145, 5.689774, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 4679)
+(@OGUID+75, 180880, 0, 1, 1, -4643.901, -952.4222, 502.6053, 1.675514, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 4679)
+(@OGUID+76, 180880, 0, 1, 1, -4644.116, -952.0615, 502.6122, 6.021387, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 4679)
+(@OGUID+77, 180881, 0, 1, 1, -4644.559, -952.6501, 502.5913, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 4679)
+(@OGUID+78, 180881, 0, 1, 1, -4644.697, -951.6542, 502.5873, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 4679)
+(@OGUID+79, 180882, 0, 1, 1, -4643.973, -951.5918, 502.5915, 5.061456, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 4679)
+(@OGUID+80, 180882, 0, 1, 1, -4643.597, -952.0538, 502.5845, 3.926996, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 4679)
+(@OGUID+81, 180883, 0, 1, 1, -4643.862, -952.8162, 502.5914, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 4679)
+(@OGUID+82, 180883, 0, 1, 1, -4644.573, -952.2311, 502.5913, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 4679)
+(@OGUID+83, 180868, 530, 1, 1, -4014.642, -11845.6, 0.088204, 4.694937, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 0) -- more exodar
+(@OGUID+84, 180868, 530, 1, 1, -4020.391, -11845.43, 0.025103, 4.747296, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 0)
+(@OGUID+85, 180868, 530, 1, 1, -4014.579, -11842.59, 0.096342, 4.694937, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 0)
+(@OGUID+86, 180868, 530, 1, 1, -4014.198, -11835.3, 0.118586, 4.694937, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 0)
+(@OGUID+87, 180868, 530, 1, 1, -4021.152, -11835.28, 0.0539, 4.747296, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 0)
+(@OGUID+88, 180868, 530, 1, 1, -4020.445, -11842.34, 0.032153, 4.747296, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 0)
+(@OGUID+89, 180868, 530, 1, 1, -4017.739, -11832.38, 0.104225, 4.729844, 0, 0, 0, 1, 120, 255, 1); -- 180868 (Area: 0)
+
+DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+89 AND `eventEntry`=@Event;
+INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+89;
+
+-- Add missing lunar spawns
+DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+11;
+INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES
+(@CGUID+0, 15892, 530, -4014.533, -11839.5, 0.1878313, 2.617994, 120, 0), -- 15892 (Area: 0)
+(@CGUID+1, 15892, 530, -4017.631, -11834.3, 0.1710953, 4.747295, 120, 0), -- 15892 (Area: 0)
+(@CGUID+2, 15892, 530, -4020.615, -11839.4, 0.1208633, 0.4712389, 120, 0), -- 15892 (Area: 0)
+(@CGUID+3, 15892, 1, 10146.8, 2603.15, 1330.903, 6.021386, 120, 0), -- 15892 (Area: 1658)
+(@CGUID+4, 15892, 1, 10151.3, 2598.93, 1330.903, 1.780236, 120, 0), -- 15892 (Area: 1658)
+(@CGUID+5, 15892, 1, 10153.2, 2604.51, 1330.903, 3.961897, 120, 0), -- 15892 (Area: 1658)
+(@CGUID+6, 15898, 530, -4020.056, -11848.42, 0.1050933, 4.677482, 120, 0), -- 15898 (Area: 0) (Auras: )
+(@CGUID+7, 15898, 1, 10148.03, 2572.627, 1320.697, 4.18879, 120, 0), -- 15898 (Area: 1659) (Auras: )
+(@CGUID+8, 15895, 530, -4014.714, -11848.54, 0.1634673, 4.799655, 120, 0), -- 15895 (Area: 0) (Auras: )
+(@CGUID+9, 15895, 1, 10153.6, 2593.45, 1330.843, 4.799655, 120, 0), -- 15895 (Area: 1659) (Auras: )
+(@CGUID+10, 15897, 530, -4017.511, -11837.73, 0.1593063, 4.39823, 120, 0), -- 15897 (Area: 0) (Auras: 25824 - 25824)
+(@CGUID+11, 15897, 1, 10150.53, 2602.14, 1330.906, 1.570796, 120, 0); -- 15897 (Area: 1658) (Auras: 25824 - 25824)
+
+DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+11 AND `eventEntry`=@Event;
+INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+11;
diff --git a/sql/updates/world/2016_02_23_02_world.sql b/sql/updates/world/2016_02_23_02_world.sql
new file mode 100644
index 00000000000..9e2c550dd65
--- /dev/null
+++ b/sql/updates/world/2016_02_23_02_world.sql
@@ -0,0 +1,6 @@
+DELETE FROM `creature_text` WHERE `entry` IN(37671,38065) AND `id`>0;
+INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES
+(37671, 0, 1, 'Time is money, friend. Go go go!', 12, 0, 100, 1, 0, 0, 38022, 0, 'Crown Supply Guard'),
+(38065, 0, 1, 'Time is money, friend. Go go go!', 12, 0, 100, 1, 0, 0, 38022, 0, 'Crown Supply Guard'),
+(37671, 0, 2, 'The Lovely Merchant is waiting for that. Hurry it up!', 12, 0, 100, 1, 0, 0, 38023, 0, 'Crown Supply Guard'),
+(38065, 0, 2, 'The Lovely Merchant is waiting for that. Hurry it up!', 12, 0, 100, 1, 0, 0, 38023, 0, 'Crown Supply Guard');
diff --git a/src/common/Configuration/BuiltInConfig.cpp b/src/common/Configuration/BuiltInConfig.cpp
new file mode 100644
index 00000000000..c2fc3b91766
--- /dev/null
+++ b/src/common/Configuration/BuiltInConfig.cpp
@@ -0,0 +1,52 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+#include "BuiltInConfig.h"
+#include "Config.h"
+#include "GitRevision.h"
+
+template<typename Fn>
+static std::string GetStringWithDefaultValueFromFunction(
+ std::string const& key, Fn getter)
+{
+ std::string const value = sConfigMgr->GetStringDefault(key, "");
+ return value.empty() ? getter() : value;
+}
+
+std::string BuiltInConfig::GetCMakeCommand()
+{
+ return GetStringWithDefaultValueFromFunction(
+ "CMakeCommand", GitRevision::GetCMakeCommand);
+}
+
+std::string BuiltInConfig::GetBuildDirectory()
+{
+ return GetStringWithDefaultValueFromFunction(
+ "BuildDirectory", GitRevision::GetBuildDirectory);
+}
+
+std::string BuiltInConfig::GetSourceDirectory()
+{
+ return GetStringWithDefaultValueFromFunction(
+ "SourceDirectory", GitRevision::GetSourceDirectory);
+}
+
+std::string BuiltInConfig::GetMySQLExecutable()
+{
+ return GetStringWithDefaultValueFromFunction(
+ "MySQLExecutable", GitRevision::GetMySQLExecutable);
+}
diff --git a/src/common/Configuration/BuiltInConfig.h b/src/common/Configuration/BuiltInConfig.h
new file mode 100644
index 00000000000..4ae4ed40189
--- /dev/null
+++ b/src/common/Configuration/BuiltInConfig.h
@@ -0,0 +1,42 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+#ifndef BUILT_IN_CONFIG_H
+#define BUILT_IN_CONFIG_H
+
+#include <string>
+
+/// Provides helper functions to access built-in values
+/// which can be overwritten in config
+namespace BuiltInConfig
+{
+ /// Returns the CMake command when any is specified in the config,
+ /// returns the built-in path otherwise
+ std::string GetCMakeCommand();
+ /// Returns the build directory path when any is specified in the config,
+ /// returns the built-in one otherwise
+ std::string GetBuildDirectory();
+ /// Returns the source directory path when any is specified in the config,
+ /// returns the built-in one otherwise
+ std::string GetSourceDirectory();
+ /// Returns the path to the mysql executable (`mysql`) when any is specified
+ /// in the config, returns the built-in one otherwise
+ std::string GetMySQLExecutable();
+
+} // namespace BuiltInConfig
+
+#endif // BUILT_IN_CONFIG_H
diff --git a/src/common/Configuration/Config.cpp b/src/common/Configuration/Config.cpp
index 6ac04615315..5db333c8aff 100644
--- a/src/common/Configuration/Config.cpp
+++ b/src/common/Configuration/Config.cpp
@@ -61,7 +61,7 @@ bool ConfigMgr::Reload(std::string& error)
return LoadInitial(_filename, error);
}
-std::string ConfigMgr::GetStringDefault(std::string const& name, const std::string& def)
+std::string ConfigMgr::GetStringDefault(std::string const& name, const std::string& def) const
{
std::string value = _config.get<std::string>(ptree::path_type(name, '/'), def);
@@ -70,7 +70,7 @@ std::string ConfigMgr::GetStringDefault(std::string const& name, const std::stri
return value;
}
-bool ConfigMgr::GetBoolDefault(std::string const& name, bool def)
+bool ConfigMgr::GetBoolDefault(std::string const& name, bool def) const
{
try
{
@@ -84,12 +84,12 @@ bool ConfigMgr::GetBoolDefault(std::string const& name, bool def)
}
}
-int ConfigMgr::GetIntDefault(std::string const& name, int def)
+int ConfigMgr::GetIntDefault(std::string const& name, int def) const
{
return _config.get<int>(ptree::path_type(name, '/'), def);
}
-float ConfigMgr::GetFloatDefault(std::string const& name, float def)
+float ConfigMgr::GetFloatDefault(std::string const& name, float def) const
{
return _config.get<float>(ptree::path_type(name, '/'), def);
}
diff --git a/src/common/Configuration/Config.h b/src/common/Configuration/Config.h
index 5b04212ed7c..ada910d8fcc 100644
--- a/src/common/Configuration/Config.h
+++ b/src/common/Configuration/Config.h
@@ -41,10 +41,10 @@ public:
bool Reload(std::string& error);
- std::string GetStringDefault(std::string const& name, const std::string& def);
- bool GetBoolDefault(std::string const& name, bool def);
- int GetIntDefault(std::string const& name, int def);
- float GetFloatDefault(std::string const& name, float def);
+ std::string GetStringDefault(std::string const& name, const std::string& def) const;
+ bool GetBoolDefault(std::string const& name, bool def) const;
+ int GetIntDefault(std::string const& name, int def) const;
+ float GetFloatDefault(std::string const& name, float def) const;
std::string const& GetFilename();
std::list<std::string> GetKeysByString(std::string const& name);
diff --git a/src/common/GitRevision.cpp b/src/common/GitRevision.cpp
index d0719c09959..5343fbd6531 100644
--- a/src/common/GitRevision.cpp
+++ b/src/common/GitRevision.cpp
@@ -17,6 +17,16 @@ char const* GitRevision::GetBranch()
return _BRANCH;
}
+char const* GitRevision::GetCMakeCommand()
+{
+ return _CMAKE_COMMAND;
+}
+
+char const* GitRevision::GetBuildDirectory()
+{
+ return _BUILD_DIRECTORY;
+}
+
char const* GitRevision::GetSourceDirectory()
{
return _SOURCE_DIRECTORY;
@@ -66,13 +76,3 @@ char const* GitRevision::GetProductVersionStr()
{
return VER_PRODUCTVERSION_STR;
}
-
-char const* GitRevision::GetCompilerCFlags()
-{
- return COMPILER_C_FLAGS;
-}
-
-char const* GitRevision::GetCompilerCXXFlags()
-{
- return COMPILER_CXX_FLAGS;
-}
diff --git a/src/common/GitRevision.h b/src/common/GitRevision.h
index 8d2764ba861..7fddcb7605a 100644
--- a/src/common/GitRevision.h
+++ b/src/common/GitRevision.h
@@ -25,6 +25,8 @@ namespace GitRevision
char const* GetHash();
char const* GetDate();
char const* GetBranch();
+ char const* GetCMakeCommand();
+ char const* GetBuildDirectory();
char const* GetSourceDirectory();
char const* GetMySQLExecutable();
char const* GetFullDatabase();
@@ -33,8 +35,6 @@ namespace GitRevision
char const* GetLegalCopyrightStr();
char const* GetFileVersionStr();
char const* GetProductVersionStr();
- char const* GetCompilerCFlags();
- char const* GetCompilerCXXFlags();
}
#endif
diff --git a/src/common/Threading/MPSCQueue.h b/src/common/Threading/MPSCQueue.h
new file mode 100644
index 00000000000..09648b844be
--- /dev/null
+++ b/src/common/Threading/MPSCQueue.h
@@ -0,0 +1,83 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+#ifndef MPSCQueue_h__
+#define MPSCQueue_h__
+
+#include <atomic>
+#include <utility>
+
+// C++ implementation of Dmitry Vyukov's lock free MPSC queue
+// http://www.1024cores.net/home/lock-free-algorithms/queues/non-intrusive-mpsc-node-based-queue
+template<typename T>
+class MPSCQueue
+{
+public:
+ MPSCQueue() : _head(new Node()), _tail(_head.load(std::memory_order_relaxed))
+ {
+ Node* front = _head.load(std::memory_order_relaxed);
+ front->Next.store(nullptr, std::memory_order_relaxed);
+ }
+
+ ~MPSCQueue()
+ {
+ T* output;
+ while (this->Dequeue(output))
+ ;
+
+ Node* front = _head.load(std::memory_order_relaxed);
+ delete front;
+ }
+
+ void Enqueue(T* input)
+ {
+ Node* node = new Node(input);
+ Node* prevHead = _head.exchange(node, std::memory_order_acq_rel);
+ prevHead->Next.store(node, std::memory_order_release);
+ }
+
+ bool Dequeue(T*& result)
+ {
+ Node* tail = _tail.load(std::memory_order_relaxed);
+ Node* next = tail->Next.load(std::memory_order_acquire);
+ if (!next)
+ return false;
+
+ result = next->Data;
+ _tail.store(next, std::memory_order_release);
+ delete tail;
+ return true;
+ }
+
+private:
+ struct Node
+ {
+ Node() = default;
+ explicit Node(T* data) : Data(data) { Next.store(nullptr, std::memory_order_relaxed); }
+
+ T* Data;
+ std::atomic<Node*> Next;
+ };
+
+ std::atomic<Node*> _head;
+ std::atomic<Node*> _tail;
+
+ MPSCQueue(MPSCQueue const&) = delete;
+ MPSCQueue& operator=(MPSCQueue const&) = delete;
+};
+
+#endif // MPSCQueue_h__
diff --git a/src/server/authserver/CMakeLists.txt b/src/server/authserver/CMakeLists.txt
index c11deec39bb..d87847d6740 100644
--- a/src/server/authserver/CMakeLists.txt
+++ b/src/server/authserver/CMakeLists.txt
@@ -79,10 +79,10 @@ if( NOT WIN32 )
endif()
target_link_libraries(authserver
- common
shared
- format
database
+ common
+ format
${MYSQL_LIBRARY}
${OPENSSL_LIBRARIES}
${CMAKE_THREAD_LIBS_INIT}
diff --git a/src/server/authserver/Server/AuthSession.cpp b/src/server/authserver/Server/AuthSession.cpp
index 519cd1f19f7..57e5d6682f2 100644
--- a/src/server/authserver/Server/AuthSession.cpp
+++ b/src/server/authserver/Server/AuthSession.cpp
@@ -274,10 +274,7 @@ void AuthSession::SendPacket(ByteBuffer& packet)
{
MessageBuffer buffer;
buffer.Write(packet.contents(), packet.size());
-
- std::unique_lock<std::mutex> guard(_writeLock);
-
- QueuePacket(std::move(buffer), guard);
+ QueuePacket(std::move(buffer));
}
}
diff --git a/src/server/authserver/Server/AuthSocketMgr.h b/src/server/authserver/Server/AuthSocketMgr.h
index fa96502663f..a16b7d405b9 100644
--- a/src/server/authserver/Server/AuthSocketMgr.h
+++ b/src/server/authserver/Server/AuthSocketMgr.h
@@ -21,8 +21,6 @@
#include "SocketMgr.h"
#include "AuthSession.h"
-void OnSocketAccept(tcp::socket&& sock);
-
class AuthSocketMgr : public SocketMgr<AuthSession>
{
typedef SocketMgr<AuthSession> BaseSocketMgr;
@@ -39,7 +37,7 @@ public:
if (!BaseSocketMgr::StartNetwork(service, bindIp, port))
return false;
- _acceptor->AsyncAcceptManaged(&OnSocketAccept);
+ _acceptor->AsyncAcceptWithCallback<&AuthSocketMgr::OnSocketAccept>();
return true;
}
@@ -48,14 +46,13 @@ protected:
{
return new NetworkThread<AuthSession>[1];
}
+
+ static void OnSocketAccept(tcp::socket&& sock, uint32 threadIndex)
+ {
+ Instance().OnSocketOpen(std::forward<tcp::socket>(sock), threadIndex);
+ }
};
#define sAuthSocketMgr AuthSocketMgr::Instance()
-void OnSocketAccept(tcp::socket&& sock)
-{
- sAuthSocketMgr.OnSocketOpen(std::forward<tcp::socket>(sock));
-}
-
-
#endif // AuthSocketMgr_h__
diff --git a/src/server/authserver/authserver.conf.dist b/src/server/authserver/authserver.conf.dist
index 82c3cd47148..a97d75b3f57 100644
--- a/src/server/authserver/authserver.conf.dist
+++ b/src/server/authserver/authserver.conf.dist
@@ -138,6 +138,26 @@ WrongPass.Logging = 0
BanExpiryCheckInterval = 60
#
+# SourceDirectory
+# Description: The path to your TrinityCore source directory.
+# If the path is left empty, the built-in CMAKE_SOURCE_DIR is used.
+# Example: "../TrinityCore"
+# Default: ""
+
+SourceDirectory = ""
+
+#
+# MySQLExecutable
+# Description: The path to your mysql cli binary.
+# If the path is left empty, built-in path from cmake is used.
+# Example: "C:/Program Files/MySQL/MySQL Server 5.6/bin/mysql.exe"
+# "mysql.exe"
+# "/usr/bin/mysql"
+# Default: ""
+
+MySQLExecutable = ""
+
+#
###################################################################################################
###################################################################################################
@@ -181,26 +201,6 @@ LoginDatabase.WorkerThreads = 1
Updates.EnableDatabases = 0
#
-# Updates.SourcePath
-# Description: The path to your TrinityCore source directory.
-# If the path is left empty, built-in CMAKE_SOURCE_DIR is used.
-# Example: "../TrinityCore"
-# Default: ""
-
-Updates.SourcePath = ""
-
-#
-# Updates.MySqlCLIPath
-# Description: The path to your mysql cli binary.
-# If the path is left empty, built-in path from cmake is used.
-# Example: "C:/Program Files/MySQL/MySQL Server 5.6/bin/mysql.exe"
-# "mysql.exe"
-# "/usr/bin/mysql"
-# Default: ""
-
-Updates.MySqlCLIPath = ""
-
-#
# Updates.AutoSetup
# Description: Auto populate empty databases.
# Default: 1 - (Enabled)
diff --git a/src/server/database/Updater/DBUpdater.cpp b/src/server/database/Updater/DBUpdater.cpp
index 170954a86f4..b18d6c67612 100644
--- a/src/server/database/Updater/DBUpdater.cpp
+++ b/src/server/database/Updater/DBUpdater.cpp
@@ -21,6 +21,7 @@
#include "UpdateFetcher.h"
#include "DatabaseLoader.h"
#include "Config.h"
+#include "BuiltInConfig.h"
#include <fstream>
#include <iostream>
@@ -35,23 +36,17 @@ using namespace boost::process;
using namespace boost::process::initializers;
using namespace boost::iostreams;
-std::string DBUpdaterUtil::GetMySqlCli()
+std::string DBUpdaterUtil::GetCorrectedMySQLExecutable()
{
if (!corrected_path().empty())
return corrected_path();
else
- {
- std::string const entry = sConfigMgr->GetStringDefault("Updates.MySqlCLIPath", "");
- if (!entry.empty())
- return entry;
- else
- return GitRevision::GetMySQLExecutable();
- }
+ return BuiltInConfig::GetMySQLExecutable();
}
bool DBUpdaterUtil::CheckExecutable()
{
- boost::filesystem::path exe(GetMySqlCli());
+ boost::filesystem::path exe(GetCorrectedMySQLExecutable());
if (!exists(exe))
{
exe.clear();
@@ -85,16 +80,6 @@ std::string& DBUpdaterUtil::corrected_path()
return path;
}
-template<class T>
-std::string DBUpdater<T>::GetSourceDirectory()
-{
- std::string const entry = sConfigMgr->GetStringDefault("Updates.SourcePath", "");
- if (!entry.empty())
- return entry;
- else
- return GitRevision::GetSourceDirectory();
-}
-
// Auth Database
template<>
std::string DBUpdater<LoginDatabaseConnection>::GetConfigEntry()
@@ -111,7 +96,8 @@ std::string DBUpdater<LoginDatabaseConnection>::GetTableName()
template<>
std::string DBUpdater<LoginDatabaseConnection>::GetBaseFile()
{
- return DBUpdater<LoginDatabaseConnection>::GetSourceDirectory() + "/sql/base/auth_database.sql";
+ return BuiltInConfig::GetSourceDirectory() +
+ "/sql/base/auth_database.sql";
}
template<>
@@ -169,7 +155,8 @@ std::string DBUpdater<CharacterDatabaseConnection>::GetTableName()
template<>
std::string DBUpdater<CharacterDatabaseConnection>::GetBaseFile()
{
- return DBUpdater<CharacterDatabaseConnection>::GetSourceDirectory() + "/sql/base/characters_database.sql";
+ return BuiltInConfig::GetSourceDirectory() +
+ "/sql/base/characters_database.sql";
}
template<>
@@ -239,7 +226,7 @@ bool DBUpdater<T>::Update(DatabaseWorkerPool<T>& pool)
TC_LOG_INFO("sql.updates", "Updating %s database...", DBUpdater<T>::GetTableName().c_str());
- Path const sourceDirectory(GetSourceDirectory());
+ Path const sourceDirectory(BuiltInConfig::GetSourceDirectory());
if (!is_directory(sourceDirectory))
{
@@ -410,7 +397,7 @@ void DBUpdater<T>::ApplyFile(DatabaseWorkerPool<T>& pool, std::string const& hos
boost::process::pipe errPipe = create_pipe();
child c = execute(run_exe(
- boost::filesystem::absolute(DBUpdaterUtil::GetMySqlCli()).generic_string()),
+ boost::filesystem::absolute(DBUpdaterUtil::GetCorrectedMySQLExecutable()).generic_string()),
set_args(args), bind_stdin(source), throw_on_error(),
bind_stdout(file_descriptor_sink(outPipe.sink, close_handle)),
bind_stderr(file_descriptor_sink(errPipe.sink, close_handle)));
diff --git a/src/server/database/Updater/DBUpdater.h b/src/server/database/Updater/DBUpdater.h
index c9792ffe060..dbb897d2527 100644
--- a/src/server/database/Updater/DBUpdater.h
+++ b/src/server/database/Updater/DBUpdater.h
@@ -57,7 +57,7 @@ struct UpdateResult
class DBUpdaterUtil
{
public:
- static std::string GetMySqlCli();
+ static std::string GetCorrectedMySQLExecutable();
static bool CheckExecutable();
@@ -71,8 +71,6 @@ class DBUpdater
public:
using Path = boost::filesystem::path;
- static std::string GetSourceDirectory();
-
static inline std::string GetConfigEntry();
static inline std::string GetTableName();
diff --git a/src/server/database/Updater/UpdateFetcher.cpp b/src/server/database/Updater/UpdateFetcher.cpp
index fd0dbdd4b5a..2d60cdb92ef 100644
--- a/src/server/database/Updater/UpdateFetcher.cpp
+++ b/src/server/database/Updater/UpdateFetcher.cpp
@@ -137,24 +137,33 @@ UpdateFetcher::AppliedFileStorage UpdateFetcher::ReceiveAppliedFiles() const
return map;
}
-UpdateFetcher::SQLUpdate UpdateFetcher::ReadSQLUpdate(boost::filesystem::path const& file) const
+std::string UpdateFetcher::ReadSQLUpdate(boost::filesystem::path const& file) const
{
std::ifstream in(file.c_str());
- WPFatal(in.is_open(), "Could not read an update file.");
+ if (!in.is_open())
+ {
+ TC_LOG_FATAL("sql.updates", "Failed to open the sql update \"%s\" for reading! "
+ "Stopping the server to keep the database integrity, "
+ "try to identify and solve the issue or disabled the database updater.",
+ file.generic_string().c_str());
- auto const start_pos = in.tellg();
- in.ignore(std::numeric_limits<std::streamsize>::max());
- auto const char_count = in.gcount();
- in.seekg(start_pos);
+ throw UpdateException("Opening the sql update failed!");
+ }
- SQLUpdate const update(new std::string(char_count, char{}));
+ auto update = [&in] {
+ std::ostringstream ss;
+ ss << in.rdbuf();
+ return ss.str();
+ }();
- in.read(&(*update)[0], update->size());
in.close();
return update;
}
-UpdateResult UpdateFetcher::Update(bool const redundancyChecks, bool const allowRehash, bool const archivedRedundancy, int32 const cleanDeadReferencesMaxCount) const
+UpdateResult UpdateFetcher::Update(bool const redundancyChecks,
+ bool const allowRehash,
+ bool const archivedRedundancy,
+ int32 const cleanDeadReferencesMaxCount) const
{
LocaleFileStorage const available = GetFileList();
AppliedFileStorage applied = ReceiveAppliedFiles();
@@ -200,11 +209,9 @@ UpdateResult UpdateFetcher::Update(bool const redundancyChecks, bool const allow
}
}
- // Read update from file
- SQLUpdate const update = ReadSQLUpdate(availableQuery.first);
-
// Calculate hash
- std::string const hash = CalculateHash(update);
+ std::string const hash =
+ CalculateHash(ReadSQLUpdate(availableQuery.first));
UpdateMode mode = MODE_APPLY;
@@ -327,11 +334,11 @@ UpdateResult UpdateFetcher::Update(bool const redundancyChecks, bool const allow
return UpdateResult(importedUpdates, countRecentUpdates, countArchivedUpdates);
}
-std::string UpdateFetcher::CalculateHash(SQLUpdate const& query) const
+std::string UpdateFetcher::CalculateHash(std::string const& query) const
{
// Calculate a Sha1 hash based on query content.
unsigned char digest[SHA_DIGEST_LENGTH];
- SHA1((unsigned char*)query->c_str(), query->length(), (unsigned char*)&digest);
+ SHA1((unsigned char*)query.c_str(), query.length(), (unsigned char*)&digest);
return ByteArrayToHexStr(digest, SHA_DIGEST_LENGTH);
}
diff --git a/src/server/database/Updater/UpdateFetcher.h b/src/server/database/Updater/UpdateFetcher.h
index 22a0d08c7f8..c87efea2b02 100644
--- a/src/server/database/Updater/UpdateFetcher.h
+++ b/src/server/database/Updater/UpdateFetcher.h
@@ -103,16 +103,16 @@ private:
typedef std::unordered_map<std::string, std::string> HashToFileNameStorage;
typedef std::unordered_map<std::string, AppliedFileEntry> AppliedFileStorage;
typedef std::vector<UpdateFetcher::DirectoryEntry> DirectoryStorage;
- typedef std::shared_ptr<std::string> SQLUpdate;
LocaleFileStorage GetFileList() const;
- void FillFileListRecursively(Path const& path, LocaleFileStorage& storage, State const state, uint32 const depth) const;
+ void FillFileListRecursively(Path const& path, LocaleFileStorage& storage,
+ State const state, uint32 const depth) const;
DirectoryStorage ReceiveIncludedDirectories() const;
AppliedFileStorage ReceiveAppliedFiles() const;
- SQLUpdate ReadSQLUpdate(Path const& file) const;
- std::string CalculateHash(SQLUpdate const& query) const;
+ std::string ReadSQLUpdate(Path const& file) const;
+ std::string CalculateHash(std::string const& query) const;
uint32 Apply(Path const& path) const;
diff --git a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp
index 68cb8d346d0..fa80634e0f0 100644
--- a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp
+++ b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp
@@ -105,7 +105,7 @@ bool npc_escortAI::AssistPlayerInCombat(Unit* who)
void npc_escortAI::MoveInLineOfSight(Unit* who)
{
- if (!me->HasUnitState(UNIT_STATE_STUNNED) && who->isTargetableForAttack() && who->isInAccessiblePlaceFor(me))
+ if (me->HasReactState(REACT_AGGRESSIVE) && !me->HasUnitState(UNIT_STATE_STUNNED) && who->isTargetableForAttack() && who->isInAccessiblePlaceFor(me))
{
if (HasEscortState(STATE_ESCORT_ESCORTING) && AssistPlayerInCombat(who))
return;
diff --git a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp
index dc9f6d2681e..778edf8cab5 100644
--- a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp
+++ b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp
@@ -102,7 +102,7 @@ bool FollowerAI::AssistPlayerInCombat(Unit* who)
void FollowerAI::MoveInLineOfSight(Unit* who)
{
- if (!me->HasUnitState(UNIT_STATE_STUNNED) && who->isTargetableForAttack() && who->isInAccessiblePlaceFor(me))
+ if (me->HasReactState(REACT_AGGRESSIVE) && !me->HasUnitState(UNIT_STATE_STUNNED) && who->isTargetableForAttack() && who->isInAccessiblePlaceFor(me))
{
if (HasFollowState(STATE_FOLLOW_INPROGRESS) && AssistPlayerInCombat(who))
return;
diff --git a/src/server/game/AI/SmartScripts/SmartAI.cpp b/src/server/game/AI/SmartScripts/SmartAI.cpp
index eca327e770e..361bb1a5b1d 100644
--- a/src/server/game/AI/SmartScripts/SmartAI.cpp
+++ b/src/server/game/AI/SmartScripts/SmartAI.cpp
@@ -466,6 +466,9 @@ bool SmartAI::CanAIAttack(const Unit* /*who*/) const
bool SmartAI::AssistPlayerInCombat(Unit* who)
{
+ if (me->HasReactState(REACT_PASSIVE))
+ return false;
+
if (!who || !who->GetVictim())
return false;
diff --git a/src/server/game/Achievements/AchievementMgr.cpp b/src/server/game/Achievements/AchievementMgr.cpp
index ac8e0298a44..40cb643bbb5 100644
--- a/src/server/game/Achievements/AchievementMgr.cpp
+++ b/src/server/game/Achievements/AchievementMgr.cpp
@@ -46,7 +46,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
{
if (dataType >= MAX_ACHIEVEMENT_CRITERIA_DATA_TYPE)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` for criteria (Entry: %u) has wrong data type (%u), ignored.", criteria->ID, dataType);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` for criteria (Entry: %u) contains a wrong data type (%u), ignored.", criteria->ID, dataType);
return false;
}
@@ -81,7 +81,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
default:
if (dataType != ACHIEVEMENT_CRITERIA_DATA_TYPE_SCRIPT)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` has data for non-supported criteria type (Entry: %u Type: %u), ignored.", criteria->ID, criteria->requiredType);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` contains data for a non-supported criteria type (Entry: %u Type: %u), ignored.", criteria->ID, criteria->requiredType);
return false;
}
break;
@@ -96,7 +96,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_CREATURE:
if (!creature.id || !sObjectMgr->GetCreatureTemplate(creature.id))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_CREATURE (%u) has non-existing creature id in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_CREATURE (%u) contains a non-existing creature id in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, creature.id);
return false;
}
@@ -104,13 +104,13 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_CLASS_RACE:
if (classRace.class_id && ((1 << (classRace.class_id-1)) & CLASSMASK_ALL_PLAYABLE) == 0)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_CLASS_RACE (%u) has non-existing class in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_CLASS_RACE (%u) contains a non-existing class in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, classRace.class_id);
return false;
}
if (classRace.race_id && ((1 << (classRace.race_id-1)) & RACEMASK_ALL_PLAYABLE) == 0)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_CLASS_RACE (%u) has non-existing race in value2 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_CLASS_RACE (%u) contains a non-existing race in value2 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, classRace.race_id);
return false;
}
@@ -118,7 +118,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_LESS_HEALTH:
if (health.percent < 1 || health.percent > 100)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_PLAYER_LESS_HEALTH (%u) has wrong percent value in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_PLAYER_LESS_HEALTH (%u) contains a wrong percent value in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, health.percent);
return false;
}
@@ -126,7 +126,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_DEAD:
if (player_dead.own_team_flag > 1)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_DEAD (%u) has wrong boolean value1 (%u).",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_DEAD (%u) contains a wrong boolean value1 (%u).",
criteria->ID, criteria->requiredType, dataType, player_dead.own_team_flag);
return false;
}
@@ -137,19 +137,19 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
SpellInfo const* spellEntry = sSpellMgr->GetSpellInfo(aura.spell_id);
if (!spellEntry)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) has wrong spell id in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) contains a wrong spell id in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, (dataType == ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AURA?"ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AURA":"ACHIEVEMENT_CRITERIA_DATA_TYPE_T_AURA"), dataType, aura.spell_id);
return false;
}
if (aura.effect_idx >= 3)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) has wrong spell effect index in value2 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) contains a wrong spell effect index in value2 (%u), ignored.",
criteria->ID, criteria->requiredType, (dataType == ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AURA?"ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AURA":"ACHIEVEMENT_CRITERIA_DATA_TYPE_T_AURA"), dataType, aura.effect_idx);
return false;
}
if (!spellEntry->Effects[aura.effect_idx].ApplyAuraName)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) has non-aura spell effect (ID: %u Effect: %u), ignores.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) contains a non-aura spell effect (ID: %u Effect: %u), ignored.",
criteria->ID, criteria->requiredType, (dataType == ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AURA?"ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AURA":"ACHIEVEMENT_CRITERIA_DATA_TYPE_T_AURA"), dataType, aura.spell_id, aura.effect_idx);
return false;
}
@@ -158,7 +158,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AREA:
if (!sAreaTableStore.LookupEntry(area.id))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AREA (%u) has wrong area id in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AREA (%u) contains a wrong area id in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, area.id);
return false;
}
@@ -166,7 +166,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE:
if (value.compType >= COMP_TYPE_MAX)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE (%u) has wrong ComparisionType in value2 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_VALUE (%u) contains a wrong ComparisionType in value2 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, value.compType);
return false;
}
@@ -174,7 +174,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_LEVEL:
if (level.minlevel > STRONG_MAX_LEVEL)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_LEVEL (%u) has wrong minlevel in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_LEVEL (%u) contains a wrong minlevel in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, level.minlevel);
return false;
}
@@ -182,7 +182,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_GENDER:
if (gender.gender > GENDER_NONE)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_GENDER (%u) has wrong gender in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_GENDER (%u) contains a wrong gender value in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, gender.gender);
return false;
}
@@ -190,7 +190,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_SCRIPT:
if (!ScriptId)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_SCRIPT (%u) does not have ScriptName set, ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_SCRIPT (%u) does not have a ScriptName set, ignored.",
criteria->ID, criteria->requiredType, dataType);
return false;
}
@@ -198,7 +198,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_DIFFICULTY:
if (difficulty.difficulty >= MAX_DIFFICULTY)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_DIFFICULTY (%u) has wrong difficulty in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_DIFFICULTY (%u) contains a wrong difficulty value in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, difficulty.difficulty);
return false;
}
@@ -206,7 +206,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_PLAYER_COUNT:
if (map_players.maxcount <= 0)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_PLAYER_COUNT (%u) has wrong max players count in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_PLAYER_COUNT (%u) contains a wrong max players count in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, map_players.maxcount);
return false;
}
@@ -214,7 +214,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_TEAM:
if (team.team != ALLIANCE && team.team != HORDE)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_TEAM (%u) has unknown team in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_TEAM (%u) contains an unknown team value in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, team.team);
return false;
}
@@ -222,7 +222,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_S_DRUNK:
if (drunk.state >= MAX_DRUNKEN)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_DRUNK (%u) has unknown drunken state in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_DRUNK (%u) contains an unknown drunken state value in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, drunk.state);
return false;
}
@@ -230,7 +230,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_HOLIDAY:
if (!sHolidaysStore.LookupEntry(holiday.id))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_HOLIDAY (%u) has unknown holiday in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_HOLIDAY (%u) contains an unknown holiday entry in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, holiday.id);
return false;
}
@@ -240,7 +240,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_S_EQUIPED_ITEM:
if (equipped_item.item_quality >= MAX_ITEM_QUALITY)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_EQUIPED_ITEM (%u) has unknown quality state in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_EQUIPED_ITEM (%u) contains an unknown quality state value in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, equipped_item.item_quality);
return false;
}
@@ -248,7 +248,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_ID:
if (!sMapStore.LookupEntry(map_id.mapId))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_ID (%u) has unknown map id in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_MAP_ID (%u) contains an unknown map id in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, map_id.mapId);
return false;
}
@@ -256,19 +256,19 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE:
if (!classRace.class_id && !classRace.race_id)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE (%u) must not have 0 in either value field, ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE (%u) should not have 0 in either value field. Ignored.",
criteria->ID, criteria->requiredType, dataType);
return false;
}
if (classRace.class_id && ((1 << (classRace.class_id-1)) & CLASSMASK_ALL_PLAYABLE) == 0)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE (%u) has non-existing class in value1 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE (%u) contains a non-existing class entry in value1 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, classRace.class_id);
return false;
}
if (classRace.race_id && ((1 << (classRace.race_id-1)) & RACEMASK_ALL_PLAYABLE) == 0)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE (%u) has non-existing race in value2 (%u), ignored.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_PLAYER_CLASS_RACE (%u) contains a non-existing race entry in value2 (%u), ignored.",
criteria->ID, criteria->requiredType, dataType, classRace.race_id);
return false;
}
@@ -276,13 +276,13 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria)
case ACHIEVEMENT_CRITERIA_DATA_TYPE_S_KNOWN_TITLE:
if (!sCharTitlesStore.LookupEntry(known_title.title_id))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_KNOWN_TITLE (%u) have unknown title_id in value1 (%u), ignore.",
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_KNOWN_TITLE (%u) contains an unknown title_id in value1 (%u), ignore.",
criteria->ID, criteria->requiredType, dataType, known_title.title_id);
return false;
}
return true;
default:
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) has data for non-supported data type (%u), ignored.", criteria->ID, criteria->requiredType, dataType);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) contains data of a non-supported data type (%u), ignored.", criteria->ID, criteria->requiredType, dataType);
return false;
}
}
@@ -377,14 +377,14 @@ bool AchievementCriteriaData::Meets(uint32 criteria_id, Player const* source, Un
Map* map = source->GetMap();
if (!map->IsDungeon())
{
- TC_LOG_ERROR("achievement", "Achievement system call ACHIEVEMENT_CRITERIA_DATA_TYPE_INSTANCE_SCRIPT (%u) for achievement criteria %u for non-dungeon/non-raid map %u",
+ TC_LOG_ERROR("achievement", "Achievement system call ACHIEVEMENT_CRITERIA_DATA_TYPE_INSTANCE_SCRIPT (%u) for achievement criteria %u in a non-dungeon/non-raid map %u",
dataType, criteria_id, map->GetId());
return false;
}
InstanceScript* instance = map->ToInstanceMap()->GetInstanceScript();
if (!instance)
{
- TC_LOG_ERROR("achievement", "Achievement system call ACHIEVEMENT_CRITERIA_DATA_TYPE_INSTANCE_SCRIPT (%u) for achievement criteria %u for map %u but map does not have a instance script",
+ TC_LOG_ERROR("achievement", "Achievement system call ACHIEVEMENT_CRITERIA_DATA_TYPE_INSTANCE_SCRIPT (%u) for achievement criteria %u in map %u, but the map does not have an instance script.",
dataType, criteria_id, map->GetId());
return false;
}
@@ -601,8 +601,8 @@ void AchievementMgr::LoadFromDB(PreparedQueryResult achievementResult, PreparedQ
AchievementCriteriaEntry const* criteria = sAchievementMgr->GetAchievementCriteria(id);
if (!criteria)
{
- // we will remove not existed criteria for all characters
- TC_LOG_ERROR("achievement", "Non-existing achievement criteria %u data removed from table `character_achievement_progress`.", id);
+ // Removing non-existing criteria data for all characters
+ TC_LOG_ERROR("achievement", "Non-existing achievement criteria %u data has been removed from the table `character_achievement_progress`.", id);
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_INVALID_ACHIEV_PROGRESS_CRITERIA);
@@ -1066,7 +1066,7 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
break;
}
- // std case: not exist in DBC, not triggered in code as result
+ // std case: does not exist in DBC, not triggered in code as result
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEALTH:
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_SPELLPOWER:
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_ARMOR:
@@ -1404,7 +1404,7 @@ void AchievementMgr::SetCriteriaProgress(AchievementCriteriaEntry const* entry,
if (entry->timeLimit)
{
- // has to exist else we wouldn't be here
+ // has to exist, otherwise we wouldn't be here
timedCompleted = IsCompletedCriteria(entry, sAchievementMgr->GetAchievement(entry->referredAchievement));
// Client expects this in packet
timeElapsed = entry->timeLimit - (timedIter->second/IN_MILLISECONDS);
@@ -1655,14 +1655,14 @@ bool AchievementMgr::CanUpdateCriteria(AchievementCriteriaEntry const* criteria,
if (!RequirementsSatisfied(criteria, achievement, miscValue1, miscValue2, unit))
{
- TC_LOG_TRACE("achievement", "CanUpdateCriteria: (Id: %u Type %s) Requirements not satisfied",
+ TC_LOG_TRACE("achievement", "CanUpdateCriteria: (Id: %u Type %s) Requirements have not been satisfied",
criteria->ID, AchievementGlobalMgr::GetCriteriaTypeString(criteria->requiredType));
return false;
}
if (!ConditionsSatisfied(criteria))
{
- TC_LOG_TRACE("achievement", "CanUpdateCriteria: (Id: %u Type %s) Conditions not satisfied",
+ TC_LOG_TRACE("achievement", "CanUpdateCriteria: (Id: %u Type %s) Conditions have not been satisfied",
criteria->ID, AchievementGlobalMgr::GetCriteriaTypeString(criteria->requiredType));
return false;
}
@@ -2273,7 +2273,7 @@ void AchievementGlobalMgr::LoadAchievementCriteriaList()
++loaded;
}
- TC_LOG_INFO("server.loading", ">> Loaded %u achievement criteria in %u ms", loaded, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u achievement criteria in %u ms.", loaded, GetMSTimeDiffToNow(oldMSTime));
}
void AchievementGlobalMgr::LoadAchievementReferenceList()
@@ -2302,7 +2302,7 @@ void AchievementGlobalMgr::LoadAchievementReferenceList()
if (AchievementEntry const* achievement = sAchievementMgr->GetAchievement(4539))
const_cast<AchievementEntry*>(achievement)->mapID = 631; // Correct map requirement (currently has Ulduar)
- TC_LOG_INFO("server.loading", ">> Loaded %u achievement references in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u achievement references in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
void AchievementGlobalMgr::LoadAchievementCriteriaData()
@@ -2330,7 +2330,7 @@ void AchievementGlobalMgr::LoadAchievementCriteriaData()
if (!criteria)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` has data for non-existing criteria (Entry: %u), ignore.", criteria_id);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` contains data for non-existing criteria (Entry: %u). Ignored.", criteria_id);
continue;
}
@@ -2340,7 +2340,7 @@ void AchievementGlobalMgr::LoadAchievementCriteriaData()
if (scriptName.length()) // not empty
{
if (dataType != ACHIEVEMENT_CRITERIA_DATA_TYPE_SCRIPT)
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` has ScriptName set for non-scripted data type (Entry: %u, type %u), useless data.", criteria_id, dataType);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` contains a ScriptName for non-scripted data type (Entry: %u, type %u), useless data.", criteria_id, dataType);
else
scriptId = sObjectMgr->GetScriptId(scriptName);
}
@@ -2396,7 +2396,7 @@ void AchievementGlobalMgr::LoadAchievementCriteriaData()
if (!achievement)
continue;
- // exist many achievements with this criteria, use at this moment hardcoded check to skil simple case
+ // There are many achievements with these criteria, use hardcoded check at this moment to pick a simple case
if (achievement->ID == 1282)
break;
@@ -2433,7 +2433,7 @@ void AchievementGlobalMgr::LoadAchievementCriteriaData()
}
if (!GetCriteriaDataSet(criteria) && !DisableMgr::IsDisabledFor(DISABLE_TYPE_ACHIEVEMENT_CRITERIA, entryId, NULL))
- TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` does not have expected data for criteria (Entry: %u Type: %u) for achievement %u.", criteria->ID, criteria->requiredType, criteria->referredAchievement);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` does not contain expected data for criteria (Entry: %u Type: %u) for achievement %u.", criteria->ID, criteria->requiredType, criteria->referredAchievement);
}
TC_LOG_INFO("server.loading", ">> Loaded %u additional achievement criteria data in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
@@ -2459,8 +2459,8 @@ void AchievementGlobalMgr::LoadCompletedAchievements()
const AchievementEntry* achievement = sAchievementMgr->GetAchievement(achievementId);
if (!achievement)
{
- // Remove non existent achievements from all characters
- TC_LOG_ERROR("achievement", "Non-existing achievement %u data removed from table `character_achievement`.", achievementId);
+ // Remove non-existing achievements from all characters
+ TC_LOG_ERROR("achievement", "Non-existing achievement %u data has been removed from the table `character_achievement`.", achievementId);
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_INVALID_ACHIEVMENT);
stmt->setUInt16(0, uint16(achievementId));
@@ -2473,7 +2473,7 @@ void AchievementGlobalMgr::LoadCompletedAchievements()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %lu realm first completed achievements in %u ms", (unsigned long)m_allCompletedAchievements.size(), GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %lu realm first completed achievements in %u ms.", (unsigned long)m_allCompletedAchievements.size(), GetMSTimeDiffToNow(oldMSTime));
}
void AchievementGlobalMgr::LoadRewards()
@@ -2500,7 +2500,7 @@ void AchievementGlobalMgr::LoadRewards()
AchievementEntry const* achievement = GetAchievement(entry);
if (!achievement)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` has wrong achievement (Entry: %u), ignored.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` contains a wrong achievement entry (Entry: %u), ignored.", entry);
continue;
}
@@ -2516,19 +2516,19 @@ void AchievementGlobalMgr::LoadRewards()
// must be title or mail at least
if (!reward.titleId[0] && !reward.titleId[1] && !reward.sender)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have title or item reward data, ignored.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not contain title or item reward data. Ignored.", entry);
continue;
}
if (achievement->requiredFaction == ACHIEVEMENT_FACTION_ANY && (!reward.titleId[0] ^ !reward.titleId[1]))
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has title (A: %u H: %u) for only one team.", entry, reward.titleId[0], reward.titleId[1]);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) contains the title (A: %u H: %u) for only one team.", entry, reward.titleId[0], reward.titleId[1]);
if (reward.titleId[0])
{
CharTitlesEntry const* titleEntry = sCharTitlesStore.LookupEntry(reward.titleId[0]);
if (!titleEntry)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has invalid title id (%u) in `title_A`, set to 0", entry, reward.titleId[0]);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) contains an invalid title id (%u) in `title_A`, set to 0", entry, reward.titleId[0]);
reward.titleId[0] = 0;
}
}
@@ -2538,7 +2538,7 @@ void AchievementGlobalMgr::LoadRewards()
CharTitlesEntry const* titleEntry = sCharTitlesStore.LookupEntry(reward.titleId[1]);
if (!titleEntry)
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has invalid title id (%u) in `title_H`, set to 0", entry, reward.titleId[1]);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) contains an invalid title id (%u) in `title_H`, set to 0", entry, reward.titleId[1]);
reward.titleId[1] = 0;
}
}
@@ -2548,41 +2548,41 @@ void AchievementGlobalMgr::LoadRewards()
{
if (!sObjectMgr->GetCreatureTemplate(reward.sender))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has invalid creature entry %u as sender, mail reward skipped.", entry, reward.sender);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) contains an invalid creature entry %u as sender, mail reward skipped.", entry, reward.sender);
reward.sender = 0;
}
}
else
{
if (reward.itemId)
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data but has item reward, item will not be rewarded.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data, but contains an item reward. Item will not be rewarded.", entry);
if (!reward.subject.empty())
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data but has mail subject.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data, but contains a mail subject.", entry);
if (!reward.text.empty())
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data but has mail text.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data, but contains mail text.", entry);
if (reward.mailTemplate)
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data but has mailTemplate.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) does not have sender data, but has a mailTemplate.", entry);
}
if (reward.mailTemplate)
{
if (!sMailTemplateStore.LookupEntry(reward.mailTemplate))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has invalid mailTemplate (%u).", entry, reward.mailTemplate);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) is using an invalid mailTemplate (%u).", entry, reward.mailTemplate);
reward.mailTemplate = 0;
}
else if (!reward.subject.empty() || !reward.text.empty())
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has mailTemplate (%u) and mail subject/text.", entry, reward.mailTemplate);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) is using mailTemplate (%u) and mail subject/text.", entry, reward.mailTemplate);
}
if (reward.itemId)
{
if (!sObjectMgr->GetItemTemplate(reward.itemId))
{
- TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) has invalid item id %u, reward mail will not contain item.", entry, reward.itemId);
+ TC_LOG_ERROR("sql.sql", "Table `achievement_reward` (Entry: %u) contains an invalid item id %u, reward mail will not contain the rewarded item.", entry, reward.itemId);
reward.itemId = 0;
}
}
@@ -2592,7 +2592,7 @@ void AchievementGlobalMgr::LoadRewards()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u achievement rewards in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u achievement rewards in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
void AchievementGlobalMgr::LoadRewardLocales()
@@ -2607,7 +2607,7 @@ void AchievementGlobalMgr::LoadRewardLocales()
if (!result)
{
- TC_LOG_INFO("server.loading", ">> Loaded 0 achievement reward locale strings. DB table `locales_achievement_reward` is empty");
+ TC_LOG_INFO("server.loading", ">> Loaded 0 achievement reward locale strings. DB table `locales_achievement_reward` is empty.");
return;
}
@@ -2619,7 +2619,7 @@ void AchievementGlobalMgr::LoadRewardLocales()
if (m_achievementRewards.find(entry) == m_achievementRewards.end())
{
- TC_LOG_ERROR("sql.sql", "Table `locales_achievement_reward` (Entry: %u) has locale strings for non-existing achievement reward.", entry);
+ TC_LOG_ERROR("sql.sql", "Table `locales_achievement_reward` (Entry: %u) contains locale strings for a non-existing achievement reward.", entry);
continue;
}
@@ -2634,7 +2634,7 @@ void AchievementGlobalMgr::LoadRewardLocales()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u achievement reward locale strings in %u ms", uint32(m_achievementRewardLocales.size()), GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u achievement reward locale strings in %u ms.", uint32(m_achievementRewardLocales.size()), GetMSTimeDiffToNow(oldMSTime));
}
AchievementEntry const* AchievementGlobalMgr::GetAchievement(uint32 achievementId) const
diff --git a/src/server/game/Battlefield/Battlefield.cpp b/src/server/game/Battlefield/Battlefield.cpp
index 34326d09e2f..e69d0f3085c 100644
--- a/src/server/game/Battlefield/Battlefield.cpp
+++ b/src/server/game/Battlefield/Battlefield.cpp
@@ -285,7 +285,7 @@ void Battlefield::InitStalker(uint32 entry, Position const& pos)
if (Creature* creature = SpawnCreature(entry, pos, TEAM_NEUTRAL))
StalkerGuid = creature->GetGUID();
else
- TC_LOG_ERROR("bg.battlefield", "Battlefield::InitStalker: could not spawn Stalker (Creature entry %u), zone messeges will be un-available", entry);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::InitStalker: Could not spawn Stalker (Creature entry %u), zone messages will be unavailable!", entry);
}
void Battlefield::KickAfkPlayers()
@@ -544,10 +544,10 @@ BfGraveyard* Battlefield::GetGraveyardById(uint32 id) const
if (BfGraveyard* graveyard = m_GraveyardList.at(id))
return graveyard;
else
- TC_LOG_ERROR("bg.battlefield", "Battlefield::GetGraveyardById Id:%u not existed", id);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::GetGraveyardById Id:%u does not exist.", id);
}
else
- TC_LOG_ERROR("bg.battlefield", "Battlefield::GetGraveyardById Id:%u cant be found", id);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::GetGraveyardById Id:%u could not be found.", id);
return NULL;
}
@@ -765,7 +765,7 @@ Creature* Battlefield::SpawnCreature(uint32 entry, float x, float y, float z, fl
Map* map = sMapMgr->CreateBaseMap(m_MapId);
if (!map)
{
- TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnCreature: Can't create creature entry: %u map not found", entry);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnCreature: Can't create creature entry: %u, map not found.", entry);
return nullptr;
}
@@ -782,7 +782,7 @@ Creature* Battlefield::SpawnCreature(uint32 entry, float x, float y, float z, fl
CreatureTemplate const* cinfo = sObjectMgr->GetCreatureTemplate(entry);
if (!cinfo)
{
- TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnCreature: entry %u does not exist.", entry);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnCreature: Entry %u does not exist.", entry);
return nullptr;
}
@@ -805,8 +805,8 @@ GameObject* Battlefield::SpawnGameObject(uint32 entry, float x, float y, float z
GameObject* go = new GameObject;
if (!go->Create(map->GenerateLowGuid<HighGuid::GameObject>(), entry, map, PHASEMASK_NORMAL, x, y, z, o, 0, 0, 0, 0, 100, GO_STATE_READY))
{
- TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnGameObject: Gameobject template %u not found in database! Battlefield not created!", entry);
- TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnGameObject: Cannot create gameobject template %u! Battlefield not created!", entry);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnGameObject: Gameobject template %u could not be found in the database! Battlefield has not been created!", entry);
+ TC_LOG_ERROR("bg.battlefield", "Battlefield::SpawnGameObject: Could not create gameobject template %u! Battlefield has not been created!", entry);
delete go;
return NULL;
}
@@ -907,7 +907,7 @@ bool BfCapturePoint::SetCapturePointData(GameObject* capturePoint)
GameObjectTemplate const* goinfo = capturePoint->GetGOInfo();
if (goinfo->type != GAMEOBJECT_TYPE_CAPTURE_POINT)
{
- TC_LOG_ERROR("misc", "OutdoorPvP: GO %u is not capture point!", capturePoint->GetEntry());
+ TC_LOG_ERROR("misc", "OutdoorPvP: GO %u is not a capture point!", capturePoint->GetEntry());
return false;
}
diff --git a/src/server/game/Battlegrounds/BattlegroundMgr.cpp b/src/server/game/Battlegrounds/BattlegroundMgr.cpp
index 062d4702d43..8942ca7a18e 100644
--- a/src/server/game/Battlegrounds/BattlegroundMgr.cpp
+++ b/src/server/game/Battlegrounds/BattlegroundMgr.cpp
@@ -536,7 +536,7 @@ void BattlegroundMgr::LoadBattlegroundTemplates()
BattlemasterListEntry const* bl = sBattlemasterListStore.LookupEntry(bgTypeId);
if (!bl)
{
- TC_LOG_ERROR("bg.battleground", "Battleground ID %u not found in BattlemasterList.dbc. Battleground not created.", bgTypeId);
+ TC_LOG_ERROR("bg.battleground", "Battleground ID %u could not be found in BattlemasterList.dbc. The battleground was not created.", bgTypeId);
continue;
}
@@ -554,14 +554,14 @@ void BattlegroundMgr::LoadBattlegroundTemplates()
if (bgTemplate.MaxPlayersPerTeam == 0 || bgTemplate.MinPlayersPerTeam > bgTemplate.MaxPlayersPerTeam)
{
- TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u has bad values for MinPlayersPerTeam (%u) and MaxPlayersPerTeam(%u)",
+ TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u contains bad values for MinPlayersPerTeam (%u) and MaxPlayersPerTeam(%u).",
bgTemplate.Id, bgTemplate.MinPlayersPerTeam, bgTemplate.MaxPlayersPerTeam);
continue;
}
if (bgTemplate.MinLevel == 0 || bgTemplate.MaxLevel == 0 || bgTemplate.MinLevel > bgTemplate.MaxLevel)
{
- TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u has bad values for MinLevel (%u) and MaxLevel (%u)",
+ TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u contains bad values for MinLevel (%u) and MaxLevel (%u).",
bgTemplate.Id, bgTemplate.MinLevel, bgTemplate.MaxLevel);
continue;
}
@@ -575,7 +575,7 @@ void BattlegroundMgr::LoadBattlegroundTemplates()
}
else
{
- TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u has non-existed WorldSafeLocs.dbc id %u in field `AllianceStartLoc`. BG not created.", bgTemplate.Id, startId);
+ TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u contains a non-existing WorldSafeLocs.dbc id %u in field `AllianceStartLoc`. BG not created.", bgTemplate.Id, startId);
continue;
}
@@ -586,7 +586,7 @@ void BattlegroundMgr::LoadBattlegroundTemplates()
}
else
{
- TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u has non-existed WorldSafeLocs.dbc id %u in field `HordeStartLoc`. BG not created.", bgTemplate.Id, startId);
+ TC_LOG_ERROR("sql.sql", "Table `battleground_template` for id %u contains a non-existing WorldSafeLocs.dbc id %u in field `HordeStartLoc`. BG not created.", bgTemplate.Id, startId);
continue;
}
}
@@ -788,7 +788,7 @@ BattlegroundTypeId BattlegroundMgr::BGTemplateId(BattlegroundQueueTypeId bgQueue
case BATTLEGROUND_QUEUE_5v5:
return BATTLEGROUND_AA;
default:
- return BattlegroundTypeId(0); // used for unknown template (it existed and do nothing)
+ return BattlegroundTypeId(0); // used for unknown template (it exists and does nothing)
}
}
@@ -892,7 +892,7 @@ void BattlegroundMgr::LoadBattleMastersEntry()
uint32 bgTypeId = fields[1].GetUInt32();
if (!sBattlemasterListStore.LookupEntry(bgTypeId))
{
- TC_LOG_ERROR("sql.sql", "Table `battlemaster_entry` contain entry %u for not existed battleground type %u, ignored.", entry, bgTypeId);
+ TC_LOG_ERROR("sql.sql", "Table `battlemaster_entry` contains entry %u for a non-existing battleground type %u, ignored.", entry, bgTypeId);
continue;
}
@@ -912,7 +912,7 @@ void BattlegroundMgr::CheckBattleMasters()
{
if ((itr->second.npcflag & UNIT_NPC_FLAG_BATTLEMASTER) && mBattleMastersMap.find(itr->second.Entry) == mBattleMastersMap.end())
{
- TC_LOG_ERROR("sql.sql", "CreatureTemplate (Entry: %u) has UNIT_NPC_FLAG_BATTLEMASTER but no data in `battlemaster_entry` table. Removing flag!", itr->second.Entry);
+ TC_LOG_ERROR("sql.sql", "Creature_Template Entry: %u has UNIT_NPC_FLAG_BATTLEMASTER, but no data in the `battlemaster_entry` table. Removing flag.", itr->second.Entry);
const_cast<CreatureTemplate*>(&itr->second)->npcflag &= ~UNIT_NPC_FLAG_BATTLEMASTER;
}
}
diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp
index 626bcacbf27..e52106a8efe 100644
--- a/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp
+++ b/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp
@@ -171,7 +171,7 @@ void BattlegroundEY::CheckSomeoneJoinedPoint()
Player* player = ObjectAccessor::FindPlayer(m_PlayersNearPoint[EY_POINTS_MAX][j]);
if (!player)
{
- TC_LOG_ERROR("bg.battleground", "BattlegroundEY:CheckSomeoneJoinedPoint: Player (%s) not found!", m_PlayersNearPoint[EY_POINTS_MAX][j].ToString().c_str());
+ TC_LOG_ERROR("bg.battleground", "BattlegroundEY:CheckSomeoneJoinedPoint: Player (%s) could not be found!", m_PlayersNearPoint[EY_POINTS_MAX][j].ToString().c_str());
++j;
continue;
}
@@ -212,8 +212,8 @@ void BattlegroundEY::CheckSomeoneLeftPoint()
Player* player = ObjectAccessor::FindPlayer(m_PlayersNearPoint[i][j]);
if (!player)
{
- TC_LOG_ERROR("bg.battleground", "BattlegroundEY:CheckSomeoneLeftPoint Player (%s) not found!", m_PlayersNearPoint[i][j].ToString().c_str());
- //move not existed player to "free space" - this will cause many error showing in log, but it is a very important bug
+ TC_LOG_ERROR("bg.battleground", "BattlegroundEY:CheckSomeoneLeftPoint Player (%s) could not be found!", m_PlayersNearPoint[i][j].ToString().c_str());
+ //move non-existing players to "free space" - this will cause many errors showing in log, but it is a very important bug
m_PlayersNearPoint[EY_POINTS_MAX].push_back(m_PlayersNearPoint[i][j]);
m_PlayersNearPoint[i].erase(m_PlayersNearPoint[i].begin() + j);
continue;
@@ -498,7 +498,7 @@ bool BattlegroundEY::SetupBattleground()
|| !AddObject(BG_EY_OBJECT_TOWER_CAP_MAGE_TOWER, BG_OBJECT_HU_TOWER_CAP_EY_ENTRY, 2282.121582f, 1760.006958f, 1189.707153f, 1.919862f, 0, 0, 0.819152f, 0.573576f, RESPAWN_ONE_DAY)
)
{
- TC_LOG_ERROR("sql.sql", "BatteGroundEY: Failed to spawn some object Battleground not created!");
+ TC_LOG_ERROR("sql.sql", "BatteGroundEY: Failed to spawn some objects. The battleground was not created.");
return false;
}
@@ -515,21 +515,21 @@ bool BattlegroundEY::SetupBattleground()
|| !AddObject(BG_EY_OBJECT_SPEEDBUFF_FEL_REAVER + i * 3 + 1, Buff_Entries[1], at->x, at->y, at->z, 0.907571f, 0, 0, 0.438371f, 0.898794f, RESPAWN_ONE_DAY)
|| !AddObject(BG_EY_OBJECT_SPEEDBUFF_FEL_REAVER + i * 3 + 2, Buff_Entries[2], at->x, at->y, at->z, 0.907571f, 0, 0, 0.438371f, 0.898794f, RESPAWN_ONE_DAY)
)
- TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Cannot spawn buff");
+ TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Could not spawn Speedbuff Fel Reaver.");
}
WorldSafeLocsEntry const* sg = NULL;
sg = sWorldSafeLocsStore.LookupEntry(EY_GRAVEYARD_MAIN_ALLIANCE);
if (!sg || !AddSpiritGuide(EY_SPIRIT_MAIN_ALLIANCE, sg->x, sg->y, sg->z, 3.124139f, TEAM_ALLIANCE))
{
- TC_LOG_ERROR("sql.sql", "BatteGroundEY: Failed to spawn spirit guide! Battleground not created!");
+ TC_LOG_ERROR("sql.sql", "BatteGroundEY: Failed to spawn spirit guide. The battleground was not created.");
return false;
}
sg = sWorldSafeLocsStore.LookupEntry(EY_GRAVEYARD_MAIN_HORDE);
if (!sg || !AddSpiritGuide(EY_SPIRIT_MAIN_HORDE, sg->x, sg->y, sg->z, 3.193953f, TEAM_HORDE))
{
- TC_LOG_ERROR("sql.sql", "BatteGroundEY: Failed to spawn spirit guide! Battleground not created!");
+ TC_LOG_ERROR("sql.sql", "BatteGroundEY: Failed to spawn spirit guide. The battleground was not created.");
return false;
}
@@ -595,7 +595,7 @@ void BattlegroundEY::RespawnFlagAfterDrop()
if (obj)
obj->Delete();
else
- TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Unknown dropped flag (%s)", GetDroppedFlagGUID().ToString().c_str());
+ TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Unknown dropped flag (%s).", GetDroppedFlagGUID().ToString().c_str());
SetDroppedFlagGUID(ObjectGuid::Empty);
}
@@ -767,7 +767,7 @@ void BattlegroundEY::EventTeamCapturedPoint(Player* player, uint32 Point)
WorldSafeLocsEntry const* sg = NULL;
sg = sWorldSafeLocsStore.LookupEntry(m_CapturingPointTypes[Point].GraveYardId);
if (!sg || !AddSpiritGuide(Point, sg->x, sg->y, sg->z, 3.124139f, GetTeamIndexByTeamId(Team)))
- TC_LOG_ERROR("bg.battleground", "BatteGroundEY: Failed to spawn spirit guide! point: %u, team: %u, graveyard_id: %u",
+ TC_LOG_ERROR("bg.battleground", "BatteGroundEY: Failed to spawn spirit guide. point: %u, team: %u, graveyard_id: %u",
Point, Team, m_CapturingPointTypes[Point].GraveYardId);
// SpawnBGCreature(Point, RESPAWN_IMMEDIATELY);
@@ -917,7 +917,7 @@ WorldSafeLocsEntry const* BattlegroundEY::GetClosestGraveYard(Player* player)
if (!entry)
{
- TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Not found the main team graveyard. Graveyard system isn't working!");
+ TC_LOG_ERROR("bg.battleground", "BattlegroundEY: The main team graveyard could not be found. The graveyard system will not be operational!");
return NULL;
}
@@ -934,7 +934,7 @@ WorldSafeLocsEntry const* BattlegroundEY::GetClosestGraveYard(Player* player)
{
entry = sWorldSafeLocsStore.LookupEntry(m_CapturingPointTypes[i].GraveYardId);
if (!entry)
- TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Not found graveyard: %u", m_CapturingPointTypes[i].GraveYardId);
+ TC_LOG_ERROR("bg.battleground", "BattlegroundEY: Graveyard %u could not be found.", m_CapturingPointTypes[i].GraveYardId);
else
{
distance = (entry->x - plr_x)*(entry->x - plr_x) + (entry->y - plr_y)*(entry->y - plr_y) + (entry->z - plr_z)*(entry->z - plr_z);
diff --git a/src/server/game/Chat/Chat.cpp b/src/server/game/Chat/Chat.cpp
index 8fe0810f3b9..aa0f6ce09fc 100644
--- a/src/server/game/Chat/Chat.cpp
+++ b/src/server/game/Chat/Chat.cpp
@@ -360,7 +360,7 @@ bool ChatHandler::SetDataForCommandInTable(std::vector<ChatCommand>& table, char
// expected subcommand by full name DB content
else if (*text)
{
- TC_LOG_ERROR("sql.sql", "Table `command` have unexpected subcommand '%s' in command '%s', skip.", text, fullcommand.c_str());
+ TC_LOG_ERROR("sql.sql", "Table `command` contains an unexpected subcommand '%s' in command '%s', skipped.", text, fullcommand.c_str());
return false;
}
@@ -376,9 +376,9 @@ bool ChatHandler::SetDataForCommandInTable(std::vector<ChatCommand>& table, char
if (!cmd.empty())
{
if (&table == &getCommandTable())
- TC_LOG_ERROR("sql.sql", "Table `command` have not existed command '%s', skip.", cmd.c_str());
+ TC_LOG_ERROR("sql.sql", "Table `command` contains a non-existing command '%s', skipped.", cmd.c_str());
else
- TC_LOG_ERROR("sql.sql", "Table `command` have not existed subcommand '%s' in command '%s', skip.", cmd.c_str(), fullcommand.c_str());
+ TC_LOG_ERROR("sql.sql", "Table `command` contains a non-existing subcommand '%s' in command '%s', skipped.", cmd.c_str(), fullcommand.c_str());
}
return false;
@@ -486,7 +486,7 @@ bool ChatHandler::ShowHelpForSubCommands(std::vector<ChatCommand> const& table,
std::string list;
for (uint32 i = 0; i < table.size(); ++i)
{
- // must be available (ignore handler existence for show command with possible available subcommands)
+ // must be available (ignore handler existence to show command with possible available subcommands)
if (!isAvailable(table[i]))
continue;
@@ -525,7 +525,7 @@ bool ChatHandler::ShowHelpForCommand(std::vector<ChatCommand> const& table, cons
{
for (uint32 i = 0; i < table.size(); ++i)
{
- // must be available (ignore handler existence for show command with possible available subcommands)
+ // must be available (ignore handler existence to show command with possible available subcommands)
if (!isAvailable(table[i]))
continue;
@@ -555,7 +555,7 @@ bool ChatHandler::ShowHelpForCommand(std::vector<ChatCommand> const& table, cons
{
for (uint32 i = 0; i < table.size(); ++i)
{
- // must be available (ignore handler existence for show command with possible available subcommands)
+ // must be available (ignore handler existence to show command with possible available subcommands)
if (!isAvailable(table[i]))
continue;
@@ -1100,7 +1100,7 @@ bool ChatHandler::extractPlayerTarget(char* args, Player** player, ObjectGuid* p
*player_name = pl ? pl->GetName() : "";
}
- // some from req. data must be provided (note: name is empty if player not exist)
+ // some from req. data must be provided (note: name is empty if player does not exist)
if ((!player || !*player) && (!player_guid || !*player_guid) && (!player_name || player_name->empty()))
{
SendSysMessage(LANG_PLAYER_NOT_FOUND);
diff --git a/src/server/game/Entities/Corpse/Corpse.cpp b/src/server/game/Entities/Corpse/Corpse.cpp
index 8f700cc636f..22bb9bca712 100644
--- a/src/server/game/Entities/Corpse/Corpse.cpp
+++ b/src/server/game/Entities/Corpse/Corpse.cpp
@@ -147,7 +147,7 @@ bool Corpse::LoadCorpseFromDB(ObjectGuid::LowType guid, Field* fields)
SetObjectScale(1.0f);
SetUInt32Value(CORPSE_FIELD_DISPLAY_ID, fields[5].GetUInt32());
- _LoadIntoDataField(fields[6].GetCString(), CORPSE_FIELD_ITEM, EQUIPMENT_SLOT_END);
+ _LoadIntoDataField(fields[6].GetString(), CORPSE_FIELD_ITEM, EQUIPMENT_SLOT_END);
SetUInt32Value(CORPSE_FIELD_BYTES_1, fields[7].GetUInt32());
SetUInt32Value(CORPSE_FIELD_BYTES_2, fields[8].GetUInt32());
SetUInt32Value(CORPSE_FIELD_GUILD, fields[9].GetUInt32());
diff --git a/src/server/game/Entities/Item/Item.cpp b/src/server/game/Entities/Item/Item.cpp
index 70fa4714547..773d5a05772 100644
--- a/src/server/game/Entities/Item/Item.cpp
+++ b/src/server/game/Entities/Item/Item.cpp
@@ -447,8 +447,7 @@ bool Item::LoadFromDB(ObjectGuid::LowType guid, ObjectGuid owner_guid, Field* fi
need_save = true;
}
- std::string enchants = fields[6].GetString();
- _LoadIntoDataField(enchants.c_str(), ITEM_FIELD_ENCHANTMENT_1_1, MAX_ENCHANTMENT_SLOT * MAX_ENCHANTMENT_OFFSET);
+ _LoadIntoDataField(fields[6].GetString(), ITEM_FIELD_ENCHANTMENT_1_1, MAX_ENCHANTMENT_SLOT * MAX_ENCHANTMENT_OFFSET);
SetInt32Value(ITEM_FIELD_RANDOM_PROPERTIES_ID, fields[7].GetInt16());
// recalculate suffix factor
if (GetItemRandomPropertyId() < 0)
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp
index e8163a7c0fb..cbf29980057 100644
--- a/src/server/game/Entities/Player/Player.cpp
+++ b/src/server/game/Entities/Player/Player.cpp
@@ -213,7 +213,7 @@ void PlayerTaxi::AppendTaximaskTo(ByteBuffer& data, bool all)
if (all)
{
for (uint8 i = 0; i < TaxiMaskSize; ++i)
- data << uint32(sTaxiNodesMask[i]); // all existed nodes
+ data << uint32(sTaxiNodesMask[i]); // all existing nodes
}
else
{
@@ -605,7 +605,7 @@ bool Player::Create(ObjectGuid::LowType guidlow, CharacterCreateInfo* createInfo
PlayerInfo const* info = sObjectMgr->GetPlayerInfo(createInfo->Race, createInfo->Class);
if (!info)
{
- TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking-attempt: Account %u tried creating a character named '%s' with an invalid race/class pair (%u/%u) - refusing to do so.",
+ TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking attempt: Account %u tried to create a character named '%s' with an invalid race/class pair (%u/%u) - refusing to do so.",
GetSession()->GetAccountId(), m_name.c_str(), createInfo->Race, createInfo->Class);
return false;
}
@@ -618,7 +618,7 @@ bool Player::Create(ObjectGuid::LowType guidlow, CharacterCreateInfo* createInfo
ChrClassesEntry const* cEntry = sChrClassesStore.LookupEntry(createInfo->Class);
if (!cEntry)
{
- TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking-attempt: Account %u tried creating a character named '%s' with an invalid character class (%u) - refusing to do so (wrong DBC-files?)",
+ TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking attempt: Account %u tried to create a character named '%s' with an invalid character class (%u) - refusing to do so (wrong DBC-files?)",
GetSession()->GetAccountId(), m_name.c_str(), createInfo->Class);
return false;
}
@@ -633,14 +633,14 @@ bool Player::Create(ObjectGuid::LowType guidlow, CharacterCreateInfo* createInfo
if (!IsValidGender(createInfo->Gender))
{
- TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking-attempt: Account %u tried creating a character named '%s' with an invalid gender (%u) - refusing to do so",
+ TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking attempt: Account %u tried to create a character named '%s' with an invalid gender (%u) - refusing to do so",
GetSession()->GetAccountId(), m_name.c_str(), createInfo->Gender);
return false;
}
if (!ValidateAppearance(createInfo->Race, createInfo->Class, createInfo->Gender, createInfo->HairStyle, createInfo->HairColor, createInfo->Face, createInfo->FacialHair, createInfo->Skin, true))
{
- TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking-attempt: Account %u tried creating a character named '%s' with invalid appearance attributes - refusing to do so",
+ TC_LOG_ERROR("entities.player", "Player::Create: Possible hacking attempt: Account %u tried to create a character named '%s' with invalid appearance attributes - refusing to do so",
GetSession()->GetAccountId(), m_name.c_str());
return false;
}
@@ -962,9 +962,9 @@ uint32 Player::EnvironmentalDamage(EnviromentalDamage type, uint32 damage)
if (!IsAlive())
{
- if (type == DAMAGE_FALL) // DealDamage not apply item durability loss at self damage
+ if (type == DAMAGE_FALL) // DealDamage does not apply item durability loss from self-induced damage.
{
- TC_LOG_DEBUG("entities.player", "We are fall to death, loosing 10 percents durability");
+ TC_LOG_DEBUG("entities.player", "You have died from falling, losing 10 percent total armor durability.");
DurabilityLossAll(0.10f, false);
// durability lost message
WorldPacket data2(SMSG_DURABILITY_DAMAGE_DEATH, 0);
@@ -1546,7 +1546,7 @@ void Player::setDeathState(DeathState s)
{
if (!cur)
{
- TC_LOG_ERROR("entities.player", "setDeathState: attempt to kill a dead player %s(%d)", GetName().c_str(), GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "setDeathState: Attempted to kill a dead player %s(%d)", GetName().c_str(), GetGUID().GetCounter());
return;
}
@@ -1819,7 +1819,7 @@ bool Player::TeleportTo(uint32 mapid, float x, float y, float z, float orientati
// client without expansion support
if (GetSession()->Expansion() < mEntry->Expansion())
{
- TC_LOG_DEBUG("maps", "Player %s using client without required expansion tried teleport to non accessible map %u", GetName().c_str(), mapid);
+ TC_LOG_DEBUG("maps", "Player %s using client without required expansion tried teleporting to non accessible map %u", GetName().c_str(), mapid);
if (Transport* transport = GetTransport())
{
@@ -3159,12 +3159,12 @@ bool Player::AddTalent(uint32 spellId, uint8 spec, bool learning)
// do character spell book cleanup (all characters)
if (!IsInWorld() && !learning) // spell load case
{
- TC_LOG_ERROR("spells", "Player::addSpell: Non-existed in SpellStore spell #%u request, deleting for all characters in `character_spell`.", spellId);
+ TC_LOG_ERROR("spells", "Player::addSpell: Non-existing spell #%u requested from SpellStore. Deleting spell for all characters in `character_spell`.", spellId);
DeleteSpellFromAllPlayers(spellId);
}
else
- TC_LOG_ERROR("spells", "Player::addSpell: Non-existed in SpellStore spell #%u request.", spellId);
+ TC_LOG_ERROR("spells", "Player::addSpell: Non-existing spell #%u requested from SpellStore.", spellId);
return false;
}
@@ -3174,12 +3174,12 @@ bool Player::AddTalent(uint32 spellId, uint8 spec, bool learning)
// do character spell book cleanup (all characters)
if (!IsInWorld() && !learning) // spell load case
{
- TC_LOG_ERROR("spells", "Player::addTalent: Broken spell #%u learning not allowed, deleting for all characters in `character_talent`.", spellId);
+ TC_LOG_ERROR("spells", "Player::addTalent: Broken spell #%u, learning this spell is not allowed. Deleting this spell for all characters in `character_talent`.", spellId);
DeleteSpellFromAllPlayers(spellId);
}
else
- TC_LOG_ERROR("spells", "Player::addTalent: Broken spell #%u learning not allowed.", spellId);
+ TC_LOG_ERROR("spells", "Player::addTalent: Broken spell #%u, learning this spell is not allowed.", spellId);
return false;
}
@@ -3224,12 +3224,12 @@ bool Player::AddSpell(uint32 spellId, bool active, bool learning, bool dependent
// do character spell book cleanup (all characters)
if (!IsInWorld() && !learning) // spell load case
{
- TC_LOG_ERROR("spells", "Player::addSpell: Non-existed in SpellStore spell #%u request, deleting for all characters in `character_spell`.", spellId);
+ TC_LOG_ERROR("spells", "Player::addSpell: Non-existing spell #%u requested from SpellStore. Deleting for all characters in `character_spell`.", spellId);
DeleteSpellFromAllPlayers(spellId);
}
else
- TC_LOG_ERROR("spells", "Player::addSpell: Non-existed in SpellStore spell #%u request.", spellId);
+ TC_LOG_ERROR("spells", "Player::addSpell: Non-existing spell #%u requested from SpellStore.", spellId);
return false;
}
@@ -3239,12 +3239,12 @@ bool Player::AddSpell(uint32 spellId, bool active, bool learning, bool dependent
// do character spell book cleanup (all characters)
if (!IsInWorld() && !learning) // spell load case
{
- TC_LOG_ERROR("spells", "Player::addSpell: Broken spell #%u learning not allowed, deleting for all characters in `character_spell`.", spellId);
+ TC_LOG_ERROR("spells", "Player::addSpell: Broken spell #%u, learning this spell is not allowed. Deleting this spell for all characters in `character_spell`.", spellId);
DeleteSpellFromAllPlayers(spellId);
}
else
- TC_LOG_ERROR("spells", "Player::addSpell: Broken spell #%u learning not allowed.", spellId);
+ TC_LOG_ERROR("spells", "Player::addSpell: Broken spell #%u, learning this spell is not allowed.", spellId);
return false;
}
@@ -3961,7 +3961,7 @@ bool Player::ResetTalents(bool no_cost)
for (int8 rank = MAX_TALENT_RANK-1; rank >= 0; --rank)
{
- // skip non-existant talent ranks
+ // skip non-existing talent ranks
if (talentInfo->RankID[rank] == 0)
continue;
const SpellInfo* _spellEntry = sSpellMgr->GetSpellInfo(talentInfo->RankID[rank]);
@@ -4812,7 +4812,7 @@ void Player::OfflineResurrect(ObjectGuid const& guid, SQLTransaction& trans)
Corpse* Player::CreateCorpse()
{
- // prevent existence 2 corpse for player
+ // prevent the existence of 2 corpses for one player
SpawnCorpseBones();
uint32 _pb, _pb2, _cfb1, _cfb2;
@@ -5037,7 +5037,7 @@ uint32 Player::DurabilityRepair(uint16 pos, bool cost, float discountMod, bool g
DurabilityCostsEntry const* dcost = sDurabilityCostsStore.LookupEntry(ditemProto->ItemLevel);
if (!dcost)
{
- TC_LOG_ERROR("entities.player.items", "RepairDurability: Wrong item lvl %u", ditemProto->ItemLevel);
+ TC_LOG_ERROR("entities.player.items", "RepairDurability: Wrong item level %u", ditemProto->ItemLevel);
return TotalCost;
}
@@ -5061,7 +5061,7 @@ uint32 Player::DurabilityRepair(uint16 pos, bool cost, float discountMod, bool g
{
if (GetGuildId() == 0)
{
- TC_LOG_DEBUG("entities.player.items", "You are not member of a guild");
+ TC_LOG_DEBUG("entities.player.items", "You are not member of a guild.");
return TotalCost;
}
@@ -5076,7 +5076,7 @@ uint32 Player::DurabilityRepair(uint16 pos, bool cost, float discountMod, bool g
}
else if (!HasEnoughMoney(costs))
{
- TC_LOG_DEBUG("entities.player.items", "You do not have enough money");
+ TC_LOG_DEBUG("entities.player.items", "You do not have enough money.");
return TotalCost;
}
else
@@ -5286,7 +5286,7 @@ void Player::HandleBaseModValue(BaseModGroup modGroup, BaseModType modType, floa
{
if (modGroup >= BASEMOD_END || modType >= MOD_END)
{
- TC_LOG_ERROR("spells", "ERROR in HandleBaseModValue(): non existed BaseModGroup of wrong BaseModType!");
+ TC_LOG_ERROR("spells", "ERROR in HandleBaseModValue(): Non-existing BaseModGroup or wrong BaseModType!");
return;
}
@@ -5312,7 +5312,7 @@ float Player::GetBaseModValue(BaseModGroup modGroup, BaseModType modType) const
{
if (modGroup >= BASEMOD_END || modType >= MOD_END)
{
- TC_LOG_ERROR("spells", "trial to access non existed BaseModGroup or wrong BaseModType!");
+ TC_LOG_ERROR("spells", "Attempt to access non-existing BaseModGroup or wrong BaseModType!");
return 0.0f;
}
@@ -5326,7 +5326,7 @@ float Player::GetTotalBaseModValue(BaseModGroup modGroup) const
{
if (modGroup >= BASEMOD_END)
{
- TC_LOG_ERROR("spells", "wrong BaseModGroup in GetTotalBaseModValue()!");
+ TC_LOG_ERROR("spells", "Wrong BaseModGroup in GetTotalBaseModValue()!");
return 0.0f;
}
@@ -6264,20 +6264,20 @@ bool Player::IsActionButtonDataValid(uint8 button, uint32 action, uint8 type)
case ACTION_BUTTON_SPELL:
if (!sSpellMgr->GetSpellInfo(action))
{
- TC_LOG_DEBUG("entities.player", "Spell action %u not added into button %u for player %s (GUID: %u): spell not exist", action, button, GetName().c_str(), GetGUID().GetCounter());
+ TC_LOG_DEBUG("entities.player", "Spell action %u not added into button %u for player %s (GUID: %u): spell does not exist", action, button, GetName().c_str(), GetGUID().GetCounter());
return false;
}
if (!HasSpell(action))
{
- TC_LOG_DEBUG("entities.player", "Spell action %u not added into button %u for player %s (GUID: %u): player don't known this spell", action, button, GetName().c_str(), GetGUID().GetCounter());
+ TC_LOG_DEBUG("entities.player", "Spell action %u not added into button %u for player %s (GUID: %u): player does not know this spell", action, button, GetName().c_str(), GetGUID().GetCounter());
return false;
}
break;
case ACTION_BUTTON_ITEM:
if (!sObjectMgr->GetItemTemplate(action))
{
- TC_LOG_DEBUG("entities.player", "Item action %u not added into button %u for player %s (GUID: %u): item not exist", action, button, GetName().c_str(), GetGUID().GetCounter());
+ TC_LOG_DEBUG("entities.player", "Item action %u not added into button %u for player %s (GUID: %u): item does not exist", action, button, GetName().c_str(), GetGUID().GetCounter());
return false;
}
break;
@@ -6299,7 +6299,7 @@ ActionButton* Player::addActionButton(uint8 button, uint32 action, uint8 type)
if (!IsActionButtonDataValid(button, action, type))
return NULL;
- // it create new button (NEW state) if need or return existed
+ // it create new button (NEW state) if need or return existing
ActionButton& ab = m_actionButtons[button];
// set data and update to CHANGED if not NEW
@@ -7945,7 +7945,7 @@ void Player::CastItemCombatSpell(Unit* target, WeaponAttackType attType, uint32
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellData.SpellId);
if (!spellInfo)
{
- TC_LOG_ERROR("entities.player.items", "WORLD: unknown Item spellid %i", spellData.SpellId);
+ TC_LOG_ERROR("entities.player.items", "WORLD: Unknown item spellid %i", spellData.SpellId);
continue;
}
@@ -8045,7 +8045,7 @@ void Player::CastItemUseSpell(Item* item, SpellCastTargets const& targets, uint8
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(learn_spell_id);
if (!spellInfo)
{
- TC_LOG_ERROR("entities.player", "Player::CastItemUseSpell: Item (Entry: %u) in have wrong spell id %u, ignoring ", proto->ItemId, learn_spell_id);
+ TC_LOG_ERROR("entities.player", "Player::CastItemUseSpell: Item (Entry: %u) has wrong spell id %u, ignoring.", proto->ItemId, learn_spell_id);
SendEquipError(EQUIP_ERR_NONE, item, NULL);
return;
}
@@ -8074,7 +8074,7 @@ void Player::CastItemUseSpell(Item* item, SpellCastTargets const& targets, uint8
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellData.SpellId);
if (!spellInfo)
{
- TC_LOG_ERROR("entities.player", "Player::CastItemUseSpell: Item (Entry: %u) in have wrong spell id %u, ignoring", proto->ItemId, spellData.SpellId);
+ TC_LOG_ERROR("entities.player", "Player::CastItemUseSpell: Item (Entry: %u) has wrong spell id %u, ignoring.", proto->ItemId, spellData.SpellId);
continue;
}
@@ -8101,7 +8101,7 @@ void Player::CastItemUseSpell(Item* item, SpellCastTargets const& targets, uint8
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(pEnchant->spellid[s]);
if (!spellInfo)
{
- TC_LOG_ERROR("entities.player", "Player::CastItemUseSpell Enchant %i, cast unknown spell %i", pEnchant->ID, pEnchant->spellid[s]);
+ TC_LOG_ERROR("entities.player", "Player::CastItemUseSpell Enchant %i casts unknown spell %i.", pEnchant->ID, pEnchant->spellid[s]);
continue;
}
@@ -9357,7 +9357,7 @@ uint32 Player::GetXPRestBonus(uint32 xp)
SetRestBonus(GetRestBonus() - rested_bonus);
- TC_LOG_DEBUG("entities.player", "GetXPRestBonus: Player %s (%u) gain %u xp (+%u Rested Bonus). Rested points=%f", GetName().c_str(), GetGUID().GetCounter(), xp+rested_bonus, rested_bonus, GetRestBonus());
+ TC_LOG_DEBUG("entities.player", "GetXPRestBonus: Player %s (%u) gains %u xp (+%u Rested Bonus). Rested points=%f", GetName().c_str(), GetGUID().GetCounter(), xp+rested_bonus, rested_bonus, GetRestBonus());
return rested_bonus;
}
@@ -9389,7 +9389,7 @@ void Player::ResetPetTalents()
CharmInfo* charmInfo = pet->GetCharmInfo();
if (!charmInfo)
{
- TC_LOG_ERROR("entities.player", "Object (GUID: %u TypeId: %u) is considered pet-like but doesn't have a charminfo!", pet->GetGUID().GetCounter(), pet->GetTypeId());
+ TC_LOG_ERROR("entities.player", "Object (GUID: %u TypeId: %u) is considered pet-like, but doesn't have charm info!", pet->GetGUID().GetCounter(), pet->GetTypeId());
return;
}
pet->resetTalents();
@@ -10306,7 +10306,7 @@ InventoryResult Player::CanStoreItem_InBag(uint8 bag, ItemPosCountVec &dest, Ite
if (bag == skip_bag)
return EQUIP_ERR_ITEM_DOESNT_GO_INTO_BAG;
- // skip not existed bag or self targeted bag
+ // skip non-existing bag or self targeted bag
Bag* pBag = GetBagByPos(bag);
if (!pBag || pBag == pSrcItem)
return EQUIP_ERR_ITEM_DOESNT_GO_INTO_BAG;
@@ -11291,7 +11291,7 @@ InventoryResult Player::CanUnequipItem(uint16 pos, bool swap) const
Item* pItem = GetItemByPos(pos);
- // Applied only to existed equipped item
+ // Applied only to existing equipped item
if (!pItem)
return EQUIP_ERR_OK;
@@ -11972,7 +11972,7 @@ Item* Player::EquipItem(uint16 pos, Item* pItem, bool update)
SpellInfo const* spellProto = sSpellMgr->GetSpellInfo(cooldownSpell);
if (!spellProto)
- TC_LOG_ERROR("entities.player", "Weapon switch cooldown spell %u couldn't be found in Spell.dbc", cooldownSpell);
+ TC_LOG_ERROR("entities.player", "Weapon switch cooldown spell %u could not be found in Spell.dbc", cooldownSpell);
else
{
m_weaponChangeTimer = spellProto->StartRecoveryTime;
@@ -12220,7 +12220,7 @@ void Player::MoveItemToInventory(ItemPosCountVec const& dest, Item* pItem, bool
// store item
Item* pLastItem = StoreItem(dest, pItem, update);
- // only set if not merged to existed stack (pItem can be deleted already but we can compare pointers any way)
+ // only set if not merged to existing stack (pItem can be deleted already but we can compare pointers any way)
if (pLastItem == pItem)
{
// update owner for last item (this can be original item with wrong owner
@@ -12666,7 +12666,7 @@ void Player::SplitItem(uint16 src, uint16 dst, uint32 count)
return;
}
- // not let split more existed items (can be only at cheating)
+ // not let split more existing items (can be only at cheating)
if (pSrcItem->GetCount() < count)
{
SendEquipError(EQUIP_ERR_TRIED_TO_SPLIT_MORE_THAN_COUNT, pSrcItem, NULL);
@@ -13962,7 +13962,7 @@ void Player::PrepareGossipMenu(WorldObject* source, uint32 menuId /*= 0*/, bool
VendorItemData const* vendorItems = creature->GetVendorItems();
if (!vendorItems || vendorItems->Empty())
{
- TC_LOG_ERROR("sql.sql", "Creature %s (Entry: %u GUID: %u DB GUID: %u) has UNIT_NPC_FLAG_VENDOR set but has an empty trading item list.", creature->GetName().c_str(), creature->GetEntry(), creature->GetGUID().GetCounter(), creature->GetSpawnId());
+ TC_LOG_ERROR("sql.sql", "Creature %s (Entry: %u GUID: %u DB GUID: %u) has UNIT_NPC_FLAG_VENDOR set, but has an empty trading item list.", creature->GetName().c_str(), creature->GetEntry(), creature->GetGUID().GetCounter(), creature->GetSpawnId());
canTalk = false;
}
break;
@@ -13996,7 +13996,7 @@ void Player::PrepareGossipMenu(WorldObject* source, uint32 menuId /*= 0*/, bool
break;
case GOSSIP_OPTION_TRAINER:
if (getClass() != creature->GetCreatureTemplate()->trainer_class && creature->GetCreatureTemplate()->trainer_type == TRAINER_TYPE_CLASS)
- TC_LOG_ERROR("sql.sql", "GOSSIP_OPTION_TRAINER:: Player %s (GUID: %u) request wrong gossip menu: %u with wrong class: %u at Creature: %s (Entry: %u, Trainer Class: %u)",
+ TC_LOG_ERROR("sql.sql", "GOSSIP_OPTION_TRAINER:: Player %s (GUID: %u) requested wrong gossip menu: %u with wrong class: %u at Creature: %s (Entry: %u, Trainer Class: %u)",
GetName().c_str(), GetGUID().GetCounter(), menu->GetGossipMenu().GetMenuId(), getClass(), creature->GetName().c_str(), creature->GetEntry(), creature->GetCreatureTemplate()->trainer_class);
// no break;
case GOSSIP_OPTION_GOSSIP:
@@ -14012,7 +14012,7 @@ void Player::PrepareGossipMenu(WorldObject* source, uint32 menuId /*= 0*/, bool
canTalk = false;
break;
default:
- TC_LOG_ERROR("sql.sql", "Creature entry %u has unknown gossip option %u for menu %u", creature->GetEntry(), itr->second.OptionType, itr->second.MenuId);
+ TC_LOG_ERROR("sql.sql", "Creature entry %u has unknown gossip option %u for menu %u.", creature->GetEntry(), itr->second.OptionType, itr->second.MenuId);
canTalk = false;
break;
}
@@ -14125,7 +14125,7 @@ void Player::OnGossipSelect(WorldObject* source, uint32 gossipListId, uint32 men
{
if (gossipOptionId > GOSSIP_OPTION_QUESTGIVER)
{
- TC_LOG_ERROR("entities.player", "Player guid %u request invalid gossip option for GameObject entry %u", GetGUID().GetCounter(), source->GetEntry());
+ TC_LOG_ERROR("entities.player", "Player guid %u requested invalid gossip option for GameObject entry %u.", GetGUID().GetCounter(), source->GetEntry());
return;
}
}
@@ -14229,7 +14229,7 @@ void Player::OnGossipSelect(WorldObject* source, uint32 gossipListId, uint32 men
if (bgTypeId == BATTLEGROUND_TYPE_NONE)
{
- TC_LOG_ERROR("entities.player", "a user (guid %u) requested battlegroundlist from a npc who is no battlemaster", GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "User (guid %u) requested battlegroundlist from an NPC who is not a battlemaster.", GetGUID().GetCounter());
return;
}
@@ -15188,7 +15188,7 @@ bool Player::SatisfyQuestPreviousQuest(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestPreviousQuest: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required quest (1).", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestPreviousQuest: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have the required quest(s) (1).", qInfo->GetQuestId());
}
return false;
}
@@ -15221,7 +15221,7 @@ bool Player::SatisfyQuestPreviousQuest(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestPreviousQuest: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required quest (2).", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestPreviousQuest: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have the required quest(s) (2).", qInfo->GetQuestId());
}
return false;
@@ -15237,7 +15237,7 @@ bool Player::SatisfyQuestPreviousQuest(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestPreviousQuest: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required quest (3).", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestPreviousQuest: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have the required quest(s) (3).", qInfo->GetQuestId());
}
return false;
@@ -15255,7 +15255,7 @@ bool Player::SatisfyQuestClass(Quest const* qInfo, bool msg) const
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestClass: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required class.", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestClass: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player is not (one of) the required class(es).", qInfo->GetQuestId());
}
return false;
@@ -15274,7 +15274,7 @@ bool Player::SatisfyQuestRace(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_QUEST_FAILED_WRONG_RACE);
- TC_LOG_DEBUG("misc", "SatisfyQuestRace: Sent INVALIDREASON_QUEST_FAILED_WRONG_RACE (questId: %u) because player does not have required race.", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestRace: Sent INVALIDREASON_QUEST_FAILED_WRONG_RACE (questId: %u) because player is not (one of) the required race(s).", qInfo->GetQuestId());
}
return false;
@@ -15290,7 +15290,7 @@ bool Player::SatisfyQuestReputation(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestReputation: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required reputation (min).", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestReputation: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have the required reputation (min).", qInfo->GetQuestId());
}
return false;
}
@@ -15301,7 +15301,7 @@ bool Player::SatisfyQuestReputation(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestReputation: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required reputation (max).", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestReputation: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have the required reputation (max).", qInfo->GetQuestId());
}
return false;
}
@@ -15314,7 +15314,7 @@ bool Player::SatisfyQuestReputation(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestReputation: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have required reputation (ReputationObjective2).", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestReputation: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not have the required reputation (ReputationObjective2).", qInfo->GetQuestId());
}
return false;
}
@@ -15343,7 +15343,7 @@ bool Player::SatisfyQuestConditions(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestConditions: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not meet conditions.", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestConditions: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player does not meet the conditions.", qInfo->GetQuestId());
}
TC_LOG_DEBUG("condition", "Player::SatisfyQuestConditions: conditions not met for quest %u", qInfo->GetQuestId());
return false;
@@ -15389,7 +15389,7 @@ bool Player::SatisfyQuestExclusiveGroup(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestExclusiveGroup: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player already did daily quests in exclusive group.", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestExclusiveGroup: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player already did all daily quests in exclusive group.", qInfo->GetQuestId());
}
return false;
@@ -15401,7 +15401,7 @@ bool Player::SatisfyQuestExclusiveGroup(Quest const* qInfo, bool msg)
if (msg)
{
SendCanTakeQuestResponse(INVALIDREASON_DONT_HAVE_REQ);
- TC_LOG_DEBUG("misc", "SatisfyQuestExclusiveGroup: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player already did quest in exclusive group.", qInfo->GetQuestId());
+ TC_LOG_DEBUG("misc", "SatisfyQuestExclusiveGroup: Sent INVALIDREASON_DONT_HAVE_REQ (questId: %u) because player has already taken one or more quests in the exclusive group.", qInfo->GetQuestId());
}
return false;
}
@@ -16781,7 +16781,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
{
std::string name = "<unknown>";
sObjectMgr->GetPlayerNameByGUID(guid, name);
- TC_LOG_ERROR("entities.player", "Player %s %s not found in table `characters`, can't load. ", name.c_str(), guid.ToString().c_str());
+ TC_LOG_ERROR("entities.player", "Player %s %s not found in table `characters`, can't load.", name.c_str(), guid.ToString().c_str());
return false;
}
@@ -16793,7 +16793,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
// player should be able to load/delete character only with correct account!
if (dbAccountId != GetSession()->GetAccountId())
{
- TC_LOG_ERROR("entities.player", "Player %s loading from wrong account (is: %u, should be: %u)", guid.ToString().c_str(), GetSession()->GetAccountId(), dbAccountId);
+ TC_LOG_ERROR("entities.player", "Player %s attempts to load from wrong account (current: %u, should be: %u)", guid.ToString().c_str(), GetSession()->GetAccountId(), dbAccountId);
return false;
}
@@ -16825,7 +16825,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
uint8 gender = fields[5].GetUInt8();
if (!IsValidGender(gender))
{
- TC_LOG_ERROR("entities.player", "Player %s has wrong gender (%u), can't be loaded.", guid.ToString().c_str(), gender);
+ TC_LOG_ERROR("entities.player", "Player %s is the wrong gender (%u) and can't be loaded.", guid.ToString().c_str(), gender);
return false;
}
@@ -16840,15 +16840,15 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
PlayerInfo const* info = sObjectMgr->GetPlayerInfo(getRace(), getClass());
if (!info)
{
- TC_LOG_ERROR("entities.player", "Player %s has wrong race/class (%u/%u), can't be loaded.", guid.ToString().c_str(), getRace(), getClass());
+ TC_LOG_ERROR("entities.player", "Player %s has an invalid race/class combination (%u/%u) and can't be loaded.", guid.ToString().c_str(), getRace(), getClass());
return false;
}
SetUInt32Value(UNIT_FIELD_LEVEL, fields[6].GetUInt8());
SetUInt32Value(PLAYER_XP, fields[7].GetUInt32());
- _LoadIntoDataField(fields[61].GetCString(), PLAYER_EXPLORED_ZONES_1, PLAYER_EXPLORED_ZONES_SIZE);
- _LoadIntoDataField(fields[64].GetCString(), PLAYER__FIELD_KNOWN_TITLES, KNOWN_TITLES_SIZE*2);
+ _LoadIntoDataField(fields[61].GetString(), PLAYER_EXPLORED_ZONES_1, PLAYER_EXPLORED_ZONES_SIZE);
+ _LoadIntoDataField(fields[64].GetString(), PLAYER__FIELD_KNOWN_TITLES, KNOWN_TITLES_SIZE * 2);
SetObjectScale(1.0f);
SetFloatValue(UNIT_FIELD_HOVERHEIGHT, 1.0f);
@@ -16875,7 +16875,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
GetByteValue(PLAYER_BYTES_2, 0), // facial hair
GetByteValue(PLAYER_BYTES, 0))) // skin color
{
- TC_LOG_ERROR("entities.player", "Player %s has wrong Appearance values (Hair/Skin/Color), can't be loaded.", guid.ToString().c_str());
+ TC_LOG_ERROR("entities.player", "Player %s has wrong Appearance values (Hair/Skin/Color) and can't be loaded.", guid.ToString().c_str());
return false;
}
@@ -16891,7 +16891,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
InitDisplayIds();
- // cleanup inventory related item value fields (its will be filled correctly in _LoadInventory)
+ // cleanup inventory related item value fields (it will be filled correctly in _LoadInventory)
for (uint8 slot = EQUIPMENT_SLOT_START; slot < EQUIPMENT_SLOT_END; ++slot)
{
SetGuidValue(PLAYER_FIELD_INV_SLOT_HEAD + (slot * 2), ObjectGuid::Empty);
@@ -16901,7 +16901,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
m_items[slot] = NULL;
}
- TC_LOG_DEBUG("entities.player.loading", "Load Basic value of player %s is: ", m_name.c_str());
+ TC_LOG_DEBUG("entities.player.loading", "Load Basic values of player %s: ", m_name.c_str());
outDebugValues();
//Need to call it to initialize m_team (m_team can be calculated from race)
@@ -16970,7 +16970,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
MapEntry const* mapEntry = sMapStore.LookupEntry(mapId);
if (!mapEntry || !IsPositionValid())
{
- TC_LOG_ERROR("entities.player", "Player %s have invalid coordinates (MapId: %u X: %f Y: %f Z: %f O: %f). Teleport to default race/class locations.",
+ TC_LOG_ERROR("entities.player", "Player %s has invalid coordinates (MapId: %u X: %f Y: %f Z: %f O: %f). Teleporting player to default race/class location.",
guid.ToString().c_str(), mapId, GetPositionX(), GetPositionY(), GetPositionZ(), GetOrientation());
RelocateToHomebind();
}
@@ -17011,7 +17011,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
//if (mapId == MAPID_INVALID) -- code kept for reference
if (int16(mapId) == int16(-1)) // Battleground Entry Point not found (???)
{
- TC_LOG_ERROR("entities.player", "Player %s was in BG in database, but BG was not found, and entry point was invalid! Teleport to default race/class locations.",
+ TC_LOG_ERROR("entities.player", "Player %s was in BG in database, but BG was not found and entry point was invalid! Teleporting to default race/class locations.",
guid.ToString().c_str());
RelocateToHomebind();
}
@@ -17043,7 +17043,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
std::fabs(m_movementInfo.transport.pos.GetPositionY()) > 250.0f ||
std::fabs(m_movementInfo.transport.pos.GetPositionZ()) > 250.0f)
{
- TC_LOG_ERROR("entities.player", "Player %s have invalid transport coordinates (X: %f Y: %f Z: %f O: %f). Teleport to bind location.",
+ TC_LOG_ERROR("entities.player", "Player %s has invalid transport coordinates (X: %f Y: %f Z: %f O: %f). Teleporting player to bind location.",
guid.ToString().c_str(), x, y, z, o);
m_movementInfo.transport.Reset();
@@ -17060,7 +17060,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
}
else
{
- TC_LOG_ERROR("entities.player", "Player %s have problems with transport guid (%u). Teleport to bind location.",
+ TC_LOG_ERROR("entities.player", "Player %s has problems with transport guid (%u). Teleporting to bind location.",
guid.ToString().c_str(), transLowGUID);
RelocateToHomebind();
@@ -17084,14 +17084,14 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
if (uint32 node_id = m_taxi.GetTaxiSource())
nodeEntry = sTaxiNodesStore.LookupEntry(node_id);
- if (!nodeEntry) // don't know taxi start node, to homebind
+ if (!nodeEntry) // don't know taxi start node, teleport to homebind
{
- TC_LOG_ERROR("entities.player", "Character %u have wrong data in taxi destination list, teleport to homebind.", GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "Character %u has wrong data in taxi destination list. Teleporting player to homebind.", GetGUID().GetCounter());
RelocateToHomebind();
}
- else // have start node, to it
+ else // has start node, teleport to it
{
- TC_LOG_ERROR("entities.player", "Character %u have too short taxi destination list, teleport to original node.", GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "Character %u has too short taxi destination list. Teleporting player to original node.", GetGUID().GetCounter());
mapId = nodeEntry->map_id;
Relocate(nodeEntry->x, nodeEntry->y, nodeEntry->z, 0.0f);
}
@@ -17120,7 +17120,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
{
if (GetSession()->Expansion() < mapEntry->Expansion())
{
- TC_LOG_DEBUG("entities.player.loading", "Player %s using client without required expansion tried login at non accessible map %u", GetName().c_str(), mapId);
+ TC_LOG_DEBUG("entities.player.loading", "Player %s is using client without required expansion, tried to log in to inaccessible map %u.", GetName().c_str(), mapId);
RelocateToHomebind();
}
@@ -17250,7 +17250,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
m_stableSlots = fields[32].GetUInt8();
if (m_stableSlots > MAX_PET_STABLES)
{
- TC_LOG_ERROR("entities.player", "Player can have not more %u stable slots, but have in DB %u", MAX_PET_STABLES, uint32(m_stableSlots));
+ TC_LOG_ERROR("entities.player", "Player can not have more than %u stable slots, but has %u in DB.", MAX_PET_STABLES, uint32(m_stableSlots));
m_stableSlots = MAX_PET_STABLES;
}
@@ -17258,7 +17258,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder)
if (HasAtLoginFlag(AT_LOGIN_RENAME))
{
- TC_LOG_ERROR("entities.player", "Player (GUID: %u) tried to login while forced to rename, can't load.'", GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "Player (GUID: %u) tried to login while forced to rename, could not load player.", GetGUID().GetCounter());
return false;
}
@@ -17545,9 +17545,9 @@ void Player::_LoadActions(PreparedQueryResult result)
ab->uState = ACTIONBUTTON_UNCHANGED;
else
{
- TC_LOG_ERROR("entities.player", " ...at loading, and will deleted in DB also");
+ TC_LOG_ERROR("entities.player", " ...at loading, and will also be deleted in DB.");
- // Will deleted in DB at next save (it can create data until save but marked as deleted)
+ // Will be deleted in DB at next save (it can create data until save but marked as deleted).
m_actionButtons[button].uState = ACTIONBUTTON_DELETED;
}
} while (result->NextRow());
@@ -17556,7 +17556,7 @@ void Player::_LoadActions(PreparedQueryResult result)
void Player::_LoadAuras(PreparedQueryResult result, uint32 timediff)
{
- TC_LOG_DEBUG("entities.player.loading", "Loading auras for player %u", GetGUID().GetCounter());
+ TC_LOG_DEBUG("entities.player.loading", "Loading auras for player %u.", GetGUID().GetCounter());
/* 0 1 2 3 4 5 6 7 8 9 10
QueryResult* result = CharacterDatabase.PQuery("SELECT casterGuid, spell, effectMask, recalculateMask, stackCount, amount0, amount1, amount2, base_amount0, base_amount1, base_amount2,
@@ -17589,7 +17589,7 @@ void Player::_LoadAuras(PreparedQueryResult result, uint32 timediff)
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellid);
if (!spellInfo)
{
- TC_LOG_ERROR("entities.player", "Unknown aura (spellid %u), ignore.", spellid);
+ TC_LOG_ERROR("entities.player", "Unknown aura (spellid %u), ignored.", spellid);
continue;
}
@@ -17623,7 +17623,7 @@ void Player::_LoadAuras(PreparedQueryResult result, uint32 timediff)
aura->SetLoadedState(maxduration, remaintime, remaincharges, stackcount, recalculatemask, &damage[0]);
aura->ApplyForTargets();
- TC_LOG_DEBUG("entities.player", "Added aura spellid %u, effectmask %u", spellInfo->Id, effmask);
+ TC_LOG_DEBUG("entities.player", "Added aura spellid %u, effectmask %u.", spellInfo->Id, effmask);
}
}
while (result->NextRow());
@@ -17649,10 +17649,10 @@ void Player::_LoadGlyphAuras()
TC_LOG_ERROR("entities.player", "Player %s has glyph with typeflags %u in slot with typeflags %u, removing.", m_name.c_str(), gp->TypeFlags, gs->TypeFlags);
}
else
- TC_LOG_ERROR("entities.player", "Player %s has not existing glyph slot entry %u on index %u", m_name.c_str(), GetGlyphSlot(i), i);
+ TC_LOG_ERROR("entities.player", "Player %s has non-existing glyph slot entry %u on index %u.", m_name.c_str(), GetGlyphSlot(i), i);
}
else
- TC_LOG_ERROR("entities.player", "Player %s has not existing glyph entry %u on index %u", m_name.c_str(), glyph, i);
+ TC_LOG_ERROR("entities.player", "Player %s has non-existing glyph entry %u on index %u.", m_name.c_str(), glyph, i);
// On any error remove glyph
SetGlyph(i, 0);
@@ -17782,7 +17782,7 @@ void Player::_LoadInventory(PreparedQueryResult result, uint32 timeDiff)
item->SetState(ITEM_UNCHANGED, this);
else
{
- TC_LOG_ERROR("entities.player", "Player::_LoadInventory: player (GUID: %u, name: '%s') has item (GUID: %u, entry: %u) which can't be loaded into inventory (Bag GUID: %u, slot: %u) by reason %u. Item will be sent by mail.",
+ TC_LOG_ERROR("entities.player", "Player::_LoadInventory: player (GUID: %u, name: '%s') has item (GUID: %u, entry: %u) which can't be loaded into inventory (Bag GUID: %u, slot: %u) for reason %u. Item will be sent by mail.",
GetGUID().GetCounter(), GetName().c_str(), item->GetGUID().GetCounter(), item->GetEntry(), bagGuid, slot, err);
item->DeleteFromInventoryDB(trans);
problematicItems.push_back(item);
@@ -17915,7 +17915,7 @@ Item* Player::_LoadItem(SQLTransaction& trans, uint32 zoneId, uint32 timeDiff, F
}
else
{
- TC_LOG_ERROR("entities.player", "Player::_LoadInventory: player (GUID: %u, name: '%s') has broken item (GUID: %u, entry: %u) in inventory. Deleting item.",
+ TC_LOG_ERROR("entities.player", "Player::_LoadInventory: player (GUID: %u, name: '%s') has a broken item (GUID: %u, entry: %u) in inventory. Deleting item.",
GetGUID().GetCounter(), GetName().c_str(), itemGuid, itemEntry);
remove = true;
}
@@ -17930,7 +17930,7 @@ Item* Player::_LoadItem(SQLTransaction& trans, uint32 zoneId, uint32 timeDiff, F
}
else
{
- TC_LOG_ERROR("entities.player", "Player::_LoadInventory: player (GUID: %u, name: '%s') has unknown item (entry: %u) in inventory. Deleting item.",
+ TC_LOG_ERROR("entities.player", "Player::_LoadInventory: player (GUID: %u, name: '%s') has an unknown item (entry: %u) in inventory. Deleting item.",
GetGUID().GetCounter(), GetName().c_str(), itemEntry);
Item::DeleteFromInventoryDB(trans, itemGuid);
Item::DeleteFromDB(trans, itemGuid);
@@ -17961,7 +17961,7 @@ void Player::_LoadMailedItems(Mail* mail)
if (!proto)
{
- TC_LOG_ERROR("entities.player", "Player %u has unknown item_template (ProtoType) in mailed items(GUID: %u template: %u) in mail (%u), deleted.", GetGUID().GetCounter(), itemGuid, itemTemplate, mail->messageID);
+ TC_LOG_ERROR("entities.player", "Player %u has an unknown item_template (ProtoType) in mailed items(GUID: %u template: %u) in mail (%u), deleted.", GetGUID().GetCounter(), itemGuid, itemTemplate, mail->messageID);
stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_INVALID_MAIL_ITEM);
stmt->setUInt32(0, itemGuid);
@@ -17977,7 +17977,7 @@ void Player::_LoadMailedItems(Mail* mail)
if (!item->LoadFromDB(itemGuid, ObjectGuid(HighGuid::Player, fields[13].GetUInt32()), fields, itemTemplate))
{
- TC_LOG_ERROR("entities.player", "Player::_LoadMailedItems - Item in mail (%u) doesn't exist !!!! - item guid: %u, deleted from mail", mail->messageID, itemGuid);
+ TC_LOG_ERROR("entities.player", "Player::_LoadMailedItems - Item in mail (%u) doesn't exist!!! - item guid: %u, deleted from mail.", mail->messageID, itemGuid);
stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_MAIL_ITEM);
stmt->setUInt32(0, itemGuid);
@@ -18040,7 +18040,7 @@ void Player::_LoadMail()
if (m->mailTemplateId && !sMailTemplateStore.LookupEntry(m->mailTemplateId))
{
- TC_LOG_ERROR("entities.player", "Player::_LoadMail - Mail (%u) have not existed MailTemplateId (%u), remove at load", m->messageID, m->mailTemplateId);
+ TC_LOG_ERROR("entities.player", "Player::_LoadMail - Mail (%u) contains a non-existing MailTemplateId (%u), removing at load.", m->messageID, m->mailTemplateId);
m->mailTemplateId = 0;
}
@@ -18221,7 +18221,7 @@ void Player::_LoadDailyQuestStatus(PreparedQueryResult result)
if (quest_daily_idx >= PLAYER_MAX_DAILY_QUESTS) // max amount with exist data in query
{
- TC_LOG_ERROR("entities.player", "Player (GUID: %u) have more 25 daily quest records in `charcter_queststatus_daily`", GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "Player (GUID: %u) has more than 25 daily quest records in `charcter_queststatus_daily`", GetGUID().GetCounter());
break;
}
@@ -18384,12 +18384,12 @@ void Player::_LoadBoundInstances(PreparedQueryResult result)
if (!mapEntry || !mapEntry->IsDungeon())
{
- TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) has bind to not existed or not dungeon map %d (%s)", GetName().c_str(), GetGUID().GetCounter(), mapId, mapname.c_str());
+ TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) has bind to a non-existing or non-dungeon map %d (%s).", GetName().c_str(), GetGUID().GetCounter(), mapId, mapname.c_str());
deleteInstance = true;
}
else if (difficulty >= MAX_DIFFICULTY)
{
- TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) has bind to not existed difficulty %d instance for map %u (%s)", GetName().c_str(), GetGUID().GetCounter(), difficulty, mapId, mapname.c_str());
+ TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) has a bind to a non-existing difficulty %d instance for map %u (%s)", GetName().c_str(), GetGUID().GetCounter(), difficulty, mapId, mapname.c_str());
deleteInstance = true;
}
else
@@ -18397,12 +18397,12 @@ void Player::_LoadBoundInstances(PreparedQueryResult result)
MapDifficulty const* mapDiff = GetMapDifficultyData(mapId, Difficulty(difficulty));
if (!mapDiff)
{
- TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) has bind to not existed difficulty %d instance for map %u (%s)", GetName().c_str(), GetGUID().GetCounter(), difficulty, mapId, mapname.c_str());
+ TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) has a bind to a non-existing difficulty %d instance for map %u (%s).", GetName().c_str(), GetGUID().GetCounter(), difficulty, mapId, mapname.c_str());
deleteInstance = true;
}
else if (!perm && group)
{
- TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) is in group %d but has a non-permanent character bind to map %d (%s), %d, %d", GetName().c_str(), GetGUID().GetCounter(), group->GetLowGUID(), mapId, mapname.c_str(), instanceId, difficulty);
+ TC_LOG_ERROR("entities.player", "_LoadBoundInstances: player %s(%d) is in group %d, but has a non-permanent character bind to map %d (%s), %d, %d.", GetName().c_str(), GetGUID().GetCounter(), group->GetLowGUID(), mapId, mapname.c_str(), instanceId, difficulty);
deleteInstance = true;
}
}
@@ -19313,7 +19313,7 @@ void Player::_SaveInventory(SQLTransaction& trans)
}
else
{
- TC_LOG_ERROR("entities.player", "Can't find %s but is in refundable storage for player %u ! Removing.", itr->ToString().c_str(), GetGUID().GetCounter());
+ TC_LOG_ERROR("entities.player", "Can't find %s, but is in refundable storage for player %u ! Removing.", itr->ToString().c_str(), GetGUID().GetCounter());
m_refundableItems.erase(itr);
}
}
@@ -19362,7 +19362,7 @@ void Player::_SaveInventory(SQLTransaction& trans)
{
TC_LOG_ERROR("entities.player", "Player(GUID: %u Name: %s)::_SaveInventory - the bag(%u) and slot(%u) values for the item with guid %u are incorrect, the item with guid %u is there instead!", lowGuid, GetName().c_str(), item->GetBagSlot(), item->GetSlot(), item->GetGUID().GetCounter(), test->GetGUID().GetCounter());
// save all changes to the item...
- if (item->GetState() != ITEM_NEW) // only for existing items, no dupes
+ if (item->GetState() != ITEM_NEW) // only for existing items, no duplicates
item->SaveToDB(trans);
// ...but do not save position in invntory
continue;
@@ -20121,8 +20121,8 @@ Pet* Player::GetPet() const
if (IsInWorld() && pet)
return pet;
- //there may be a guardian in slot
- //TC_LOG_ERROR("entities.player", "Player::GetPet: Pet %u not exist.", GUID_LOPART(pet_guid));
+ // there may be a guardian in this slot
+ //TC_LOG_ERROR("entities.player", "Player::GetPet: Pet %u does not exist.", GUID_LOPART(pet_guid));
//const_cast<Player*>(this)->SetPetGUID(0);
}
@@ -20230,7 +20230,7 @@ void Player::StopCastingCharm()
if (GetCharmGUID())
{
- TC_LOG_FATAL("entities.player", "Player %s (%s) is not able to uncharm unit (%s)", GetName().c_str(), GetGUID().ToString().c_str(), GetCharmGUID().ToString().c_str());
+ TC_LOG_FATAL("entities.player", "Player %s (%s) is not able to uncharm unit (%s)!", GetName().c_str(), GetGUID().ToString().c_str(), GetCharmGUID().ToString().c_str());
if (charm->GetCharmerGUID())
{
TC_LOG_FATAL("entities.player", "Charmed unit has charmer %s", charm->GetCharmerGUID().ToString().c_str());
@@ -21335,7 +21335,7 @@ bool Player::BuyItemFromVendorSlot(ObjectGuid vendorguid, uint32 vendorslot, uin
ItemExtendedCostEntry const* iece = sItemExtendedCostStore.LookupEntry(crItem->ExtendedCost);
if (!iece)
{
- TC_LOG_ERROR("entities.player", "Item %u have wrong ExtendedCost field value %u", pProto->ItemId, crItem->ExtendedCost);
+ TC_LOG_ERROR("entities.player", "Item %u has wrong ExtendedCost field value %u", pProto->ItemId, crItem->ExtendedCost);
return false;
}
@@ -21378,7 +21378,7 @@ bool Player::BuyItemFromVendorSlot(ObjectGuid vendorguid, uint32 vendorslot, uin
uint32 maxCount = MAX_MONEY_AMOUNT / pProto->BuyPrice;
if ((uint32)count > maxCount)
{
- TC_LOG_ERROR("entities.player", "Player %s tried to buy %u item id %u, causing overflow", GetName().c_str(), (uint32)count, pProto->ItemId);
+ TC_LOG_ERROR("entities.player", "Player %s tried to buy %u item id %u, causing overflow.", GetName().c_str(), (uint32)count, pProto->ItemId);
count = (uint8)maxCount;
}
price = pProto->BuyPrice * count; //it should not exceed MAX_MONEY_AMOUNT
@@ -21472,7 +21472,7 @@ void Player::UpdateHomebindTime(uint32 time)
data << uint32(m_HomebindTimer);
data << uint32(1);
GetSession()->SendPacket(&data);
- TC_LOG_DEBUG("maps", "PLAYER: Player '%s' (GUID: %u) will be teleported to homebind in 60 seconds", GetName().c_str(), GetGUID().GetCounter());
+ TC_LOG_DEBUG("maps", "PLAYER: Player '%s' (GUID: %u) will be teleported to homebind in 60 seconds.", GetName().c_str(), GetGUID().GetCounter());
}
}
@@ -21542,7 +21542,7 @@ void Player::UpdatePotionCooldown(Spell* spell)
// Call not from spell cast, send cooldown event for item spells if no in combat
if (!spell)
{
- // spell/item pair let set proper cooldown (except not existed charged spell cooldown spellmods for potions)
+ // spell/item pair let set proper cooldown (except non-existing charged spell cooldown spellmods for potions)
if (ItemTemplate const* proto = sObjectMgr->GetItemTemplate(m_lastPotionId))
for (uint8 idx = 0; idx < MAX_ITEM_PROTO_SPELLS; ++idx)
if (proto->Spells[idx].SpellId && proto->Spells[idx].SpellTrigger == ITEM_SPELLTRIGGER_ON_USE)
@@ -23237,7 +23237,7 @@ bool Player::HasItemFitToSpellRequirements(SpellInfo const* spellInfo, Item cons
break;
}
default:
- TC_LOG_ERROR("entities.player", "HasItemFitToSpellRequirements: Not handled spell requirement for item class %u", spellInfo->EquippedItemClass);
+ TC_LOG_ERROR("entities.player", "HasItemFitToSpellRequirements: Spell requirement not handled for item class %u", spellInfo->EquippedItemClass);
break;
}
@@ -23889,7 +23889,7 @@ void Player::SetViewpoint(WorldObject* target, bool apply)
{
if (apply)
{
- TC_LOG_DEBUG("maps", "Player::CreateViewpoint: Player %s create seer %u (TypeId: %u).", GetName().c_str(), target->GetEntry(), target->GetTypeId());
+ TC_LOG_DEBUG("maps", "Player::CreateViewpoint: Player %s created seer %u (TypeId: %u).", GetName().c_str(), target->GetEntry(), target->GetTypeId());
if (!AddGuidValue(PLAYER_FARSIGHT, target->GetGUID()))
{
@@ -23905,7 +23905,7 @@ void Player::SetViewpoint(WorldObject* target, bool apply)
}
else
{
- TC_LOG_DEBUG("maps", "Player::CreateViewpoint: Player %s remove seer", GetName().c_str());
+ TC_LOG_DEBUG("maps", "Player::CreateViewpoint: Player %s removed seer", GetName().c_str());
if (!RemoveGuidValue(PLAYER_FARSIGHT, target->GetGUID()))
{
@@ -24454,7 +24454,7 @@ void Player::_LoadSkills(PreparedQueryResult result)
if (value == 0)
{
- TC_LOG_ERROR("entities.player", "Character %u has skill %u with value 0. Will be deleted.", GetGUID().GetCounter(), skill);
+ TC_LOG_ERROR("entities.player", "Character %u has skill %u with value 0. Skill will be deleted.", GetGUID().GetCounter(), skill);
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHARACTER_SKILL);
@@ -24791,7 +24791,7 @@ void Player::LearnTalent(uint32 talentId, uint32 talentRank)
uint32 spellid = talentInfo->RankID[talentRank];
if (spellid == 0)
{
- TC_LOG_ERROR("entities.player", "Talent.dbc have for talent: %u Rank: %u spell id = 0", talentId, talentRank);
+ TC_LOG_ERROR("entities.player", "Talent.dbc contains talent: %u Rank: %u spell id = 0", talentId, talentRank);
return;
}
@@ -24928,7 +24928,7 @@ void Player::LearnPetTalent(ObjectGuid petGuid, uint32 talentId, uint32 talentRa
uint32 spellid = talentInfo->RankID[talentRank];
if (spellid == 0)
{
- TC_LOG_ERROR("entities.player", "Talent.dbc have for talent: %u Rank: %u spell id = 0", talentId, talentRank);
+ TC_LOG_ERROR("entities.player", "Talent.dbc contains talent: %u Rank: %u spell id = 0", talentId, talentRank);
return;
}
@@ -25255,7 +25255,7 @@ void Player::SetEquipmentSet(uint32 index, EquipmentSet eqset)
if (!found) // something wrong...
{
- TC_LOG_ERROR("entities.player", "Player %s tried to save equipment set " UI64FMTD " (index %u), but that equipment set not found!", GetName().c_str(), eqset.Guid, index);
+ TC_LOG_ERROR("entities.player", "Player %s tried to save equipment set " UI64FMTD " (index %u), but that equipment set was not found!", GetName().c_str(), eqset.Guid, index);
return;
}
}
@@ -25598,7 +25598,7 @@ void Player::ActivateSpec(uint8 spec)
for (int8 rank = MAX_TALENT_RANK-1; rank >= 0; --rank)
{
- // skip non-existant talent ranks
+ // skip non-existing talent ranks
if (talentInfo->RankID[rank] == 0)
continue;
RemoveSpell(talentInfo->RankID[rank], true); // removes the talent, and all dependant, learned, and chained spells..
@@ -25642,7 +25642,7 @@ void Player::ActivateSpec(uint8 spec)
// learn highest talent rank that exists in newly activated spec
for (int8 rank = MAX_TALENT_RANK-1; rank >= 0; --rank)
{
- // skip non-existant talent ranks
+ // skip non-existing talent ranks
if (talentInfo->RankID[rank] == 0)
continue;
// if the talent can be found in the newly activated PlayerTalentMap
@@ -26198,7 +26198,7 @@ Pet* Player::SummonPet(uint32 entry, float x, float y, float z, float ang, PetTy
pet->Relocate(x, y, z, ang);
if (!pet->IsPositionValid())
{
- TC_LOG_ERROR("misc", "Pet (guidlow %d, entry %d) not summoned. Suggested coordinates isn't valid (X: %f Y: %f)", pet->GetGUID().GetCounter(), pet->GetEntry(), pet->GetPositionX(), pet->GetPositionY());
+ TC_LOG_ERROR("misc", "Pet (guidlow %d, entry %d) not summoned. Suggested coordinates are not valid (X: %f Y: %f)", pet->GetGUID().GetCounter(), pet->GetEntry(), pet->GetPositionX(), pet->GetPositionY());
delete pet;
return NULL;
}
@@ -26207,7 +26207,7 @@ Pet* Player::SummonPet(uint32 entry, float x, float y, float z, float ang, PetTy
uint32 pet_number = sObjectMgr->GeneratePetNumber();
if (!pet->Create(map->GenerateLowGuid<HighGuid::Pet>(), map, GetPhaseMask(), entry, pet_number))
{
- TC_LOG_ERROR("misc", "no such creature entry %u", entry);
+ TC_LOG_ERROR("misc", "No such creature entry %u", entry);
delete pet;
return NULL;
}
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index e9033b3d05c..a2a3151666e 100644
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -12342,7 +12342,7 @@ void Unit::UpdateSpeed(UnitMoveType mtype, bool forced)
if (Creature* creature = ToCreature())
{
uint32 immuneMask = creature->GetCreatureTemplate()->MechanicImmuneMask;
- if (immuneMask & (1 << MECHANIC_SNARE) || immuneMask & (1 << MECHANIC_DAZE))
+ if (immuneMask & (1 << (MECHANIC_SNARE - 1)) || immuneMask & (1 << (MECHANIC_DAZE - 1)))
break;
}
diff --git a/src/server/game/Events/GameEventMgr.cpp b/src/server/game/Events/GameEventMgr.cpp
index b2871786034..79584c6261e 100644
--- a/src/server/game/Events/GameEventMgr.cpp
+++ b/src/server/game/Events/GameEventMgr.cpp
@@ -221,7 +221,7 @@ void GameEventMgr::LoadFromDB()
uint8 event_id = fields[0].GetUInt8();
if (event_id == 0)
{
- TC_LOG_ERROR("sql.sql", "`game_event` game event entry 0 is reserved and can't be used.");
+ TC_LOG_ERROR("sql.sql", "`game_event`: game event entry 0 is reserved and can't be used.");
continue;
}
@@ -240,7 +240,7 @@ void GameEventMgr::LoadFromDB()
if (pGameEvent.length == 0 && pGameEvent.state == GAMEEVENT_NORMAL) // length>0 is validity check
{
- TC_LOG_ERROR("sql.sql", "`game_event` game event id (%i) isn't a world event and has length = 0, thus it can't be used.", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event`: game event id (%i) is not a world event and has length = 0, thus cannot be used.", event_id);
continue;
}
@@ -248,7 +248,7 @@ void GameEventMgr::LoadFromDB()
{
if (!sHolidaysStore.LookupEntry(pGameEvent.holiday_id))
{
- TC_LOG_ERROR("sql.sql", "`game_event` game event id (%i) have not existed holiday id %u.", event_id, pGameEvent.holiday_id);
+ TC_LOG_ERROR("sql.sql", "`game_event`: game event id (%i) contains nonexisting holiday id %u.", event_id, pGameEvent.holiday_id);
pGameEvent.holiday_id = HOLIDAY_NONE;
}
}
@@ -259,7 +259,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
@@ -283,7 +283,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_save` game event entry (%i) is out of range compared to max event entry in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_save`: game event entry (%i) is out of range compared to max event entry in `game_event`.", event_id);
continue;
}
@@ -294,7 +294,7 @@ void GameEventMgr::LoadFromDB()
}
else
{
- TC_LOG_ERROR("sql.sql", "game_event_save includes event save for non-worldevent id %u", event_id);
+ TC_LOG_ERROR("sql.sql", "game_event_save includes event save for non-worldevent id %u.", event_id);
continue;
}
@@ -302,7 +302,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u game event saves in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u game event saves in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -326,7 +326,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_prerequisite` game event id (%i) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_prerequisite`: game event id (%i) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -335,14 +335,14 @@ void GameEventMgr::LoadFromDB()
uint16 prerequisite_event = fields[1].GetUInt32();
if (prerequisite_event >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_prerequisite` game event prerequisite id (%i) is out of range compared to max event id in `game_event`", prerequisite_event);
+ TC_LOG_ERROR("sql.sql", "`game_event_prerequisite`: game event prerequisite id (%i) is out of range compared to max event id in `game_event`.", prerequisite_event);
continue;
}
mGameEvent[event_id].prerequisite_events.insert(prerequisite_event);
}
else
{
- TC_LOG_ERROR("sql.sql", "game_event_prerequisiste includes event entry for non-worldevent id %u", event_id);
+ TC_LOG_ERROR("sql.sql", "game_event_prerequisiste includes event entry for non-worldevent id %u.", event_id);
continue;
}
@@ -350,7 +350,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u game event prerequisites in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u game event prerequisites in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -363,7 +363,7 @@ void GameEventMgr::LoadFromDB()
QueryResult result = WorldDatabase.Query("SELECT guid, eventEntry FROM game_event_creature");
if (!result)
- TC_LOG_INFO("server.loading", ">> Loaded 0 creatures in game events. DB table `game_event_creature` is empty");
+ TC_LOG_INFO("server.loading", ">> Loaded 0 creatures in game events. DB table `game_event_creature` is empty.");
else
{
uint32 count = 0;
@@ -385,7 +385,7 @@ void GameEventMgr::LoadFromDB()
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventCreatureGuids.size()))
{
- TC_LOG_ERROR("sql.sql", "`game_event_creature` game event id (%i) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_creature`: game event id (%i) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -396,7 +396,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u creatures in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u creatures in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -431,7 +431,7 @@ void GameEventMgr::LoadFromDB()
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventGameobjectGuids.size()))
{
- TC_LOG_ERROR("sql.sql", "`game_event_gameobject` game event id (%i) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_gameobject`: game event id (%i) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -442,7 +442,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u gameobjects in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u gameobjects in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -469,7 +469,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEventModelEquip.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_model_equip` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_model_equip`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -485,7 +485,7 @@ void GameEventMgr::LoadFromDB()
int8 equipId = static_cast<int8>(newModelEquipSet.equipment_id);
if (!sObjectMgr->GetEquipmentInfo(entry, equipId))
{
- TC_LOG_ERROR("sql.sql", "Table `game_event_model_equip` have creature (Guid: %u, entry: %u) with equipment_id %u not found in table `creature_equip_template`, set to no equipment.",
+ TC_LOG_ERROR("sql.sql", "Table `game_event_model_equip` contains creature (Guid: %u, entry: %u) with equipment_id %u not found in table `creature_equip_template`. Setting entry to no equipment.",
guid, entry, newModelEquipSet.equipment_id);
continue;
}
@@ -497,7 +497,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u model/equipment changes in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u model/equipment changes in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -523,7 +523,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEventCreatureQuests.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_creature_quest` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_creature_quest`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -534,7 +534,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u quests additions in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u quests additions in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -560,7 +560,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEventGameObjectQuests.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_gameobject_quest` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_gameobject_quest`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -571,7 +571,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u quests additions in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u quests additions in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -598,7 +598,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_quest_condition` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_quest_condition`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -610,7 +610,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u quest event conditions in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u quest event conditions in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -635,7 +635,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_condition` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_condition`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -648,7 +648,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u conditions in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u conditions in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -673,7 +673,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_condition_save` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_condition_save`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -684,7 +684,7 @@ void GameEventMgr::LoadFromDB()
}
else
{
- TC_LOG_ERROR("sql.sql", "game_event_condition_save contains not present condition evt id %u cond id %u", event_id, condition);
+ TC_LOG_ERROR("sql.sql", "game_event_condition_save contains not present condition event id %u condition id %u.", event_id, condition);
continue;
}
@@ -692,7 +692,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u condition saves in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u condition saves in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -718,7 +718,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_npcflag` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_npcflag`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -728,7 +728,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u npcflags in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u npcflags in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -753,13 +753,13 @@ void GameEventMgr::LoadFromDB()
if (!sObjectMgr->GetQuestTemplate(questId))
{
- TC_LOG_ERROR("sql.sql", "`game_event_seasonal_questrelation` quest id (%u) does not exist in `quest_template`", questId);
+ TC_LOG_ERROR("sql.sql", "`game_event_seasonal_questrelation`: quest id (%u) does not exist in `quest_template`.", questId);
continue;
}
if (eventEntry >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_seasonal_questrelation` event id (%u) is out of range compared to max event in `game_event`", eventEntry);
+ TC_LOG_ERROR("sql.sql", "`game_event_seasonal_questrelation`: event id (%u) is out of range compared to max event in `game_event`.", eventEntry);
continue;
}
@@ -768,7 +768,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u quests additions in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u quests additions in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -792,7 +792,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEventVendors.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_npc_vendor` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_npc_vendor`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -830,7 +830,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u vendor additions in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u vendor additions in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -854,7 +854,7 @@ void GameEventMgr::LoadFromDB()
if (event_id >= mGameEvent.size())
{
- TC_LOG_ERROR("sql.sql", "`game_event_battleground_holiday` game event id (%u) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_battleground_holiday`: game event id (%u) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
@@ -864,7 +864,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u battleground holidays in game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u battleground holidays in game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
@@ -892,13 +892,13 @@ void GameEventMgr::LoadFromDB()
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventPoolIds.size()))
{
- TC_LOG_ERROR("sql.sql", "`game_event_pool` game event id (%i) is out of range compared to max event id in `game_event`", event_id);
+ TC_LOG_ERROR("sql.sql", "`game_event_pool`: game event id (%i) is out of range compared to max event id in `game_event`.", event_id);
continue;
}
if (!sPoolMgr->CheckPool(entry))
{
- TC_LOG_ERROR("sql.sql", "Pool Id (%u) has all creatures or gameobjects with explicit chance sum <>100 and no equal chance defined. The pool system cannot pick one to spawn.", entry);
+ TC_LOG_ERROR("sql.sql", "Pool Id (%u) has all creatures or gameobjects with explicit chance sum <> 100 and no equal chance defined. The pool system cannot pick one to spawn.", entry);
continue;
}
@@ -909,7 +909,7 @@ void GameEventMgr::LoadFromDB()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u pools for game events in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u pools for game events in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
}
}
@@ -971,7 +971,7 @@ void GameEventMgr::StartArenaSeason()
if (!result)
{
- TC_LOG_ERROR("gameevent", "ArenaSeason (%u) must be an existant Arena Season", season);
+ TC_LOG_ERROR("gameevent", "ArenaSeason (%u) must be an existing Arena Season.", season);
return;
}
@@ -980,7 +980,7 @@ void GameEventMgr::StartArenaSeason()
if (eventId >= mGameEvent.size())
{
- TC_LOG_ERROR("gameevent", "EventEntry %u for ArenaSeason (%u) does not exists", eventId, season);
+ TC_LOG_ERROR("gameevent", "EventEntry %u for ArenaSeason (%u) does not exist.", eventId, season);
return;
}
@@ -1171,7 +1171,7 @@ void GameEventMgr::GameEventSpawn(int16 event_id)
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventCreatureGuids.size()))
{
- TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventSpawn attempt access to out of range mGameEventCreatureGuids element %i (size: %zu)",
+ TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventSpawn attempted access to out of range mGameEventCreatureGuids element %i (size: %zu).",
internal_event_id, mGameEventCreatureGuids.size());
return;
}
@@ -1198,7 +1198,7 @@ void GameEventMgr::GameEventSpawn(int16 event_id)
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventGameobjectGuids.size()))
{
- TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventSpawn attempt access to out of range mGameEventGameobjectGuids element %i (size: %zu)",
+ TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventSpawn attempted access to out of range mGameEventGameobjectGuids element %i (size: %zu).",
internal_event_id, mGameEventGameobjectGuids.size());
return;
}
@@ -1231,7 +1231,7 @@ void GameEventMgr::GameEventSpawn(int16 event_id)
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventPoolIds.size()))
{
- TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventSpawn attempt access to out of range mGameEventPoolIds element %u (size: %zu)",
+ TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventSpawn attempted access to out of range mGameEventPoolIds element %u (size: %zu).",
internal_event_id, mGameEventPoolIds.size());
return;
}
@@ -1246,7 +1246,7 @@ void GameEventMgr::GameEventUnspawn(int16 event_id)
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventCreatureGuids.size()))
{
- TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventCreatureGuids element %i (size: %zu)",
+ TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventUnspawn attempted access to out of range mGameEventCreatureGuids element %i (size: %zu).",
internal_event_id, mGameEventCreatureGuids.size());
return;
}
@@ -1276,7 +1276,7 @@ void GameEventMgr::GameEventUnspawn(int16 event_id)
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventGameobjectGuids.size()))
{
- TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventGameobjectGuids element %i (size: %zu)",
+ TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventUnspawn attempted access to out of range mGameEventGameobjectGuids element %i (size: %zu).",
internal_event_id, mGameEventGameobjectGuids.size());
return;
}
@@ -1305,7 +1305,7 @@ void GameEventMgr::GameEventUnspawn(int16 event_id)
}
if (internal_event_id < 0 || internal_event_id >= int32(mGameEventPoolIds.size()))
{
- TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventPoolIds element %u (size: %zu)", internal_event_id, mGameEventPoolIds.size());
+ TC_LOG_ERROR("gameevent", "GameEventMgr::GameEventUnspawn attempted access to out of range mGameEventPoolIds element %u (size: %zu).", internal_event_id, mGameEventPoolIds.size());
return;
}
diff --git a/src/server/game/Handlers/MailHandler.cpp b/src/server/game/Handlers/MailHandler.cpp
index aaf6ca39d09..36df5b64f1b 100644
--- a/src/server/game/Handlers/MailHandler.cpp
+++ b/src/server/game/Handlers/MailHandler.cpp
@@ -35,7 +35,7 @@ bool WorldSession::CanOpenMailBox(ObjectGuid guid)
{
if (!HasPermission(rbac::RBAC_PERM_COMMAND_MAILBOX))
{
- TC_LOG_WARN("cheat", "%s attempt open mailbox in cheating way.", _player->GetName().c_str());
+ TC_LOG_WARN("cheat", "%s attempted to open mailbox by using a cheat.", _player->GetName().c_str());
return false;
}
}
@@ -108,7 +108,7 @@ void WorldSession::HandleSendMail(WorldPacket& recvData)
if (!receiverGuid)
{
- TC_LOG_INFO("network", "Player %u is sending mail to %s (GUID: not existed!) with subject %s "
+ TC_LOG_INFO("network", "Player %u is sending mail to %s (GUID: non-existing!) with subject %s "
"and body %s includes %u items, %u copper and %u COD copper with unk1 = %u, unk2 = %u",
player->GetGUID().GetCounter(), receiverName.c_str(), subject.c_str(), body.c_str(),
items_count, money, COD, stationery, package);
@@ -117,7 +117,7 @@ void WorldSession::HandleSendMail(WorldPacket& recvData)
}
TC_LOG_INFO("network", "Player %u is sending mail to %s (%s) with subject %s and body %s "
- "includes %u items, %u copper and %u COD copper with unk1 = %u, unk2 = %u",
+ "including %u items, %u copper and %u COD copper with unk1 = %u, unk2 = %u",
player->GetGUID().GetCounter(), receiverName.c_str(), receiverGuid.ToString().c_str(), subject.c_str(),
body.c_str(), items_count, money, COD, stationery, package);
diff --git a/src/server/game/Mails/Mail.cpp b/src/server/game/Mails/Mail.cpp
index b0e8a1ebe02..bc31a3c8c06 100644
--- a/src/server/game/Mails/Mail.cpp
+++ b/src/server/game/Mails/Mail.cpp
@@ -49,8 +49,8 @@ MailSender::MailSender(Object* sender, MailStationery stationery) : m_stationery
break;
default:
m_messageType = MAIL_NORMAL;
- m_senderId = 0; // will show mail from not existed player
- TC_LOG_ERROR("misc", "MailSender::MailSender - Mail have unexpected sender typeid (%u)", sender->GetTypeId());
+ m_senderId = 0; // will show mail from non-existing player
+ TC_LOG_ERROR("misc", "MailSender::MailSender - Mail message contains unexpected sender typeid (%u).", sender->GetTypeId());
break;
}
}
diff --git a/src/server/game/Movement/MotionMaster.cpp b/src/server/game/Movement/MotionMaster.cpp
index 05948b987ad..2a57524cb3c 100644
--- a/src/server/game/Movement/MotionMaster.cpp
+++ b/src/server/game/Movement/MotionMaster.cpp
@@ -193,7 +193,7 @@ void MotionMaster::MoveRandom(float spawndist)
{
if (_owner->GetTypeId() == TYPEID_UNIT)
{
- TC_LOG_DEBUG("misc", "Creature (GUID: %u) start moving random", _owner->GetGUID().GetCounter());
+ TC_LOG_DEBUG("misc", "Creature (GUID: %u) started random movement.", _owner->GetGUID().GetCounter());
Mutate(new RandomMovementGenerator<Creature>(spawndist), MOTION_SLOT_IDLE);
}
}
@@ -204,22 +204,22 @@ void MotionMaster::MoveTargetedHome()
if (_owner->GetTypeId() == TYPEID_UNIT && !_owner->ToCreature()->GetCharmerOrOwnerGUID())
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) targeted home", _owner->GetEntry(), _owner->GetGUID().GetCounter());
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) targeted home.", _owner->GetEntry(), _owner->GetGUID().GetCounter());
Mutate(new HomeMovementGenerator<Creature>(), MOTION_SLOT_ACTIVE);
}
else if (_owner->GetTypeId() == TYPEID_UNIT && _owner->ToCreature()->GetCharmerOrOwnerGUID())
{
- TC_LOG_DEBUG("misc", "Pet or controlled creature (Entry: %u GUID: %u) targeting home", _owner->GetEntry(), _owner->GetGUID().GetCounter());
+ TC_LOG_DEBUG("misc", "Pet or controlled creature (Entry: %u GUID: %u) is targeting home.", _owner->GetEntry(), _owner->GetGUID().GetCounter());
Unit* target = _owner->ToCreature()->GetCharmerOrOwner();
if (target)
{
- TC_LOG_DEBUG("misc", "Following %s (GUID: %u)", target->GetTypeId() == TYPEID_PLAYER ? "player" : "creature", target->GetTypeId() == TYPEID_PLAYER ? target->GetGUID().GetCounter() : ((Creature*)target)->GetSpawnId());
+ TC_LOG_DEBUG("misc", "Following %s (GUID: %u).", target->GetTypeId() == TYPEID_PLAYER ? "player" : "creature", target->GetTypeId() == TYPEID_PLAYER ? target->GetGUID().GetCounter() : ((Creature*)target)->GetSpawnId());
Mutate(new FollowMovementGenerator<Creature>(target, PET_FOLLOW_DIST, PET_FOLLOW_ANGLE), MOTION_SLOT_ACTIVE);
}
}
else
{
- TC_LOG_ERROR("misc", "Player (GUID: %u) attempt targeted home", _owner->GetGUID().GetCounter());
+ TC_LOG_ERROR("misc", "Player (GUID: %u) attempted to move towards target home.", _owner->GetGUID().GetCounter());
}
}
@@ -272,14 +272,14 @@ void MotionMaster::MoveFollow(Unit* target, float dist, float angle, MovementSlo
//_owner->AddUnitState(UNIT_STATE_FOLLOW);
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_DEBUG("misc", "Player (GUID: %u) follow to %s (GUID: %u)", _owner->GetGUID().GetCounter(),
+ TC_LOG_DEBUG("misc", "Player (GUID: %u) follows %s (GUID: %u).", _owner->GetGUID().GetCounter(),
target->GetTypeId() == TYPEID_PLAYER ? "player" : "creature",
target->GetTypeId() == TYPEID_PLAYER ? target->GetGUID().GetCounter() : target->ToCreature()->GetSpawnId());
Mutate(new FollowMovementGenerator<Player>(target, dist, angle), slot);
}
else
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) follow to %s (GUID: %u)",
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) follows %s (GUID: %u).",
_owner->GetEntry(), _owner->GetGUID().GetCounter(),
target->GetTypeId() == TYPEID_PLAYER ? "player" : "creature",
target->GetTypeId() == TYPEID_PLAYER ? target->GetGUID().GetCounter() : target->ToCreature()->GetSpawnId());
@@ -291,12 +291,12 @@ void MotionMaster::MovePoint(uint32 id, float x, float y, float z, bool generate
{
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_DEBUG("misc", "Player (GUID: %u) targeted point (Id: %u X: %f Y: %f Z: %f)", _owner->GetGUID().GetCounter(), id, x, y, z);
+ TC_LOG_DEBUG("misc", "Player (GUID: %u) targeted point (Id: %u X: %f Y: %f Z: %f).", _owner->GetGUID().GetCounter(), id, x, y, z);
Mutate(new PointMovementGenerator<Player>(id, x, y, z, generatePath), MOTION_SLOT_ACTIVE);
}
else
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) targeted point (ID: %u X: %f Y: %f Z: %f)",
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) targeted point (ID: %u X: %f Y: %f Z: %f).",
_owner->GetEntry(), _owner->GetGUID().GetCounter(), id, x, y, z);
Mutate(new PointMovementGenerator<Creature>(id, x, y, z, generatePath), MOTION_SLOT_ACTIVE);
}
@@ -307,7 +307,7 @@ void MotionMaster::MoveLand(uint32 id, Position const& pos)
float x, y, z;
pos.GetPosition(x, y, z);
- TC_LOG_DEBUG("misc", "Creature (Entry: %u) landing point (ID: %u X: %f Y: %f Z: %f)", _owner->GetEntry(), id, x, y, z);
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u) landing point (ID: %u X: %f Y: %f Z: %f).", _owner->GetEntry(), id, x, y, z);
Movement::MoveSplineInit init(_owner);
init.MoveTo(x, y, z);
@@ -321,7 +321,7 @@ void MotionMaster::MoveTakeoff(uint32 id, Position const& pos)
float x, y, z;
pos.GetPosition(x, y, z);
- TC_LOG_DEBUG("misc", "Creature (Entry: %u) landing point (ID: %u X: %f Y: %f Z: %f)", _owner->GetEntry(), id, x, y, z);
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u) landing point (ID: %u X: %f Y: %f Z: %f).", _owner->GetEntry(), id, x, y, z);
Movement::MoveSplineInit init(_owner);
init.MoveTo(x, y, z);
@@ -371,7 +371,7 @@ void MotionMaster::MoveJumpTo(float angle, float speedXY, float speedZ)
void MotionMaster::MoveJump(float x, float y, float z, float o, float speedXY, float speedZ, uint32 id, bool hasOrientation /* = false*/)
{
- TC_LOG_DEBUG("misc", "Unit (GUID: %u) jump to point (X: %f Y: %f Z: %f)", _owner->GetGUID().GetCounter(), x, y, z);
+ TC_LOG_DEBUG("misc", "Unit (GUID: %u) jumps to point (X: %f Y: %f Z: %f).", _owner->GetGUID().GetCounter(), x, y, z);
if (speedXY <= 0.1f)
return;
@@ -449,7 +449,7 @@ void MotionMaster::MoveFall(uint32 id /*=0*/)
float tz = _owner->GetMap()->GetHeight(_owner->GetPhaseMask(), _owner->GetPositionX(), _owner->GetPositionY(), _owner->GetPositionZ(), true, MAX_FALL_DISTANCE);
if (tz <= INVALID_HEIGHT)
{
- TC_LOG_DEBUG("misc", "MotionMaster::MoveFall: unable retrive a proper height at map %u (x: %f, y: %f, z: %f).",
+ TC_LOG_DEBUG("misc", "MotionMaster::MoveFall: unable to retrieve a proper height at map %u (x: %f, y: %f, z: %f).",
_owner->GetMap()->GetId(), _owner->GetPositionX(), _owner->GetPositionY(), _owner->GetPositionZ());
return;
}
@@ -478,12 +478,12 @@ void MotionMaster::MoveCharge(float x, float y, float z, float speed /*= SPEED_C
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_DEBUG("misc", "Player (GUID: %u) charge point (X: %f Y: %f Z: %f)", _owner->GetGUID().GetCounter(), x, y, z);
+ TC_LOG_DEBUG("misc", "Player (GUID: %u) charged point (X: %f Y: %f Z: %f).", _owner->GetGUID().GetCounter(), x, y, z);
Mutate(new PointMovementGenerator<Player>(id, x, y, z, generatePath, speed), MOTION_SLOT_CONTROLLED);
}
else
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) charge point (X: %f Y: %f Z: %f)",
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) charged point (X: %f Y: %f Z: %f).",
_owner->GetEntry(), _owner->GetGUID().GetCounter(), x, y, z);
Mutate(new PointMovementGenerator<Creature>(id, x, y, z, generatePath, speed), MOTION_SLOT_CONTROLLED);
}
@@ -506,7 +506,7 @@ void MotionMaster::MoveSeekAssistance(float x, float y, float z)
{
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_ERROR("misc", "Player (GUID: %u) attempt to seek assistance", _owner->GetGUID().GetCounter());
+ TC_LOG_ERROR("misc", "Player (GUID: %u) attempted to seek assistance.", _owner->GetGUID().GetCounter());
}
else
{
@@ -522,11 +522,11 @@ void MotionMaster::MoveSeekAssistanceDistract(uint32 time)
{
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_ERROR("misc", "Player (GUID: %u) attempt to call distract after assistance", _owner->GetGUID().GetCounter());
+ TC_LOG_ERROR("misc", "Player (GUID: %u) attempted to call distract assistance.", _owner->GetGUID().GetCounter());
}
else
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) is distracted after assistance call (Time: %u)",
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) is distracted after assistance call (Time: %u).",
_owner->GetEntry(), _owner->GetGUID().GetCounter(), time);
Mutate(new AssistanceDistractMovementGenerator(time), MOTION_SLOT_ACTIVE);
}
@@ -539,14 +539,14 @@ void MotionMaster::MoveFleeing(Unit* enemy, uint32 time)
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_DEBUG("misc", "Player (GUID: %u) flee from %s (GUID: %u)", _owner->GetGUID().GetCounter(),
+ TC_LOG_DEBUG("misc", "Player (GUID: %u) flees from %s (GUID: %u).", _owner->GetGUID().GetCounter(),
enemy->GetTypeId() == TYPEID_PLAYER ? "player" : "creature",
enemy->GetTypeId() == TYPEID_PLAYER ? enemy->GetGUID().GetCounter() : enemy->ToCreature()->GetSpawnId());
Mutate(new FleeingMovementGenerator<Player>(enemy->GetGUID()), MOTION_SLOT_CONTROLLED);
}
else
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) flee from %s (GUID: %u)%s",
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) flees from %s (GUID: %u)%s.",
_owner->GetEntry(), _owner->GetGUID().GetCounter(),
enemy->GetTypeId() == TYPEID_PLAYER ? "player" : "creature",
enemy->GetTypeId() == TYPEID_PLAYER ? enemy->GetGUID().GetCounter() : enemy->ToCreature()->GetSpawnId(),
@@ -564,20 +564,20 @@ void MotionMaster::MoveTaxiFlight(uint32 path, uint32 pathnode)
{
if (path < sTaxiPathNodesByPath.size())
{
- TC_LOG_DEBUG("misc", "%s taxi to (Path %u node %u)", _owner->GetName().c_str(), path, pathnode);
+ TC_LOG_DEBUG("misc", "%s taxi to (Path %u node %u).", _owner->GetName().c_str(), path, pathnode);
FlightPathMovementGenerator* mgen = new FlightPathMovementGenerator(pathnode);
mgen->LoadPath(_owner->ToPlayer());
Mutate(mgen, MOTION_SLOT_CONTROLLED);
}
else
{
- TC_LOG_ERROR("misc", "%s attempt taxi to (not existed Path %u node %u)",
+ TC_LOG_ERROR("misc", "%s attempted taxi to (non-existing Path %u node %u).",
_owner->GetName().c_str(), path, pathnode);
}
}
else
{
- TC_LOG_ERROR("misc", "Creature (Entry: %u GUID: %u) attempt taxi to (Path %u node %u)",
+ TC_LOG_ERROR("misc", "Creature (Entry: %u GUID: %u) attempted taxi to (Path %u node %u).",
_owner->GetEntry(), _owner->GetGUID().GetCounter(), path, pathnode);
}
}
@@ -589,11 +589,11 @@ void MotionMaster::MoveDistract(uint32 timer)
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
- TC_LOG_DEBUG("misc", "Player (GUID: %u) distracted (timer: %u)", _owner->GetGUID().GetCounter(), timer);
+ TC_LOG_DEBUG("misc", "Player (GUID: %u) distracted (timer: %u).", _owner->GetGUID().GetCounter(), timer);
}
else
{
- TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) (timer: %u)",
+ TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) distracted (timer: %u)",
_owner->GetEntry(), _owner->GetGUID().GetCounter(), timer);
}
@@ -645,7 +645,7 @@ void MotionMaster::MovePath(uint32 path_id, bool repeatable)
//Mutate(new WaypointMovementGenerator<Player>(path_id, repeatable)):
Mutate(new WaypointMovementGenerator<Creature>(path_id, repeatable), MOTION_SLOT_IDLE);
- TC_LOG_DEBUG("misc", "%s (GUID: %u) start moving over path(Id:%u, repeatable: %s)",
+ TC_LOG_DEBUG("misc", "%s (GUID: %u) starts moving over path(Id:%u, repeatable: %s).",
_owner->GetTypeId() == TYPEID_PLAYER ? "Player" : "Creature",
_owner->GetGUID().GetCounter(), path_id, repeatable ? "YES" : "NO");
}
diff --git a/src/server/game/Scripting/ScriptLoader.cpp b/src/server/game/Scripting/ScriptLoader.cpp
index 2922e4ef58d..07ac1a2ed5b 100644
--- a/src/server/game/Scripting/ScriptLoader.cpp
+++ b/src/server/game/Scripting/ScriptLoader.cpp
@@ -18,1404 +18,36 @@
#include "ScriptLoader.h"
#include "World.h"
-// spells
-void AddSC_deathknight_spell_scripts();
-void AddSC_druid_spell_scripts();
-void AddSC_generic_spell_scripts();
-void AddSC_hunter_spell_scripts();
-void AddSC_mage_spell_scripts();
-void AddSC_paladin_spell_scripts();
-void AddSC_priest_spell_scripts();
-void AddSC_rogue_spell_scripts();
-void AddSC_shaman_spell_scripts();
-void AddSC_warlock_spell_scripts();
-void AddSC_warrior_spell_scripts();
-void AddSC_quest_spell_scripts();
-void AddSC_item_spell_scripts();
-void AddSC_holiday_spell_scripts();
-
+void AddSpellsScripts();
void AddSC_SmartScripts();
-
-//Commands
-void AddSC_account_commandscript();
-void AddSC_achievement_commandscript();
-void AddSC_ahbot_commandscript();
-void AddSC_arena_commandscript();
-void AddSC_ban_commandscript();
-void AddSC_bf_commandscript();
-void AddSC_cast_commandscript();
-void AddSC_character_commandscript();
-void AddSC_cheat_commandscript();
-void AddSC_debug_commandscript();
-void AddSC_deserter_commandscript();
-void AddSC_disable_commandscript();
-void AddSC_event_commandscript();
-void AddSC_gm_commandscript();
-void AddSC_go_commandscript();
-void AddSC_gobject_commandscript();
-void AddSC_group_commandscript();
-void AddSC_guild_commandscript();
-void AddSC_honor_commandscript();
-void AddSC_instance_commandscript();
-void AddSC_learn_commandscript();
-void AddSC_lfg_commandscript();
-void AddSC_list_commandscript();
-void AddSC_lookup_commandscript();
-void AddSC_message_commandscript();
-void AddSC_misc_commandscript();
-void AddSC_mmaps_commandscript();
-void AddSC_modify_commandscript();
-void AddSC_npc_commandscript();
-void AddSC_pet_commandscript();
-void AddSC_quest_commandscript();
-void AddSC_rbac_commandscript();
-void AddSC_reload_commandscript();
-void AddSC_reset_commandscript();
-void AddSC_send_commandscript();
-void AddSC_server_commandscript();
-void AddSC_tele_commandscript();
-void AddSC_ticket_commandscript();
-void AddSC_titles_commandscript();
-void AddSC_wp_commandscript();
+void AddCommandsScripts();
#ifdef SCRIPTS
-//world
-void AddSC_areatrigger_scripts();
-void AddSC_emerald_dragons();
-void AddSC_generic_creature();
-void AddSC_go_scripts();
-void AddSC_guards();
-void AddSC_item_scripts();
-void AddSC_npc_professions();
-void AddSC_npc_innkeeper();
-void AddSC_npcs_special();
-void AddSC_achievement_scripts();
-void AddSC_action_ip_logger();
-void AddSC_duel_reset();
-
-//eastern kingdoms
-void AddSC_alterac_valley(); //Alterac Valley
-void AddSC_boss_balinda();
-void AddSC_boss_drekthar();
-void AddSC_boss_galvangar();
-void AddSC_boss_vanndar();
-void AddSC_blackrock_depths(); //Blackrock Depths
-void AddSC_boss_ambassador_flamelash();
-void AddSC_boss_draganthaurissan();
-void AddSC_boss_general_angerforge();
-void AddSC_boss_high_interrogator_gerstahn();
-void AddSC_boss_magmus();
-void AddSC_boss_moira_bronzebeard();
-void AddSC_boss_tomb_of_seven();
-void AddSC_instance_blackrock_depths();
-void AddSC_boss_drakkisath(); //Blackrock Spire
-void AddSC_boss_halycon();
-void AddSC_boss_highlordomokk();
-void AddSC_boss_mothersmolderweb();
-void AddSC_boss_overlordwyrmthalak();
-void AddSC_boss_shadowvosh();
-void AddSC_boss_thebeast();
-void AddSC_boss_warmastervoone();
-void AddSC_boss_quatermasterzigris();
-void AddSC_boss_pyroguard_emberseer();
-void AddSC_boss_gyth();
-void AddSC_boss_rend_blackhand();
-void AddSC_boss_gizrul_the_slavener();
-void AddSC_boss_urok_doomhowl();
-void AddSC_boss_lord_valthalak();
-void AddSC_instance_blackrock_spire();
-void AddSC_boss_razorgore(); //Blackwing lair
-void AddSC_boss_vaelastrasz();
-void AddSC_boss_broodlord();
-void AddSC_boss_firemaw();
-void AddSC_boss_ebonroc();
-void AddSC_boss_flamegor();
-void AddSC_boss_chromaggus();
-void AddSC_boss_nefarian();
-void AddSC_instance_blackwing_lair();
-void AddSC_deadmines(); //Deadmines
-void AddSC_instance_deadmines();
-void AddSC_boss_mr_smite();
-void AddSC_gnomeregan(); //Gnomeregan
-void AddSC_instance_gnomeregan();
-void AddSC_boss_attumen(); //Karazhan
-void AddSC_boss_curator();
-void AddSC_boss_maiden_of_virtue();
-void AddSC_boss_shade_of_aran();
-void AddSC_boss_malchezaar();
-void AddSC_boss_terestian_illhoof();
-void AddSC_boss_moroes();
-void AddSC_bosses_opera();
-void AddSC_boss_netherspite();
-void AddSC_instance_karazhan();
-void AddSC_karazhan();
-void AddSC_boss_nightbane();
-void AddSC_boss_felblood_kaelthas(); // Magister's Terrace
-void AddSC_boss_selin_fireheart();
-void AddSC_boss_vexallus();
-void AddSC_boss_priestess_delrissa();
-void AddSC_instance_magisters_terrace();
-void AddSC_magisters_terrace();
-void AddSC_boss_lucifron(); //Molten core
-void AddSC_boss_magmadar();
-void AddSC_boss_gehennas();
-void AddSC_boss_garr();
-void AddSC_boss_baron_geddon();
-void AddSC_boss_shazzrah();
-void AddSC_boss_golemagg();
-void AddSC_boss_sulfuron();
-void AddSC_boss_majordomo();
-void AddSC_boss_ragnaros();
-void AddSC_instance_molten_core();
-void AddSC_instance_ragefire_chasm(); //Ragefire Chasm
-void AddSC_the_scarlet_enclave(); //Scarlet Enclave
-void AddSC_the_scarlet_enclave_c1();
-void AddSC_the_scarlet_enclave_c2();
-void AddSC_the_scarlet_enclave_c5();
-void AddSC_boss_arcanist_doan(); //Scarlet Monastery
-void AddSC_boss_azshir_the_sleepless();
-void AddSC_boss_bloodmage_thalnos();
-void AddSC_boss_headless_horseman();
-void AddSC_boss_herod();
-void AddSC_boss_high_inquisitor_fairbanks();
-void AddSC_boss_houndmaster_loksey();
-void AddSC_boss_interrogator_vishas();
-void AddSC_boss_scorn();
-void AddSC_instance_scarlet_monastery();
-void AddSC_boss_mograine_and_whitemane();
-void AddSC_boss_darkmaster_gandling(); //Scholomance
-void AddSC_boss_death_knight_darkreaver();
-void AddSC_boss_theolenkrastinov();
-void AddSC_boss_illuciabarov();
-void AddSC_boss_instructormalicia();
-void AddSC_boss_jandicebarov();
-void AddSC_boss_kormok();
-void AddSC_boss_lordalexeibarov();
-void AddSC_boss_lorekeeperpolkelt();
-void AddSC_boss_rasfrost();
-void AddSC_boss_theravenian();
-void AddSC_boss_vectus();
-void AddSC_boss_kirtonos_the_herald();
-void AddSC_instance_scholomance();
-void AddSC_shadowfang_keep(); //Shadowfang keep
-void AddSC_instance_shadowfang_keep();
-void AddSC_boss_magistrate_barthilas(); //Stratholme
-void AddSC_boss_maleki_the_pallid();
-void AddSC_boss_nerubenkan();
-void AddSC_boss_cannon_master_willey();
-void AddSC_boss_baroness_anastari();
-void AddSC_boss_ramstein_the_gorger();
-void AddSC_boss_timmy_the_cruel();
-void AddSC_boss_postmaster_malown();
-void AddSC_boss_baron_rivendare();
-void AddSC_boss_dathrohan_balnazzar();
-void AddSC_boss_order_of_silver_hand();
-void AddSC_instance_stratholme();
-void AddSC_stratholme();
-void AddSC_sunken_temple(); // Sunken Temple
-void AddSC_instance_sunken_temple();
-void AddSC_instance_sunwell_plateau(); //Sunwell Plateau
-void AddSC_boss_kalecgos();
-void AddSC_boss_brutallus();
-void AddSC_boss_felmyst();
-void AddSC_boss_eredar_twins();
-void AddSC_boss_muru();
-void AddSC_boss_kiljaeden();
-void AddSC_sunwell_plateau();
-void AddSC_boss_archaedas(); //Uldaman
-void AddSC_boss_ironaya();
-void AddSC_uldaman();
-void AddSC_instance_uldaman();
-void AddSC_instance_the_stockade(); //The Stockade
-void AddSC_boss_akilzon(); //Zul'Aman
-void AddSC_boss_halazzi();
-void AddSC_boss_hex_lord_malacrass();
-void AddSC_boss_janalai();
-void AddSC_boss_nalorakk();
-void AddSC_boss_zuljin();
-void AddSC_instance_zulaman();
-void AddSC_zulaman();
-void AddSC_boss_jeklik(); //Zul'Gurub
-void AddSC_boss_venoxis();
-void AddSC_boss_marli();
-void AddSC_boss_mandokir();
-void AddSC_boss_gahzranka();
-void AddSC_boss_thekal();
-void AddSC_boss_arlokk();
-void AddSC_boss_jindo();
-void AddSC_boss_hakkar();
-void AddSC_boss_grilek();
-void AddSC_boss_hazzarah();
-void AddSC_boss_renataki();
-void AddSC_boss_wushoolay();
-void AddSC_instance_zulgurub();
-
-//void AddSC_alterac_mountains();
-void AddSC_arathi_highlands();
-void AddSC_blasted_lands();
-void AddSC_burning_steppes();
-void AddSC_duskwood();
-void AddSC_eastern_plaguelands();
-void AddSC_ghostlands();
-void AddSC_hinterlands();
-void AddSC_isle_of_queldanas();
-void AddSC_loch_modan();
-void AddSC_redridge_mountains();
-void AddSC_silverpine_forest();
-void AddSC_stormwind_city();
-void AddSC_stranglethorn_vale();
-void AddSC_swamp_of_sorrows();
-void AddSC_tirisfal_glades();
-void AddSC_undercity();
-void AddSC_western_plaguelands();
-void AddSC_wetlands();
-
-//kalimdor
-void AddSC_blackfathom_deeps(); //Blackfathom Depths
-void AddSC_boss_gelihast();
-void AddSC_boss_kelris();
-void AddSC_boss_aku_mai();
-void AddSC_instance_blackfathom_deeps();
-void AddSC_hyjal(); //CoT Battle for Mt. Hyjal
-void AddSC_boss_archimonde();
-void AddSC_instance_mount_hyjal();
-void AddSC_hyjal_trash();
-void AddSC_boss_rage_winterchill();
-void AddSC_boss_anetheron();
-void AddSC_boss_kazrogal();
-void AddSC_boss_azgalor();
-void AddSC_boss_captain_skarloc(); //CoT Old Hillsbrad
-void AddSC_boss_epoch_hunter();
-void AddSC_boss_lieutenant_drake();
-void AddSC_instance_old_hillsbrad();
-void AddSC_old_hillsbrad();
-void AddSC_boss_aeonus(); //CoT The Black Morass
-void AddSC_boss_chrono_lord_deja();
-void AddSC_boss_temporus();
-void AddSC_the_black_morass();
-void AddSC_instance_the_black_morass();
-void AddSC_boss_epoch(); //CoT Culling Of Stratholme
-void AddSC_boss_infinite_corruptor();
-void AddSC_boss_salramm();
-void AddSC_boss_mal_ganis();
-void AddSC_boss_meathook();
-void AddSC_culling_of_stratholme();
-void AddSC_instance_culling_of_stratholme();
-void AddSC_instance_dire_maul(); //Dire Maul
-void AddSC_boss_celebras_the_cursed(); //Maraudon
-void AddSC_boss_landslide();
-void AddSC_boss_noxxion();
-void AddSC_boss_ptheradras();
-void AddSC_instance_maraudon();
-void AddSC_boss_onyxia(); //Onyxia's Lair
-void AddSC_instance_onyxias_lair();
-void AddSC_boss_tuten_kash(); //Razorfen Downs
-void AddSC_boss_mordresh_fire_eye();
-void AddSC_boss_glutton();
-void AddSC_boss_amnennar_the_coldbringer();
-void AddSC_razorfen_downs();
-void AddSC_instance_razorfen_downs();
-void AddSC_razorfen_kraul(); //Razorfen Kraul
-void AddSC_instance_razorfen_kraul();
-void AddSC_boss_kurinnaxx(); //Ruins of ahn'qiraj
-void AddSC_boss_rajaxx();
-void AddSC_boss_moam();
-void AddSC_boss_buru();
-void AddSC_boss_ayamiss();
-void AddSC_boss_ossirian();
-void AddSC_instance_ruins_of_ahnqiraj();
-void AddSC_boss_cthun(); //Temple of ahn'qiraj
-void AddSC_boss_viscidus();
-void AddSC_boss_fankriss();
-void AddSC_boss_huhuran();
-void AddSC_bug_trio();
-void AddSC_boss_sartura();
-void AddSC_boss_skeram();
-void AddSC_boss_twinemperors();
-void AddSC_boss_ouro();
-void AddSC_npc_anubisath_sentinel();
-void AddSC_instance_temple_of_ahnqiraj();
-void AddSC_wailing_caverns(); //Wailing caverns
-void AddSC_instance_wailing_caverns();
-void AddSC_boss_zum_rah(); //Zul'Farrak
-void AddSC_zulfarrak();
-void AddSC_instance_zulfarrak();
-
-void AddSC_ashenvale();
-void AddSC_azshara();
-void AddSC_azuremyst_isle();
-void AddSC_bloodmyst_isle();
-void AddSC_boss_azuregos();
-void AddSC_darkshore();
-void AddSC_desolace();
-void AddSC_durotar();
-void AddSC_dustwallow_marsh();
-void AddSC_felwood();
-void AddSC_feralas();
-void AddSC_moonglade();
-void AddSC_orgrimmar();
-void AddSC_silithus();
-void AddSC_stonetalon_mountains();
-void AddSC_tanaris();
-void AddSC_the_barrens();
-void AddSC_thousand_needles();
-void AddSC_thunder_bluff();
-void AddSC_ungoro_crater();
-void AddSC_winterspring();
-
-// Northrend
-
-void AddSC_boss_slad_ran();
-void AddSC_boss_moorabi();
-void AddSC_boss_drakkari_colossus();
-void AddSC_boss_gal_darah();
-void AddSC_boss_eck();
-void AddSC_instance_gundrak();
-
-// Azjol-Nerub - Azjol-Nerub
-void AddSC_boss_krik_thir();
-void AddSC_boss_hadronox();
-void AddSC_boss_anub_arak();
-void AddSC_instance_azjol_nerub();
-
-// Azjol-Nerub - Ahn'kahet
-void AddSC_boss_elder_nadox();
-void AddSC_boss_taldaram();
-void AddSC_boss_amanitar();
-void AddSC_boss_jedoga_shadowseeker();
-void AddSC_boss_volazj();
-void AddSC_instance_ahnkahet();
-
-// Drak'Tharon Keep
-void AddSC_boss_trollgore();
-void AddSC_boss_novos();
-void AddSC_boss_king_dred();
-void AddSC_boss_tharon_ja();
-void AddSC_instance_drak_tharon_keep();
-
-void AddSC_boss_argent_challenge(); //Trial of the Champion
-void AddSC_boss_black_knight();
-void AddSC_boss_grand_champions();
-void AddSC_instance_trial_of_the_champion();
-void AddSC_trial_of_the_champion();
-void AddSC_boss_anubarak_trial(); //Trial of the Crusader
-void AddSC_boss_faction_champions();
-void AddSC_boss_jaraxxus();
-void AddSC_boss_northrend_beasts();
-void AddSC_boss_twin_valkyr();
-void AddSC_trial_of_the_crusader();
-void AddSC_instance_trial_of_the_crusader();
-void AddSC_boss_anubrekhan(); //Naxxramas
-void AddSC_boss_maexxna();
-void AddSC_boss_patchwerk();
-void AddSC_boss_grobbulus();
-void AddSC_boss_razuvious();
-void AddSC_boss_kelthuzad();
-void AddSC_boss_loatheb();
-void AddSC_boss_noth();
-void AddSC_boss_gluth();
-void AddSC_boss_sapphiron();
-void AddSC_boss_four_horsemen();
-void AddSC_boss_faerlina();
-void AddSC_boss_heigan();
-void AddSC_boss_gothik();
-void AddSC_boss_thaddius();
-void AddSC_instance_naxxramas();
-void AddSC_boss_nexus_commanders(); // The Nexus Nexus
-void AddSC_boss_magus_telestra();
-void AddSC_boss_anomalus();
-void AddSC_boss_ormorok();
-void AddSC_boss_keristrasza();
-void AddSC_instance_nexus();
-void AddSC_boss_drakos(); //The Nexus The Oculus
-void AddSC_boss_urom();
-void AddSC_boss_varos();
-void AddSC_boss_eregos();
-void AddSC_instance_oculus();
-void AddSC_oculus();
-void AddSC_boss_malygos(); // The Nexus: Eye of Eternity
-void AddSC_instance_eye_of_eternity();
-void AddSC_boss_sartharion(); //Obsidian Sanctum
-void AddSC_obsidian_sanctum();
-void AddSC_instance_obsidian_sanctum();
-void AddSC_boss_bjarngrim(); //Ulduar Halls of Lightning
-void AddSC_boss_loken();
-void AddSC_boss_ionar();
-void AddSC_boss_volkhan();
-void AddSC_instance_halls_of_lightning();
-void AddSC_boss_maiden_of_grief(); //Ulduar Halls of Stone
-void AddSC_boss_krystallus();
-void AddSC_boss_sjonnir();
-void AddSC_instance_halls_of_stone();
-void AddSC_halls_of_stone();
-void AddSC_boss_auriaya(); //Ulduar Ulduar
-void AddSC_boss_flame_leviathan();
-void AddSC_boss_ignis();
-void AddSC_boss_razorscale();
-void AddSC_boss_xt002();
-void AddSC_boss_kologarn();
-void AddSC_boss_assembly_of_iron();
-void AddSC_boss_general_vezax();
-void AddSC_boss_mimiron();
-void AddSC_boss_hodir();
-void AddSC_boss_freya();
-void AddSC_boss_yogg_saron();
-void AddSC_boss_algalon_the_observer();
-void AddSC_instance_ulduar();
-
-// Utgarde Keep - Utgarde Keep
-void AddSC_boss_keleseth();
-void AddSC_boss_skarvald_dalronn();
-void AddSC_boss_ingvar_the_plunderer();
-void AddSC_instance_utgarde_keep();
-void AddSC_utgarde_keep();
-
-// Utgarde Keep - Utgarde Pinnacle
-void AddSC_boss_svala();
-void AddSC_boss_palehoof();
-void AddSC_boss_skadi();
-void AddSC_boss_ymiron();
-void AddSC_instance_utgarde_pinnacle();
-
-// Vault of Archavon
-void AddSC_boss_archavon();
-void AddSC_boss_emalon();
-void AddSC_boss_koralon();
-void AddSC_boss_toravon();
-void AddSC_instance_vault_of_archavon();
-
-void AddSC_boss_cyanigosa(); //Violet Hold
-void AddSC_boss_erekem();
-void AddSC_boss_ichoron();
-void AddSC_boss_lavanthor();
-void AddSC_boss_moragg();
-void AddSC_boss_xevozz();
-void AddSC_boss_zuramat();
-void AddSC_instance_violet_hold();
-void AddSC_violet_hold();
-void AddSC_instance_forge_of_souls(); //Forge of Souls
-void AddSC_forge_of_souls();
-void AddSC_boss_bronjahm();
-void AddSC_boss_devourer_of_souls();
-void AddSC_instance_pit_of_saron(); //Pit of Saron
-void AddSC_pit_of_saron();
-void AddSC_boss_garfrost();
-void AddSC_boss_ick();
-void AddSC_boss_tyrannus();
-void AddSC_instance_halls_of_reflection(); // Halls of Reflection
-void AddSC_halls_of_reflection();
-void AddSC_boss_falric();
-void AddSC_boss_marwyn();
-void AddSC_boss_lord_marrowgar(); // Icecrown Citadel
-void AddSC_boss_lady_deathwhisper();
-void AddSC_boss_icecrown_gunship_battle();
-void AddSC_boss_deathbringer_saurfang();
-void AddSC_boss_festergut();
-void AddSC_boss_rotface();
-void AddSC_boss_professor_putricide();
-void AddSC_boss_blood_prince_council();
-void AddSC_boss_blood_queen_lana_thel();
-void AddSC_boss_valithria_dreamwalker();
-void AddSC_boss_sindragosa();
-void AddSC_boss_the_lich_king();
-void AddSC_icecrown_citadel_teleport();
-void AddSC_instance_icecrown_citadel();
-void AddSC_icecrown_citadel();
-void AddSC_instance_ruby_sanctum(); // Ruby Sanctum
-void AddSC_ruby_sanctum();
-void AddSC_boss_baltharus_the_warborn();
-void AddSC_boss_saviana_ragefire();
-void AddSC_boss_general_zarithrian();
-void AddSC_boss_halion();
-
-void AddSC_dalaran();
-void AddSC_borean_tundra();
-void AddSC_dragonblight();
-void AddSC_grizzly_hills();
-void AddSC_howling_fjord();
-void AddSC_icecrown();
-void AddSC_sholazar_basin();
-void AddSC_storm_peaks();
-void AddSC_wintergrasp();
-void AddSC_zuldrak();
-void AddSC_crystalsong_forest();
-void AddSC_isle_of_conquest();
-
-// Outland
-
-// Auchindoun - Auchenai Crypts
-void AddSC_boss_shirrak_the_dead_watcher();
-void AddSC_boss_exarch_maladaar();
-void AddSC_instance_auchenai_crypts();
-
-// Auchindoun - Mana Tombs
-void AddSC_boss_pandemonius();
-void AddSC_boss_nexusprince_shaffar();
-void AddSC_instance_mana_tombs();
-
-// Auchindoun - Sekketh Halls
-void AddSC_boss_darkweaver_syth();
-void AddSC_boss_talon_king_ikiss();
-void AddSC_boss_anzu();
-void AddSC_instance_sethekk_halls();
-
-// Auchindoun - Shadow Labyrinth
-void AddSC_boss_ambassador_hellmaw();
-void AddSC_boss_blackheart_the_inciter();
-void AddSC_boss_grandmaster_vorpil();
-void AddSC_boss_murmur();
-void AddSC_instance_shadow_labyrinth();
-
-// Black Temple
-void AddSC_black_temple();
-void AddSC_boss_illidan();
-void AddSC_boss_shade_of_akama();
-void AddSC_boss_supremus();
-void AddSC_boss_gurtogg_bloodboil();
-void AddSC_boss_mother_shahraz();
-void AddSC_boss_reliquary_of_souls();
-void AddSC_boss_teron_gorefiend();
-void AddSC_boss_najentus();
-void AddSC_boss_illidari_council();
-void AddSC_instance_black_temple();
-
-// Coilfang Reservoir - Serpent Shrine Cavern
-void AddSC_boss_fathomlord_karathress();
-void AddSC_boss_hydross_the_unstable();
-void AddSC_boss_lady_vashj();
-void AddSC_boss_leotheras_the_blind();
-void AddSC_boss_morogrim_tidewalker();
-void AddSC_instance_serpentshrine_cavern();
-void AddSC_boss_the_lurker_below();
-
-// Coilfang Reservoir - The Steam Vault
-void AddSC_boss_hydromancer_thespia();
-void AddSC_boss_mekgineer_steamrigger();
-void AddSC_boss_warlord_kalithresh();
-void AddSC_instance_steam_vault();
-
-// Coilfang Reservoir - The Slave Pens
-void AddSC_instance_the_slave_pens();
-void AddSC_boss_mennu_the_betrayer();
-void AddSC_boss_rokmar_the_crackler();
-void AddSC_boss_quagmirran();
-
-// Coilfang Reservoir - The Underbog
-void AddSC_instance_the_underbog();
-void AddSC_boss_hungarfen();
-void AddSC_boss_the_black_stalker();
-
-// Gruul's Lair
-void AddSC_boss_gruul();
-void AddSC_boss_high_king_maulgar();
-void AddSC_instance_gruuls_lair();
-void AddSC_boss_broggok(); //HC Blood Furnace
-void AddSC_boss_kelidan_the_breaker();
-void AddSC_boss_the_maker();
-void AddSC_instance_blood_furnace();
-void AddSC_boss_magtheridon(); //HC Magtheridon's Lair
-void AddSC_instance_magtheridons_lair();
-void AddSC_boss_grand_warlock_nethekurse(); //HC Shattered Halls
-void AddSC_boss_warbringer_omrogg();
-void AddSC_boss_warchief_kargath_bladefist();
-void AddSC_shattered_halls();
-void AddSC_instance_shattered_halls();
-void AddSC_boss_watchkeeper_gargolmar(); //HC Ramparts
-void AddSC_boss_omor_the_unscarred();
-void AddSC_boss_vazruden_the_herald();
-void AddSC_instance_ramparts();
-void AddSC_arcatraz(); //TK Arcatraz
-void AddSC_boss_zereketh_the_unbound();
-void AddSC_boss_dalliah_the_doomsayer();
-void AddSC_boss_wrath_scryer_soccothrates();
-void AddSC_boss_harbinger_skyriss();
-void AddSC_instance_arcatraz();
-void AddSC_boss_high_botanist_freywinn(); //TK Botanica
-void AddSC_boss_laj();
-void AddSC_boss_warp_splinter();
-void AddSC_boss_thorngrin_the_tender();
-void AddSC_boss_commander_sarannis();
-void AddSC_instance_the_botanica();
-void AddSC_boss_alar(); //TK The Eye
-void AddSC_boss_kaelthas();
-void AddSC_boss_void_reaver();
-void AddSC_boss_high_astromancer_solarian();
-void AddSC_instance_the_eye();
-void AddSC_the_eye();
-void AddSC_boss_gatewatcher_iron_hand(); //TK The Mechanar
-void AddSC_boss_gatewatcher_gyrokill();
-void AddSC_boss_nethermancer_sepethrea();
-void AddSC_boss_pathaleon_the_calculator();
-void AddSC_boss_mechano_lord_capacitus();
-void AddSC_instance_mechanar();
-
-void AddSC_blades_edge_mountains();
-void AddSC_boss_doomlordkazzak();
-void AddSC_boss_doomwalker();
-void AddSC_hellfire_peninsula();
-void AddSC_nagrand();
-void AddSC_netherstorm();
-void AddSC_shadowmoon_valley();
-void AddSC_shattrath_city();
-void AddSC_terokkar_forest();
-void AddSC_zangarmarsh();
-
-// Events
-void AddSC_event_childrens_week();
-
-// Pets
-void AddSC_deathknight_pet_scripts();
-void AddSC_generic_pet_scripts();
-void AddSC_hunter_pet_scripts();
-void AddSC_mage_pet_scripts();
-void AddSC_priest_pet_scripts();
-void AddSC_shaman_pet_scripts();
-
-// battlegrounds
-
-// outdoor pvp
-void AddSC_outdoorpvp_ep();
-void AddSC_outdoorpvp_hp();
-void AddSC_outdoorpvp_na();
-void AddSC_outdoorpvp_si();
-void AddSC_outdoorpvp_tf();
-void AddSC_outdoorpvp_zm();
-
-// player
-void AddSC_chat_log();
-void AddSC_action_ip_logger();
-
+void AddWorldScripts();
+void AddEasternKingdomsScripts();
+void AddKalimdorScripts();
+void AddOutlandScripts();
+void AddNorthrendScripts();
+void AddEventsScripts();
+void AddPetScripts();
+void AddOutdoorPvPScripts();
+void AddCustomScripts();
#endif
void AddScripts()
{
- AddSpellScripts();
+ AddSpellsScripts();
AddSC_SmartScripts();
- AddCommandScripts();
+ AddCommandsScripts();
#ifdef SCRIPTS
AddWorldScripts();
AddEasternKingdomsScripts();
AddKalimdorScripts();
AddOutlandScripts();
AddNorthrendScripts();
- AddEventScripts();
+ AddEventsScripts();
AddPetScripts();
- AddBattlegroundScripts();
AddOutdoorPvPScripts();
AddCustomScripts();
#endif
}
-
-void AddSpellScripts()
-{
- AddSC_deathknight_spell_scripts();
- AddSC_druid_spell_scripts();
- AddSC_generic_spell_scripts();
- AddSC_hunter_spell_scripts();
- AddSC_mage_spell_scripts();
- AddSC_paladin_spell_scripts();
- AddSC_priest_spell_scripts();
- AddSC_rogue_spell_scripts();
- AddSC_shaman_spell_scripts();
- AddSC_warlock_spell_scripts();
- AddSC_warrior_spell_scripts();
- AddSC_quest_spell_scripts();
- AddSC_item_spell_scripts();
- AddSC_holiday_spell_scripts();
-}
-
-void AddCommandScripts()
-{
- AddSC_account_commandscript();
- AddSC_achievement_commandscript();
- AddSC_ahbot_commandscript();
- AddSC_arena_commandscript();
- AddSC_ban_commandscript();
- AddSC_bf_commandscript();
- AddSC_cast_commandscript();
- AddSC_character_commandscript();
- AddSC_cheat_commandscript();
- AddSC_debug_commandscript();
- AddSC_deserter_commandscript();
- AddSC_disable_commandscript();
- AddSC_event_commandscript();
- AddSC_gm_commandscript();
- AddSC_go_commandscript();
- AddSC_gobject_commandscript();
- AddSC_group_commandscript();
- AddSC_guild_commandscript();
- AddSC_honor_commandscript();
- AddSC_instance_commandscript();
- AddSC_learn_commandscript();
- AddSC_lookup_commandscript();
- AddSC_lfg_commandscript();
- AddSC_list_commandscript();
- AddSC_message_commandscript();
- AddSC_misc_commandscript();
- AddSC_mmaps_commandscript();
- AddSC_modify_commandscript();
- AddSC_npc_commandscript();
- AddSC_quest_commandscript();
- AddSC_pet_commandscript();
- AddSC_rbac_commandscript();
- AddSC_reload_commandscript();
- AddSC_reset_commandscript();
- AddSC_send_commandscript();
- AddSC_server_commandscript();
- AddSC_tele_commandscript();
- AddSC_ticket_commandscript();
- AddSC_titles_commandscript();
- AddSC_wp_commandscript();
-}
-
-void AddWorldScripts()
-{
-#ifdef SCRIPTS
- AddSC_areatrigger_scripts();
- AddSC_emerald_dragons();
- AddSC_generic_creature();
- AddSC_go_scripts();
- AddSC_guards();
- AddSC_item_scripts();
- AddSC_npc_professions();
- AddSC_npc_innkeeper();
- AddSC_npcs_special();
- AddSC_achievement_scripts();
- AddSC_chat_log(); // location: scripts\World\chat_log.cpp
- // To avoid duplicate code, we check once /*ONLY*/ if logging is permitted or not.
- if (sWorld->getBoolConfig(CONFIG_IP_BASED_ACTION_LOGGING))
- AddSC_action_ip_logger(); // location: scripts\World\action_ip_logger.cpp
- AddSC_duel_reset();
-#endif
-}
-
-void AddEasternKingdomsScripts()
-{
-#ifdef SCRIPTS
- AddSC_alterac_valley(); //Alterac Valley
- AddSC_boss_balinda();
- AddSC_boss_drekthar();
- AddSC_boss_galvangar();
- AddSC_boss_vanndar();
- AddSC_blackrock_depths(); //Blackrock Depths
- AddSC_boss_ambassador_flamelash();
- AddSC_boss_draganthaurissan();
- AddSC_boss_general_angerforge();
- AddSC_boss_high_interrogator_gerstahn();
- AddSC_boss_magmus();
- AddSC_boss_moira_bronzebeard();
- AddSC_boss_tomb_of_seven();
- AddSC_instance_blackrock_depths();
- AddSC_boss_drakkisath(); //Blackrock Spire
- AddSC_boss_halycon();
- AddSC_boss_highlordomokk();
- AddSC_boss_mothersmolderweb();
- AddSC_boss_overlordwyrmthalak();
- AddSC_boss_shadowvosh();
- AddSC_boss_thebeast();
- AddSC_boss_warmastervoone();
- AddSC_boss_quatermasterzigris();
- AddSC_boss_pyroguard_emberseer();
- AddSC_boss_gyth();
- AddSC_boss_rend_blackhand();
- AddSC_boss_gizrul_the_slavener();
- AddSC_boss_urok_doomhowl();
- AddSC_boss_lord_valthalak();
- AddSC_instance_blackrock_spire();
- AddSC_boss_razorgore(); //Blackwing lair
- AddSC_boss_vaelastrasz();
- AddSC_boss_broodlord();
- AddSC_boss_firemaw();
- AddSC_boss_ebonroc();
- AddSC_boss_flamegor();
- AddSC_boss_chromaggus();
- AddSC_boss_nefarian();
- AddSC_instance_blackwing_lair();
- AddSC_deadmines(); //Deadmines
- AddSC_boss_mr_smite();
- AddSC_instance_deadmines();
- AddSC_gnomeregan(); //Gnomeregan
- AddSC_instance_gnomeregan();
- AddSC_boss_attumen(); //Karazhan
- AddSC_boss_curator();
- AddSC_boss_maiden_of_virtue();
- AddSC_boss_shade_of_aran();
- AddSC_boss_malchezaar();
- AddSC_boss_terestian_illhoof();
- AddSC_boss_moroes();
- AddSC_bosses_opera();
- AddSC_boss_netherspite();
- AddSC_instance_karazhan();
- AddSC_karazhan();
- AddSC_boss_nightbane();
- AddSC_boss_felblood_kaelthas(); // Magister's Terrace
- AddSC_boss_selin_fireheart();
- AddSC_boss_vexallus();
- AddSC_boss_priestess_delrissa();
- AddSC_instance_magisters_terrace();
- AddSC_magisters_terrace();
- AddSC_boss_lucifron(); //Molten core
- AddSC_boss_magmadar();
- AddSC_boss_gehennas();
- AddSC_boss_garr();
- AddSC_boss_baron_geddon();
- AddSC_boss_shazzrah();
- AddSC_boss_golemagg();
- AddSC_boss_sulfuron();
- AddSC_boss_majordomo();
- AddSC_boss_ragnaros();
- AddSC_instance_molten_core();
- AddSC_instance_ragefire_chasm(); //Ragefire Chasm
- AddSC_the_scarlet_enclave(); //Scarlet Enclave
- AddSC_the_scarlet_enclave_c1();
- AddSC_the_scarlet_enclave_c2();
- AddSC_the_scarlet_enclave_c5();
- AddSC_boss_arcanist_doan(); //Scarlet Monastery
- AddSC_boss_azshir_the_sleepless();
- AddSC_boss_bloodmage_thalnos();
- AddSC_boss_headless_horseman();
- AddSC_boss_herod();
- AddSC_boss_high_inquisitor_fairbanks();
- AddSC_boss_houndmaster_loksey();
- AddSC_boss_interrogator_vishas();
- AddSC_boss_scorn();
- AddSC_instance_scarlet_monastery();
- AddSC_boss_mograine_and_whitemane();
- AddSC_boss_darkmaster_gandling(); //Scholomance
- AddSC_boss_death_knight_darkreaver();
- AddSC_boss_theolenkrastinov();
- AddSC_boss_illuciabarov();
- AddSC_boss_instructormalicia();
- AddSC_boss_jandicebarov();
- AddSC_boss_kormok();
- AddSC_boss_lordalexeibarov();
- AddSC_boss_lorekeeperpolkelt();
- AddSC_boss_rasfrost();
- AddSC_boss_theravenian();
- AddSC_boss_vectus();
- AddSC_boss_kirtonos_the_herald();
- AddSC_instance_scholomance();
- AddSC_shadowfang_keep(); //Shadowfang keep
- AddSC_instance_shadowfang_keep();
- AddSC_boss_magistrate_barthilas(); //Stratholme
- AddSC_boss_maleki_the_pallid();
- AddSC_boss_nerubenkan();
- AddSC_boss_cannon_master_willey();
- AddSC_boss_baroness_anastari();
- AddSC_boss_ramstein_the_gorger();
- AddSC_boss_timmy_the_cruel();
- AddSC_boss_postmaster_malown();
- AddSC_boss_baron_rivendare();
- AddSC_boss_dathrohan_balnazzar();
- AddSC_boss_order_of_silver_hand();
- AddSC_instance_stratholme();
- AddSC_stratholme();
- AddSC_sunken_temple(); // Sunken Temple
- AddSC_instance_sunken_temple();
- AddSC_instance_sunwell_plateau(); //Sunwell Plateau
- AddSC_boss_kalecgos();
- AddSC_boss_brutallus();
- AddSC_boss_felmyst();
- AddSC_boss_eredar_twins();
- AddSC_boss_muru();
- AddSC_boss_kiljaeden();
- AddSC_sunwell_plateau();
- AddSC_instance_the_stockade(); //The Stockade
- AddSC_boss_archaedas(); //Uldaman
- AddSC_boss_ironaya();
- AddSC_uldaman();
- AddSC_instance_uldaman();
- AddSC_boss_akilzon(); //Zul'Aman
- AddSC_boss_halazzi();
- AddSC_boss_hex_lord_malacrass();
- AddSC_boss_janalai();
- AddSC_boss_nalorakk();
- AddSC_boss_zuljin();
- AddSC_instance_zulaman();
- AddSC_zulaman();
- AddSC_boss_jeklik(); //Zul'Gurub
- AddSC_boss_venoxis();
- AddSC_boss_marli();
- AddSC_boss_mandokir();
- AddSC_boss_gahzranka();
- AddSC_boss_thekal();
- AddSC_boss_arlokk();
- AddSC_boss_jindo();
- AddSC_boss_hakkar();
- AddSC_boss_grilek();
- AddSC_boss_hazzarah();
- AddSC_boss_renataki();
- AddSC_boss_wushoolay();
- AddSC_instance_zulgurub();
-
- //AddSC_alterac_mountains();
- AddSC_arathi_highlands();
- AddSC_blasted_lands();
- AddSC_burning_steppes();
- AddSC_duskwood();
- AddSC_eastern_plaguelands();
- AddSC_ghostlands();
- AddSC_hinterlands();
- AddSC_isle_of_queldanas();
- AddSC_loch_modan();
- AddSC_redridge_mountains();
- AddSC_silverpine_forest();
- AddSC_stormwind_city();
- AddSC_stranglethorn_vale();
- AddSC_swamp_of_sorrows();
- AddSC_tirisfal_glades();
- AddSC_undercity();
- AddSC_western_plaguelands();
- AddSC_wetlands();
-#endif
-}
-
-void AddKalimdorScripts()
-{
-#ifdef SCRIPTS
- AddSC_blackfathom_deeps(); //Blackfathom Depths
- AddSC_boss_gelihast();
- AddSC_boss_kelris();
- AddSC_boss_aku_mai();
- AddSC_instance_blackfathom_deeps();
- AddSC_hyjal(); //CoT Battle for Mt. Hyjal
- AddSC_boss_archimonde();
- AddSC_instance_mount_hyjal();
- AddSC_hyjal_trash();
- AddSC_boss_rage_winterchill();
- AddSC_boss_anetheron();
- AddSC_boss_kazrogal();
- AddSC_boss_azgalor();
- AddSC_boss_captain_skarloc(); //CoT Old Hillsbrad
- AddSC_boss_epoch_hunter();
- AddSC_boss_lieutenant_drake();
- AddSC_instance_old_hillsbrad();
- AddSC_old_hillsbrad();
- AddSC_boss_aeonus(); //CoT The Black Morass
- AddSC_boss_chrono_lord_deja();
- AddSC_boss_temporus();
- AddSC_the_black_morass();
- AddSC_instance_the_black_morass();
- AddSC_boss_epoch(); //CoT Culling Of Stratholme
- AddSC_boss_infinite_corruptor();
- AddSC_boss_salramm();
- AddSC_boss_mal_ganis();
- AddSC_boss_meathook();
- AddSC_culling_of_stratholme();
- AddSC_instance_culling_of_stratholme();
- AddSC_instance_dire_maul(); //Dire Maul
- AddSC_boss_celebras_the_cursed(); //Maraudon
- AddSC_boss_landslide();
- AddSC_boss_noxxion();
- AddSC_boss_ptheradras();
- AddSC_instance_maraudon();
- AddSC_boss_onyxia(); //Onyxia's Lair
- AddSC_instance_onyxias_lair();
- AddSC_boss_tuten_kash(); //Razorfen Downs
- AddSC_boss_mordresh_fire_eye();
- AddSC_boss_glutton();
- AddSC_boss_amnennar_the_coldbringer();
- AddSC_razorfen_downs();
- AddSC_instance_razorfen_downs();
- AddSC_razorfen_kraul(); //Razorfen Kraul
- AddSC_instance_razorfen_kraul();
- AddSC_boss_kurinnaxx(); //Ruins of ahn'qiraj
- AddSC_boss_rajaxx();
- AddSC_boss_moam();
- AddSC_boss_buru();
- AddSC_boss_ayamiss();
- AddSC_boss_ossirian();
- AddSC_instance_ruins_of_ahnqiraj();
- AddSC_boss_cthun(); //Temple of ahn'qiraj
- AddSC_boss_viscidus();
- AddSC_boss_fankriss();
- AddSC_boss_huhuran();
- AddSC_bug_trio();
- AddSC_boss_sartura();
- AddSC_boss_skeram();
- AddSC_boss_twinemperors();
- AddSC_boss_ouro();
- AddSC_npc_anubisath_sentinel();
- AddSC_instance_temple_of_ahnqiraj();
- AddSC_wailing_caverns(); //Wailing caverns
- AddSC_instance_wailing_caverns();
- AddSC_boss_zum_rah(); //Zul'Farrak
- AddSC_zulfarrak();
- AddSC_instance_zulfarrak();
-
- AddSC_ashenvale();
- AddSC_azshara();
- AddSC_azuremyst_isle();
- AddSC_bloodmyst_isle();
- AddSC_boss_azuregos();
- AddSC_darkshore();
- AddSC_desolace();
- AddSC_durotar();
- AddSC_dustwallow_marsh();
- AddSC_felwood();
- AddSC_feralas();
- AddSC_moonglade();
- AddSC_orgrimmar();
- AddSC_silithus();
- AddSC_stonetalon_mountains();
- AddSC_tanaris();
- AddSC_the_barrens();
- AddSC_thousand_needles();
- AddSC_thunder_bluff();
- AddSC_ungoro_crater();
- AddSC_winterspring();
-#endif
-}
-
-void AddOutlandScripts()
-{
-#ifdef SCRIPTS
- // Auchindoun - Auchenai Crypts
- AddSC_boss_shirrak_the_dead_watcher();
- AddSC_boss_exarch_maladaar();
- AddSC_instance_auchenai_crypts();
-
- // Auchindoun - Mana Tombs
- AddSC_boss_pandemonius();
- AddSC_boss_nexusprince_shaffar();
- AddSC_instance_mana_tombs();
-
- // Auchindoun - Sekketh Halls
- AddSC_boss_darkweaver_syth();
- AddSC_boss_talon_king_ikiss();
- AddSC_boss_anzu();
- AddSC_instance_sethekk_halls();
-
- // Auchindoun - Shadow Labyrinth
- AddSC_boss_ambassador_hellmaw();
- AddSC_boss_blackheart_the_inciter();
- AddSC_boss_grandmaster_vorpil();
- AddSC_boss_murmur();
- AddSC_instance_shadow_labyrinth();
-
- // Black Temple
- AddSC_black_temple();
- AddSC_boss_illidan();
- AddSC_boss_shade_of_akama();
- AddSC_boss_supremus();
- AddSC_boss_gurtogg_bloodboil();
- AddSC_boss_mother_shahraz();
- AddSC_boss_reliquary_of_souls();
- AddSC_boss_teron_gorefiend();
- AddSC_boss_najentus();
- AddSC_boss_illidari_council();
- AddSC_instance_black_temple();
-
- // Coilfang Reservoir - Serpent Shrine Cavern
- AddSC_boss_fathomlord_karathress();
- AddSC_boss_hydross_the_unstable();
- AddSC_boss_lady_vashj();
- AddSC_boss_leotheras_the_blind();
- AddSC_boss_morogrim_tidewalker();
- AddSC_instance_serpentshrine_cavern();
- AddSC_boss_the_lurker_below();
-
- // Coilfang Reservoir - The Steam Vault
- AddSC_instance_steam_vault();
- AddSC_boss_hydromancer_thespia();
- AddSC_boss_mekgineer_steamrigger();
- AddSC_boss_warlord_kalithresh();
-
- // Coilfang Reservoir - The Slave Pens
- AddSC_instance_the_slave_pens();
- AddSC_boss_mennu_the_betrayer();
- AddSC_boss_rokmar_the_crackler();
- AddSC_boss_quagmirran();
-
- // Coilfang Reservoir - The Underbog
- AddSC_instance_the_underbog();
- AddSC_boss_hungarfen();
- AddSC_boss_the_black_stalker();
-
- // Gruul's Lair
- AddSC_boss_gruul();
- AddSC_boss_high_king_maulgar();
- AddSC_instance_gruuls_lair();
- AddSC_boss_broggok(); //HC Blood Furnace
- AddSC_boss_kelidan_the_breaker();
- AddSC_boss_the_maker();
- AddSC_instance_blood_furnace();
- AddSC_boss_magtheridon(); //HC Magtheridon's Lair
- AddSC_instance_magtheridons_lair();
- AddSC_boss_grand_warlock_nethekurse(); //HC Shattered Halls
- AddSC_boss_warbringer_omrogg();
- AddSC_boss_warchief_kargath_bladefist();
- AddSC_shattered_halls();
- AddSC_instance_shattered_halls();
- AddSC_boss_watchkeeper_gargolmar(); //HC Ramparts
- AddSC_boss_omor_the_unscarred();
- AddSC_boss_vazruden_the_herald();
- AddSC_instance_ramparts();
- AddSC_arcatraz(); //TK Arcatraz
- AddSC_boss_zereketh_the_unbound();
- AddSC_boss_dalliah_the_doomsayer();
- AddSC_boss_wrath_scryer_soccothrates();
- AddSC_boss_harbinger_skyriss();
- AddSC_instance_arcatraz();
- AddSC_boss_high_botanist_freywinn(); //TK Botanica
- AddSC_boss_laj();
- AddSC_boss_warp_splinter();
- AddSC_boss_thorngrin_the_tender();
- AddSC_boss_commander_sarannis();
- AddSC_instance_the_botanica();
- AddSC_boss_alar(); //TK The Eye
- AddSC_boss_kaelthas();
- AddSC_boss_void_reaver();
- AddSC_boss_high_astromancer_solarian();
- AddSC_instance_the_eye();
- AddSC_the_eye();
- AddSC_boss_gatewatcher_iron_hand(); //TK The Mechanar
- AddSC_boss_gatewatcher_gyrokill();
- AddSC_boss_nethermancer_sepethrea();
- AddSC_boss_pathaleon_the_calculator();
- AddSC_boss_mechano_lord_capacitus();
- AddSC_instance_mechanar();
-
- AddSC_blades_edge_mountains();
- AddSC_boss_doomlordkazzak();
- AddSC_boss_doomwalker();
- AddSC_hellfire_peninsula();
- AddSC_nagrand();
- AddSC_netherstorm();
- AddSC_shadowmoon_valley();
- AddSC_shattrath_city();
- AddSC_terokkar_forest();
- AddSC_zangarmarsh();
-#endif
-}
-
-void AddNorthrendScripts()
-{
-#ifdef SCRIPTS
- AddSC_boss_slad_ran(); //Gundrak
- AddSC_boss_moorabi();
- AddSC_boss_drakkari_colossus();
- AddSC_boss_gal_darah();
- AddSC_boss_eck();
- AddSC_instance_gundrak();
-
- // Azjol-Nerub - Ahn'kahet
- AddSC_boss_elder_nadox();
- AddSC_boss_taldaram();
- AddSC_boss_amanitar();
- AddSC_boss_jedoga_shadowseeker();
- AddSC_boss_volazj();
- AddSC_instance_ahnkahet();
-
- // Azjol-Nerub - Azjol-Nerub
- AddSC_boss_krik_thir();
- AddSC_boss_hadronox();
- AddSC_boss_anub_arak();
- AddSC_instance_azjol_nerub();
-
- // Drak'Tharon Keep
- AddSC_boss_trollgore();
- AddSC_boss_novos();
- AddSC_boss_king_dred();
- AddSC_boss_tharon_ja();
- AddSC_instance_drak_tharon_keep();
-
- AddSC_boss_argent_challenge(); //Trial of the Champion
- AddSC_boss_black_knight();
- AddSC_boss_grand_champions();
- AddSC_instance_trial_of_the_champion();
- AddSC_trial_of_the_champion();
- AddSC_boss_anubarak_trial(); //Trial of the Crusader
- AddSC_boss_faction_champions();
- AddSC_boss_jaraxxus();
- AddSC_trial_of_the_crusader();
- AddSC_boss_twin_valkyr();
- AddSC_boss_northrend_beasts();
- AddSC_instance_trial_of_the_crusader();
- AddSC_boss_anubrekhan(); //Naxxramas
- AddSC_boss_maexxna();
- AddSC_boss_patchwerk();
- AddSC_boss_grobbulus();
- AddSC_boss_razuvious();
- AddSC_boss_kelthuzad();
- AddSC_boss_loatheb();
- AddSC_boss_noth();
- AddSC_boss_gluth();
- AddSC_boss_sapphiron();
- AddSC_boss_four_horsemen();
- AddSC_boss_faerlina();
- AddSC_boss_heigan();
- AddSC_boss_gothik();
- AddSC_boss_thaddius();
- AddSC_instance_naxxramas();
- AddSC_boss_nexus_commanders(); // The Nexus Nexus
- AddSC_boss_magus_telestra();
- AddSC_boss_anomalus();
- AddSC_boss_ormorok();
- AddSC_boss_keristrasza();
- AddSC_instance_nexus();
- AddSC_boss_drakos(); //The Nexus The Oculus
- AddSC_boss_urom();
- AddSC_boss_varos();
- AddSC_boss_eregos();
- AddSC_instance_oculus();
- AddSC_oculus();
- AddSC_boss_malygos(); // The Nexus: Eye of Eternity
- AddSC_instance_eye_of_eternity();
- AddSC_boss_sartharion(); //Obsidian Sanctum
- AddSC_obsidian_sanctum();
- AddSC_instance_obsidian_sanctum();
- AddSC_boss_bjarngrim(); //Ulduar Halls of Lightning
- AddSC_boss_loken();
- AddSC_boss_ionar();
- AddSC_boss_volkhan();
- AddSC_instance_halls_of_lightning();
- AddSC_boss_maiden_of_grief(); //Ulduar Halls of Stone
- AddSC_boss_krystallus();
- AddSC_boss_sjonnir();
- AddSC_instance_halls_of_stone();
- AddSC_halls_of_stone();
- AddSC_boss_auriaya(); //Ulduar Ulduar
- AddSC_boss_flame_leviathan();
- AddSC_boss_ignis();
- AddSC_boss_razorscale();
- AddSC_boss_xt002();
- AddSC_boss_general_vezax();
- AddSC_boss_assembly_of_iron();
- AddSC_boss_kologarn();
- AddSC_boss_mimiron();
- AddSC_boss_hodir();
- AddSC_boss_freya();
- AddSC_boss_yogg_saron();
- AddSC_boss_algalon_the_observer();
- AddSC_instance_ulduar();
-
- // Utgarde Keep - Utgarde Keep
- AddSC_boss_keleseth();
- AddSC_boss_skarvald_dalronn();
- AddSC_boss_ingvar_the_plunderer();
- AddSC_instance_utgarde_keep();
- AddSC_utgarde_keep();
-
- // Utgarde Keep - Utgarde Pinnacle
- AddSC_boss_svala();
- AddSC_boss_palehoof();
- AddSC_boss_skadi();
- AddSC_boss_ymiron();
- AddSC_instance_utgarde_pinnacle();
-
- // Vault of Archavon
- AddSC_boss_archavon();
- AddSC_boss_emalon();
- AddSC_boss_koralon();
- AddSC_boss_toravon();
- AddSC_instance_vault_of_archavon();
-
- AddSC_boss_cyanigosa(); //Violet Hold
- AddSC_boss_erekem();
- AddSC_boss_ichoron();
- AddSC_boss_lavanthor();
- AddSC_boss_moragg();
- AddSC_boss_xevozz();
- AddSC_boss_zuramat();
- AddSC_instance_violet_hold();
- AddSC_violet_hold();
- AddSC_instance_forge_of_souls(); //Forge of Souls
- AddSC_forge_of_souls();
- AddSC_boss_bronjahm();
- AddSC_boss_devourer_of_souls();
- AddSC_instance_pit_of_saron(); //Pit of Saron
- AddSC_pit_of_saron();
- AddSC_boss_garfrost();
- AddSC_boss_ick();
- AddSC_boss_tyrannus();
- AddSC_instance_halls_of_reflection(); // Halls of Reflection
- AddSC_halls_of_reflection();
- AddSC_boss_falric();
- AddSC_boss_marwyn();
- AddSC_boss_lord_marrowgar(); // Icecrown Citadel
- AddSC_boss_lady_deathwhisper();
- AddSC_boss_icecrown_gunship_battle();
- AddSC_boss_deathbringer_saurfang();
- AddSC_boss_festergut();
- AddSC_boss_rotface();
- AddSC_boss_professor_putricide();
- AddSC_boss_blood_prince_council();
- AddSC_boss_blood_queen_lana_thel();
- AddSC_boss_valithria_dreamwalker();
- AddSC_boss_sindragosa();
- AddSC_boss_the_lich_king();
- AddSC_icecrown_citadel_teleport();
- AddSC_instance_icecrown_citadel();
- AddSC_icecrown_citadel();
- AddSC_instance_ruby_sanctum(); // Ruby Sanctum
- AddSC_ruby_sanctum();
- AddSC_boss_baltharus_the_warborn();
- AddSC_boss_saviana_ragefire();
- AddSC_boss_general_zarithrian();
- AddSC_boss_halion();
-
- AddSC_dalaran();
- AddSC_borean_tundra();
- AddSC_dragonblight();
- AddSC_grizzly_hills();
- AddSC_howling_fjord();
- AddSC_icecrown();
- AddSC_sholazar_basin();
- AddSC_storm_peaks();
- AddSC_wintergrasp();
- AddSC_zuldrak();
- AddSC_crystalsong_forest();
- AddSC_isle_of_conquest();
-#endif
-}
-
-void AddEventScripts()
-{
-#ifdef SCRIPTS
- AddSC_event_childrens_week();
-#endif
-}
-
-void AddPetScripts()
-{
-#ifdef SCRIPTS
- AddSC_deathknight_pet_scripts();
- AddSC_generic_pet_scripts();
- AddSC_hunter_pet_scripts();
- AddSC_mage_pet_scripts();
- AddSC_priest_pet_scripts();
- AddSC_shaman_pet_scripts();
-#endif
-}
-
-void AddOutdoorPvPScripts()
-{
-#ifdef SCRIPTS
- AddSC_outdoorpvp_ep();
- AddSC_outdoorpvp_hp();
- AddSC_outdoorpvp_na();
- AddSC_outdoorpvp_si();
- AddSC_outdoorpvp_tf();
- AddSC_outdoorpvp_zm();
-#endif
-}
-
-void AddBattlegroundScripts()
-{
-#ifdef SCRIPTS
-#endif
-}
-
-#ifdef SCRIPTS
-/* This is where custom scripts' loading functions should be declared. */
-
-#endif
-
-void AddCustomScripts()
-{
-#ifdef SCRIPTS
- /* This is where custom scripts should be added. */
-
-#endif
-}
diff --git a/src/server/game/Scripting/ScriptLoader.h b/src/server/game/Scripting/ScriptLoader.h
index 4adb215e130..57b62df22d1 100644
--- a/src/server/game/Scripting/ScriptLoader.h
+++ b/src/server/game/Scripting/ScriptLoader.h
@@ -19,17 +19,5 @@
#define SC_SCRIPTLOADER_H
void AddScripts();
-void AddSpellScripts();
-void AddCommandScripts();
-void AddWorldScripts();
-void AddEasternKingdomsScripts();
-void AddKalimdorScripts();
-void AddOutlandScripts();
-void AddNorthrendScripts();
-void AddEventScripts();
-void AddPetScripts();
-void AddBattlegroundScripts();
-void AddOutdoorPvPScripts();
-void AddCustomScripts();
#endif
diff --git a/src/server/game/Server/WorldSocket.cpp b/src/server/game/Server/WorldSocket.cpp
index a2d357cbc4d..36029113055 100644
--- a/src/server/game/Server/WorldSocket.cpp
+++ b/src/server/game/Server/WorldSocket.cpp
@@ -25,6 +25,17 @@
#include <memory>
+class EncryptablePacket : public WorldPacket
+{
+public:
+ EncryptablePacket(WorldPacket const& packet, bool encrypt) : WorldPacket(packet), _encrypt(encrypt) { }
+
+ bool NeedsEncryption() const { return _encrypt; }
+
+private:
+ bool _encrypt;
+};
+
using boost::asio::ip::tcp;
WorldSocket::WorldSocket(tcp::socket&& socket)
@@ -40,11 +51,8 @@ void WorldSocket::Start()
stmt->setString(0, ip_address);
stmt->setUInt32(1, inet_addr(ip_address.c_str()));
- {
- std::lock_guard<std::mutex> guard(_queryLock);
- _queryCallback = io_service().wrap(std::bind(&WorldSocket::CheckIpCallback, this, std::placeholders::_1));
- _queryFuture = LoginDatabase.AsyncQuery(stmt);
- }
+ _queryCallback = std::bind(&WorldSocket::CheckIpCallback, this, std::placeholders::_1);
+ _queryFuture = LoginDatabase.AsyncQuery(stmt);
}
void WorldSocket::CheckIpCallback(PreparedQueryResult result)
@@ -78,17 +86,50 @@ void WorldSocket::CheckIpCallback(PreparedQueryResult result)
bool WorldSocket::Update()
{
+ EncryptablePacket* queued;
+ MessageBuffer buffer;
+ while (_bufferQueue.Dequeue(queued))
+ {
+ ServerPktHeader header(queued->size() + 2, queued->GetOpcode());
+ if (queued->NeedsEncryption())
+ _authCrypt.EncryptSend(header.header, header.getHeaderLength());
+
+ if (buffer.GetRemainingSpace() < queued->size() + header.getHeaderLength())
+ {
+ QueuePacket(std::move(buffer));
+ buffer.Resize(4096);
+ }
+
+ if (buffer.GetRemainingSpace() >= queued->size() + header.getHeaderLength())
+ {
+ buffer.Write(header.header, header.getHeaderLength());
+ if (!queued->empty())
+ buffer.Write(queued->contents(), queued->size());
+ }
+ else // single packet larger than 4096 bytes
+ {
+ MessageBuffer packetBuffer(queued->size() + header.getHeaderLength());
+ packetBuffer.Write(header.header, header.getHeaderLength());
+ if (!queued->empty())
+ packetBuffer.Write(queued->contents(), queued->size());
+
+ QueuePacket(std::move(packetBuffer));
+ }
+
+ delete queued;
+ }
+
+ if (buffer.GetActiveSize() > 0)
+ QueuePacket(std::move(buffer));
+
if (!BaseSocket::Update())
return false;
+ if (_queryFuture.valid() && _queryFuture.wait_for(std::chrono::seconds(0)) == std::future_status::ready)
{
- std::lock_guard<std::mutex> guard(_queryLock);
- if (_queryFuture.valid() && _queryFuture.wait_for(std::chrono::seconds(0)) == std::future_status::ready)
- {
- auto callback = std::move(_queryCallback);
- _queryCallback = nullptr;
- callback(_queryFuture.get());
- }
+ auto callback = _queryCallback;
+ _queryCallback = nullptr;
+ callback(_queryFuture.get());
}
return true;
@@ -351,29 +392,7 @@ void WorldSocket::SendPacket(WorldPacket const& packet)
if (sPacketLog->CanLogPacket())
sPacketLog->LogPacket(packet, SERVER_TO_CLIENT, GetRemoteIpAddress(), GetRemotePort());
- ServerPktHeader header(packet.size() + 2, packet.GetOpcode());
-
- std::unique_lock<std::mutex> guard(_writeLock);
-
- _authCrypt.EncryptSend(header.header, header.getHeaderLength());
-
-#ifndef TC_SOCKET_USE_IOCP
- if (_writeQueue.empty() && _writeBuffer.GetRemainingSpace() >= header.getHeaderLength() + packet.size())
- {
- _writeBuffer.Write(header.header, header.getHeaderLength());
- if (!packet.empty())
- _writeBuffer.Write(packet.contents(), packet.size());
- }
- else
-#endif
- {
- MessageBuffer buffer(header.getHeaderLength() + packet.size());
- buffer.Write(header.header, header.getHeaderLength());
- if (!packet.empty())
- buffer.Write(packet.contents(), packet.size());
-
- QueuePacket(std::move(buffer), guard);
- }
+ _bufferQueue.Enqueue(new EncryptablePacket(packet, _authCrypt.IsInitialized()));
}
void WorldSocket::HandleAuthSession(WorldPacket& recvPacket)
@@ -398,11 +417,8 @@ void WorldSocket::HandleAuthSession(WorldPacket& recvPacket)
stmt->setInt32(0, int32(realmID));
stmt->setString(1, authSession->Account);
- {
- std::lock_guard<std::mutex> guard(_queryLock);
- _queryCallback = io_service().wrap(std::bind(&WorldSocket::HandleAuthSessionCallback, this, authSession, std::placeholders::_1));
- _queryFuture = LoginDatabase.AsyncQuery(stmt);
- }
+ _queryCallback = std::bind(&WorldSocket::HandleAuthSessionCallback, this, authSession, std::placeholders::_1);
+ _queryFuture = LoginDatabase.AsyncQuery(stmt);
}
void WorldSocket::HandleAuthSessionCallback(std::shared_ptr<AuthSession> authSession, PreparedQueryResult result)
@@ -559,7 +575,7 @@ void WorldSocket::HandleAuthSessionCallback(std::shared_ptr<AuthSession> authSes
if (wardenActive)
_worldSession->InitWarden(&account.SessionKey, account.OS);
- _queryCallback = io_service().wrap(std::bind(&WorldSocket::LoadSessionPermissionsCallback, this, std::placeholders::_1));
+ _queryCallback = std::bind(&WorldSocket::LoadSessionPermissionsCallback, this, std::placeholders::_1);
_queryFuture = _worldSession->LoadPermissionsAsync();
AsyncRead();
}
diff --git a/src/server/game/Server/WorldSocket.h b/src/server/game/Server/WorldSocket.h
index 9e5b35992a6..08a5b185cf1 100644
--- a/src/server/game/Server/WorldSocket.h
+++ b/src/server/game/Server/WorldSocket.h
@@ -26,11 +26,13 @@
#include "Util.h"
#include "WorldPacket.h"
#include "WorldSession.h"
+#include "MPSCQueue.h"
#include <chrono>
#include <boost/asio/ip/tcp.hpp>
#include <boost/asio/buffer.hpp>
using boost::asio::ip::tcp;
+class EncryptablePacket;
#pragma pack(push, 1)
@@ -104,8 +106,8 @@ private:
MessageBuffer _headerBuffer;
MessageBuffer _packetBuffer;
+ MPSCQueue<EncryptablePacket> _bufferQueue;
- std::mutex _queryLock;
PreparedQueryResultFuture _queryFuture;
std::function<void(PreparedQueryResult&&)> _queryCallback;
std::string _ipCountry;
diff --git a/src/server/game/Server/WorldSocketMgr.cpp b/src/server/game/Server/WorldSocketMgr.cpp
index 529396b3966..e8f8c59f4af 100644
--- a/src/server/game/Server/WorldSocketMgr.cpp
+++ b/src/server/game/Server/WorldSocketMgr.cpp
@@ -24,9 +24,9 @@
#include <boost/system/error_code.hpp>
-static void OnSocketAccept(tcp::socket&& sock)
+static void OnSocketAccept(tcp::socket&& sock, uint32 threadIndex)
{
- sWorldSocketMgr.OnSocketOpen(std::forward<tcp::socket>(sock));
+ sWorldSocketMgr.OnSocketOpen(std::forward<tcp::socket>(sock), threadIndex);
}
class WorldSocketThread : public NetworkThread<WorldSocket>
@@ -67,7 +67,9 @@ bool WorldSocketMgr::StartNetwork(boost::asio::io_service& service, std::string
BaseSocketMgr::StartNetwork(service, bindIp, port);
- _acceptor->AsyncAcceptManaged(&OnSocketAccept);
+ _acceptor->SetSocketFactory(std::bind(&BaseSocketMgr::GetSocketForAccept, this));
+
+ _acceptor->AsyncAcceptWithCallback<&OnSocketAccept>();
sScriptMgr->OnNetworkStart();
return true;
@@ -80,7 +82,7 @@ void WorldSocketMgr::StopNetwork()
sScriptMgr->OnNetworkStop();
}
-void WorldSocketMgr::OnSocketOpen(tcp::socket&& sock)
+void WorldSocketMgr::OnSocketOpen(tcp::socket&& sock, uint32 threadIndex)
{
// set some options here
if (_socketSendBufferSize >= 0)
@@ -108,7 +110,7 @@ void WorldSocketMgr::OnSocketOpen(tcp::socket&& sock)
//sock->m_OutBufferSize = static_cast<size_t> (m_SockOutUBuff);
- BaseSocketMgr::OnSocketOpen(std::forward<tcp::socket>(sock));
+ BaseSocketMgr::OnSocketOpen(std::forward<tcp::socket>(sock), threadIndex);
}
NetworkThread<WorldSocket>* WorldSocketMgr::CreateThreads() const
diff --git a/src/server/game/Server/WorldSocketMgr.h b/src/server/game/Server/WorldSocketMgr.h
index 92a28d0c135..38e2e7abb69 100644
--- a/src/server/game/Server/WorldSocketMgr.h
+++ b/src/server/game/Server/WorldSocketMgr.h
@@ -47,7 +47,7 @@ public:
/// Stops all network threads, It will wait for all running threads .
void StopNetwork() override;
- void OnSocketOpen(tcp::socket&& sock) override;
+ void OnSocketOpen(tcp::socket&& sock, uint32 threadIndex) override;
protected:
WorldSocketMgr();
diff --git a/src/server/game/Skills/SkillDiscovery.cpp b/src/server/game/Skills/SkillDiscovery.cpp
index 36a7d147192..8860b391f48 100644
--- a/src/server/game/Skills/SkillDiscovery.cpp
+++ b/src/server/game/Skills/SkillDiscovery.cpp
@@ -88,7 +88,7 @@ void LoadSkillDiscoveryTable()
{
if (reportedReqSpells.find(absReqSkillOrSpell) == reportedReqSpells.end())
{
- TC_LOG_ERROR("sql.sql", "Spell (ID: %u) have not existed spell (ID: %i) in `reqSpell` field in `skill_discovery_template` table", spellId, reqSkillOrSpell);
+ TC_LOG_ERROR("sql.sql", "Spell (ID: %u) has a non-existing spell (ID: %i) in `reqSpell` field in the `skill_discovery_template` table.", spellId, reqSkillOrSpell);
reportedReqSpells.insert(absReqSkillOrSpell);
}
continue;
@@ -101,8 +101,8 @@ void LoadSkillDiscoveryTable()
{
if (reportedReqSpells.find(absReqSkillOrSpell) == reportedReqSpells.end())
{
- TC_LOG_ERROR("sql.sql", "Spell (ID: %u) not have MECHANIC_DISCOVERY (28) value in Mechanic field in spell.dbc"
- " and not 100%% chance random discovery ability but listed for spellId %u (and maybe more) in `skill_discovery_template` table",
+ TC_LOG_ERROR("sql.sql", "Spell (ID: %u) does not have any MECHANIC_DISCOVERY (28) value in the Mechanic field in spell.dbc"
+ " nor 100%% chance random discovery ability, but is listed for spellId %u (and maybe more) in the `skill_discovery_template` table.",
absReqSkillOrSpell, spellId);
reportedReqSpells.insert(absReqSkillOrSpell);
}
@@ -117,7 +117,7 @@ void LoadSkillDiscoveryTable()
if (bounds.first == bounds.second)
{
- TC_LOG_ERROR("sql.sql", "Spell (ID: %u) not listed in `SkillLineAbility.dbc` but listed with `reqSpell`=0 in `skill_discovery_template` table", spellId);
+ TC_LOG_ERROR("sql.sql", "Spell (ID: %u) is not listed in `SkillLineAbility.dbc`, but listed with `reqSpell`= 0 in the `skill_discovery_template` table.", spellId);
continue;
}
@@ -126,7 +126,7 @@ void LoadSkillDiscoveryTable()
}
else
{
- TC_LOG_ERROR("sql.sql", "Spell (ID: %u) have negative value in `reqSpell` field in `skill_discovery_template` table", spellId);
+ TC_LOG_ERROR("sql.sql", "Spell (ID: %u) has a negative value in `reqSpell` field in the `skill_discovery_template` table.", spellId);
continue;
}
@@ -135,7 +135,7 @@ void LoadSkillDiscoveryTable()
while (result->NextRow());
if (!ssNonDiscoverableEntries.str().empty())
- TC_LOG_ERROR("sql.sql", "Some items can't be successfully discovered: have in chance field value < 0.000001 in `skill_discovery_template` DB table . List:\n%s", ssNonDiscoverableEntries.str().c_str());
+ TC_LOG_ERROR("sql.sql", "Some items can't be successfully discovered, their chance field value is < 0.000001 in the `skill_discovery_template` DB table. List:\n%s", ssNonDiscoverableEntries.str().c_str());
// report about empty data for explicit discovery spells
for (uint32 spell_id = 1; spell_id < sSpellMgr->GetSpellInfoStoreSize(); ++spell_id)
@@ -149,10 +149,10 @@ void LoadSkillDiscoveryTable()
continue;
if (SkillDiscoveryStore.find(int32(spell_id)) == SkillDiscoveryStore.end())
- TC_LOG_ERROR("sql.sql", "Spell (ID: %u) is 100%% chance random discovery ability but not have data in `skill_discovery_template` table", spell_id);
+ TC_LOG_ERROR("sql.sql", "Spell (ID: %u) has got 100%% chance random discovery ability, but does not have data in the `skill_discovery_template` table.", spell_id);
}
- TC_LOG_INFO("server.loading", ">> Loaded %u skill discovery definitions in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u skill discovery definitions in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
uint32 GetExplicitDiscoverySpell(uint32 spellId, Player* player)
diff --git a/src/server/game/Skills/SkillExtraItems.cpp b/src/server/game/Skills/SkillExtraItems.cpp
index 5213944cc90..f76e4623137 100644
--- a/src/server/game/Skills/SkillExtraItems.cpp
+++ b/src/server/game/Skills/SkillExtraItems.cpp
@@ -74,28 +74,28 @@ void LoadSkillPerfectItemTable()
if (!sSpellMgr->GetSpellInfo(spellId))
{
- TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u has non-existent spell id in `skill_perfect_item_template`!", spellId);
+ TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u has a non-existing spell id in the `skill_perfect_item_template`!", spellId);
continue;
}
uint32 requiredSpecialization = fields[1].GetUInt32();
if (!sSpellMgr->GetSpellInfo(requiredSpecialization))
{
- TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u has non-existent required specialization spell id %u in `skill_perfect_item_template`!", spellId, requiredSpecialization);
+ TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u has a non-existing required specialization spell id %u in the `skill_perfect_item_template`!", spellId, requiredSpecialization);
continue;
}
float perfectCreateChance = fields[2].GetFloat();
if (perfectCreateChance <= 0.0f)
{
- TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u has impossibly low proc chance in `skill_perfect_item_template`!", spellId);
+ TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u has impossibly low proc chance in the `skill_perfect_item_template`!", spellId);
continue;
}
uint32 perfectItemType = fields[3].GetUInt32();
if (!sObjectMgr->GetItemTemplate(perfectItemType))
{
- TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u references non-existent perfect item id %u in `skill_perfect_item_template`!", spellId, perfectItemType);
+ TC_LOG_ERROR("sql.sql", "Skill perfection data for spell %u references a non-existing perfect item id %u in the `skill_perfect_item_template`!", spellId, perfectItemType);
continue;
}
@@ -109,7 +109,7 @@ void LoadSkillPerfectItemTable()
}
while (result->NextRow());
- TC_LOG_INFO("server.loading", ">> Loaded %u spell perfection definitions in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
+ TC_LOG_INFO("server.loading", ">> Loaded %u spell perfection definitions in %u ms.", count, GetMSTimeDiffToNow(oldMSTime));
}
// struct to store information about extra item creation
@@ -161,28 +161,28 @@ void LoadSkillExtraItemTable()
if (!sSpellMgr->GetSpellInfo(spellId))
{
- TC_LOG_ERROR("sql.sql", "Skill specialization %u has non-existent spell id in `skill_extra_item_template`!", spellId);
+ TC_LOG_ERROR("sql.sql", "Skill specialization %u has a non-existing spell id in the `skill_extra_item_template`!", spellId);
continue;
}
uint32 requiredSpecialization = fields[1].GetUInt32();
if (!sSpellMgr->GetSpellInfo(requiredSpecialization))
{
- TC_LOG_ERROR("sql.sql", "Skill specialization %u have not existed required specialization spell id %u in `skill_extra_item_template`!", spellId, requiredSpecialization);
+ TC_LOG_ERROR("sql.sql", "Skill specialization %u has a non-existing required specialization spell id %u in the `skill_extra_item_template`!", spellId, requiredSpecialization);
continue;
}
float additionalCreateChance = fields[2].GetFloat();
if (additionalCreateChance <= 0.0f)
{
- TC_LOG_ERROR("sql.sql", "Skill specialization %u has too low additional create chance in `skill_extra_item_template`!", spellId);
+ TC_LOG_ERROR("sql.sql", "Skill specialization %u has too low additional create chance in the `skill_extra_item_template`!", spellId);
continue;
}
uint8 additionalMaxNum = fields[3].GetUInt8();
if (!additionalMaxNum)
{
- TC_LOG_ERROR("sql.sql", "Skill specialization %u has 0 max number of extra items in `skill_extra_item_template`!", spellId);
+ TC_LOG_ERROR("sql.sql", "Skill specialization %u has 0 max number of extra items in the `skill_extra_item_template`!", spellId);
continue;
}
diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp
index 9535ca291eb..f9bf33553cc 100644
--- a/src/server/game/Spells/SpellEffects.cpp
+++ b/src/server/game/Spells/SpellEffects.cpp
@@ -893,7 +893,7 @@ void Spell::EffectTriggerMissileSpell(SpellEffIndex effIndex)
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(triggered_spell_id);
if (!spellInfo)
{
- TC_LOG_ERROR("spells", "Spell::EffectTriggerMissileSpell spell %u tried to trigger unknown spell %u", m_spellInfo->Id, triggered_spell_id);
+ TC_LOG_ERROR("spells", "Spell::EffectTriggerMissileSpell spell %u tried to trigger unknown spell %u.", m_spellInfo->Id, triggered_spell_id);
return;
}
@@ -944,7 +944,7 @@ void Spell::EffectForceCast(SpellEffIndex effIndex)
if (!spellInfo)
{
- TC_LOG_ERROR("spells", "Spell::EffectForceCast of spell %u: triggering unknown spell id %i", m_spellInfo->Id, triggered_spell_id);
+ TC_LOG_ERROR("spells", "Spell::EffectForceCast of spell %u: triggering unknown spell id %i.", m_spellInfo->Id, triggered_spell_id);
return;
}
@@ -996,7 +996,7 @@ void Spell::EffectTriggerRitualOfSummoning(SpellEffIndex effIndex)
if (!spellInfo)
{
- TC_LOG_ERROR("spells", "EffectTriggerRitualOfSummoning of spell %u: triggering unknown spell id %i", m_spellInfo->Id, triggered_spell_id);
+ TC_LOG_ERROR("spells", "EffectTriggerRitualOfSummoning of spell %u: triggering unknown spell id %i.", m_spellInfo->Id, triggered_spell_id);
return;
}
@@ -1062,7 +1062,7 @@ void Spell::EffectTeleportUnits(SpellEffIndex /*effIndex*/)
// If not exist data for dest location - return
if (!m_targets.HasDst())
{
- TC_LOG_ERROR("spells", "Spell::EffectTeleportUnits - does not have destination for spellId %u.", m_spellInfo->Id);
+ TC_LOG_ERROR("spells", "Spell::EffectTeleportUnits - does not have a destination for spellId %u.", m_spellInfo->Id);
return;
}
@@ -1393,7 +1393,7 @@ void Spell::EffectHeal(SpellEffIndex /*effIndex*/)
if (!targetAura)
{
- TC_LOG_ERROR("spells", "Target (%s) has aurastate AURA_STATE_SWIFTMEND but no matching aura.", unitTarget->GetGUID().ToString().c_str());
+ TC_LOG_ERROR("spells", "Target (%s) has the aurastate AURA_STATE_SWIFTMEND, but no matching aura.", unitTarget->GetGUID().ToString().c_str());
return;
}
@@ -1886,7 +1886,7 @@ void Spell::SendLoot(ObjectGuid guid, LootType loottype)
// Players shouldn't be able to loot gameobjects that are currently despawned
if (!gameObjTarget->isSpawned() && !player->IsGameMaster())
{
- TC_LOG_ERROR("spells", "Possible hacking attempt: Player %s [guid: %u] tried to loot a gameobject [entry: %u id: %u] which is on respawn time without being in GM mode!",
+ TC_LOG_ERROR("spells", "Possible hacking attempt: Player %s [guid: %u] tried to loot a gameobject [entry: %u id: %u] which is on respawn timer without being in GM mode!",
player->GetName().c_str(), player->GetGUID().GetCounter(), gameObjTarget->GetEntry(), gameObjTarget->GetGUID().GetCounter());
return;
}
@@ -2191,7 +2191,7 @@ void Spell::EffectSummonType(SpellEffIndex effIndex)
SummonPropertiesEntry const* properties = sSummonPropertiesStore.LookupEntry(m_spellInfo->Effects[effIndex].MiscValueB);
if (!properties)
{
- TC_LOG_ERROR("spells", "EffectSummonType: Unhandled summon type %u", m_spellInfo->Effects[effIndex].MiscValueB);
+ TC_LOG_ERROR("spells", "EffectSummonType: Unhandled summon type %u.", m_spellInfo->Effects[effIndex].MiscValueB);
return;
}
@@ -2379,7 +2379,7 @@ void Spell::EffectLearnSpell(SpellEffIndex effIndex)
uint32 spellToLearn = (m_spellInfo->Id == 483 || m_spellInfo->Id == 55884) ? damage : m_spellInfo->Effects[effIndex].TriggerSpell;
player->LearnSpell(spellToLearn, false);
- TC_LOG_DEBUG("spells", "Spell: Player %u has learned spell %u from NpcGUID=%u", player->GetGUID().GetCounter(), spellToLearn, m_caster->GetGUID().GetCounter());
+ TC_LOG_DEBUG("spells", "Spell: Player %u has learned spell %u from NpcGUID: %u", player->GetGUID().GetCounter(), spellToLearn, m_caster->GetGUID().GetCounter());
}
void Spell::EffectDispel(SpellEffIndex effIndex)
@@ -2758,7 +2758,7 @@ void Spell::EffectEnchantItemPrismatic(SpellEffIndex effIndex)
}
if (!add_socket)
{
- TC_LOG_ERROR("spells", "Spell::EffectEnchantItemPrismatic: attempt apply enchant spell %u with SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC (%u) but without ITEM_ENCHANTMENT_TYPE_PRISMATIC_SOCKET (%u), not suppoted yet.",
+ TC_LOG_ERROR("spells", "Spell::EffectEnchantItemPrismatic: attempt to apply the enchant spell %u with SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC (%u), but without ITEM_ENCHANTMENT_TYPE_PRISMATIC_SOCKET (%u), not supported yet.",
m_spellInfo->Id, SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC, ITEM_ENCHANTMENT_TYPE_PRISMATIC_SOCKET);
return;
}
@@ -2823,7 +2823,7 @@ void Spell::EffectEnchantItemTmp(SpellEffIndex effIndex)
case 10: spell_id = 36758; break; // 14%
case 11: spell_id = 36760; break; // 20%
default:
- TC_LOG_ERROR("spells", "Spell::EffectEnchantItemTmp: Damage %u not handled in S'RW", damage);
+ TC_LOG_ERROR("spells", "Spell::EffectEnchantItemTmp: Damage %u not handled in S'RW.", damage);
return;
}
@@ -2857,14 +2857,14 @@ void Spell::EffectEnchantItemTmp(SpellEffIndex effIndex)
if (!enchant_id)
{
- TC_LOG_ERROR("spells", "Spell %u Effect %u (SPELL_EFFECT_ENCHANT_ITEM_TEMPORARY) have 0 as enchanting id", m_spellInfo->Id, effIndex);
+ TC_LOG_ERROR("spells", "Spell %u Effect %u (SPELL_EFFECT_ENCHANT_ITEM_TEMPORARY) has enchanting id 0.", m_spellInfo->Id, effIndex);
return;
}
SpellItemEnchantmentEntry const* pEnchant = sSpellItemEnchantmentStore.LookupEntry(enchant_id);
if (!pEnchant)
{
- TC_LOG_ERROR("spells", "Spell %u Effect %u (SPELL_EFFECT_ENCHANT_ITEM_TEMPORARY) have not existed enchanting id %u ", m_spellInfo->Id, effIndex, enchant_id);
+ TC_LOG_ERROR("spells", "Spell %u Effect %u (SPELL_EFFECT_ENCHANT_ITEM_TEMPORARY) has a non-existing enchanting id %u ", m_spellInfo->Id, effIndex, enchant_id);
return;
}
@@ -3980,7 +3980,7 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex)
case 31893: spell_heal = 48084; break;
case 31883: spell_heal = 48085; break;
default:
- TC_LOG_ERROR("spells", "Unknown Lightwell spell caster %u", m_caster->GetEntry());
+ TC_LOG_ERROR("spells", "Unknown Lightwell spell caster %u.", m_caster->GetEntry());
return;
}
@@ -4219,7 +4219,7 @@ void Spell::EffectStuck(SpellEffIndex /*effIndex*/)
return;
TC_LOG_DEBUG("spells", "Spell Effect: Stuck");
- TC_LOG_DEBUG("spells", "Player %s (guid %u) used auto-unstuck future at map %u (%f, %f, %f)", player->GetName().c_str(), player->GetGUID().GetCounter(), player->GetMapId(), player->GetPositionX(), player->GetPositionY(), player->GetPositionZ());
+ TC_LOG_DEBUG("spells", "Player %s (guid %u) used the auto-unstuck feature at map %u (%f, %f, %f).", player->GetName().c_str(), player->GetGUID().GetCounter(), player->GetMapId(), player->GetPositionX(), player->GetPositionY(), player->GetPositionZ());
if (player->IsInFlight())
return;
@@ -5101,7 +5101,7 @@ void Spell::EffectTransmitted(SpellEffIndex effIndex)
if (!goinfo)
{
- TC_LOG_ERROR("sql.sql", "Gameobject (Entry: %u) not exist and not created at spell (ID: %u) cast", name_id, m_spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "Gameobject (Entry: %u) does not exist and is not created by spell (ID: %u) cast.", name_id, m_spellInfo->Id);
return;
}
@@ -5742,7 +5742,7 @@ void Spell::EffectPlayMusic(SpellEffIndex effIndex)
if (!sSoundEntriesStore.LookupEntry(soundid))
{
- TC_LOG_ERROR("spells", "EffectPlayMusic: Sound (Id: %u) not exist in spell %u.", soundid, m_spellInfo->Id);
+ TC_LOG_ERROR("spells", "EffectPlayMusic: Sound (Id: %u) does not exist in spell %u.", soundid, m_spellInfo->Id);
return;
}
@@ -5799,7 +5799,7 @@ void Spell::EffectPlaySound(SpellEffIndex effIndex)
if (!sSoundEntriesStore.LookupEntry(soundId))
{
- TC_LOG_ERROR("spells", "EffectPlaySound: Sound (Id: %u) not exist in spell %u.", soundId, m_spellInfo->Id);
+ TC_LOG_ERROR("spells", "EffectPlaySound: Sound (Id: %u) does not exist in spell %u.", soundId, m_spellInfo->Id);
return;
}
diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp
index f5bb1c920fe..0f80d83e0ff 100644
--- a/src/server/game/Spells/SpellMgr.cpp
+++ b/src/server/game/Spells/SpellMgr.cpp
@@ -376,29 +376,29 @@ bool SpellMgr::IsSpellValid(SpellInfo const* spellInfo, Player* player, bool msg
{
if (spellInfo->Effects[i].ItemType == 0)
{
- // skip auto-loot crafting spells, its not need explicit item info (but have special fake items sometime)
+ // skip auto-loot crafting spells, it does not need explicit item info (but has special fake items sometimes).
if (!spellInfo->IsLootCrafting())
{
if (msg)
{
if (player)
- ChatHandler(player->GetSession()).PSendSysMessage("Craft spell %u not have create item entry.", spellInfo->Id);
+ ChatHandler(player->GetSession()).PSendSysMessage("The craft spell %u does not have a create item entry.", spellInfo->Id);
else
- TC_LOG_ERROR("sql.sql", "Craft spell %u not have create item entry.", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The craft spell %u does not have a create item entry.", spellInfo->Id);
}
return false;
}
}
- // also possible IsLootCrafting case but fake item must exist anyway
+ // also possible IsLootCrafting case but fake items must exist anyway
else if (!sObjectMgr->GetItemTemplate(spellInfo->Effects[i].ItemType))
{
if (msg)
{
if (player)
- ChatHandler(player->GetSession()).PSendSysMessage("Craft spell %u create not-exist in DB item (Entry: %u) and then...", spellInfo->Id, spellInfo->Effects[i].ItemType);
+ ChatHandler(player->GetSession()).PSendSysMessage("Craft spell %u has created a non-existing item in DB (Entry: %u) and then...", spellInfo->Id, spellInfo->Effects[i].ItemType);
else
- TC_LOG_ERROR("sql.sql", "Craft spell %u create not-exist in DB item (Entry: %u) and then...", spellInfo->Id, spellInfo->Effects[i].ItemType);
+ TC_LOG_ERROR("sql.sql", "Craft spell %u has created a non-existing item in DB (Entry: %u) and then...", spellInfo->Id, spellInfo->Effects[i].ItemType);
}
return false;
}
@@ -434,9 +434,9 @@ bool SpellMgr::IsSpellValid(SpellInfo const* spellInfo, Player* player, bool msg
if (msg)
{
if (player)
- ChatHandler(player->GetSession()).PSendSysMessage("Craft spell %u have not-exist reagent in DB item (Entry: %u) and then...", spellInfo->Id, spellInfo->Reagent[j]);
+ ChatHandler(player->GetSession()).PSendSysMessage("Craft spell %u refers a non-existing reagent in DB item (Entry: %u) and then...", spellInfo->Id, spellInfo->Reagent[j]);
else
- TC_LOG_ERROR("sql.sql", "Craft spell %u have not-exist reagent in DB item (Entry: %u) and then...", spellInfo->Id, spellInfo->Reagent[j]);
+ TC_LOG_ERROR("sql.sql", "Craft spell %u refers to a non-existing reagent in DB, item (Entry: %u) and then...", spellInfo->Id, spellInfo->Reagent[j]);
}
return false;
}
@@ -455,7 +455,7 @@ uint32 SpellMgr::GetSpellDifficultyId(uint32 spellId) const
void SpellMgr::SetSpellDifficultyId(uint32 spellId, uint32 id)
{
if (uint32 i = GetSpellDifficultyId(spellId))
- TC_LOG_ERROR("spells", "SpellMgr::SetSpellDifficultyId: Spell %u has already spellDifficultyId %u. Will override with spellDifficultyId %u.", spellId, i, id);
+ TC_LOG_ERROR("spells", "SpellMgr::SetSpellDifficultyId: The spell %u already has spellDifficultyId %u. Will override with spellDifficultyId %u.", spellId, i, id);
mSpellDifficultySearcherMap[spellId] = id;
}
@@ -470,7 +470,7 @@ uint32 SpellMgr::GetSpellIdForDifficulty(uint32 spellId, Unit const* caster) con
uint32 mode = uint32(caster->GetMap()->GetSpawnMode());
if (mode >= MAX_DIFFICULTY)
{
- TC_LOG_ERROR("spells", "SpellMgr::GetSpellIdForDifficulty: Incorrect Difficulty for spell %u.", spellId);
+ TC_LOG_ERROR("spells", "SpellMgr::GetSpellIdForDifficulty: Incorrect difficulty for spell %u.", spellId);
return spellId; //return source spell
}
@@ -481,7 +481,7 @@ uint32 SpellMgr::GetSpellIdForDifficulty(uint32 spellId, Unit const* caster) con
SpellDifficultyEntry const* difficultyEntry = sSpellDifficultyStore.LookupEntry(difficultyId);
if (!difficultyEntry)
{
- TC_LOG_ERROR("spells", "SpellMgr::GetSpellIdForDifficulty: SpellDifficultyEntry not found for spell %u. This should never happen.", spellId);
+ TC_LOG_ERROR("spells", "SpellMgr::GetSpellIdForDifficulty: SpellDifficultyEntry was not found for spell %u. This should never happen.", spellId);
return spellId; //return source spell
}
@@ -874,7 +874,7 @@ bool SpellMgr::IsSpellProcEventCanTriggeredBy(SpellInfo const* spellProto, Spell
// For melee triggers
if (procSpell == NULL)
{
- // Check (if set) for school (melee attack have Normal school)
+ // Check (if set) for school (melee attack has Normal school)
if (spellProcEvent->schoolMask && (spellProcEvent->schoolMask & SPELL_SCHOOL_MASK_NORMAL) == 0)
return false;
}
@@ -894,7 +894,7 @@ bool SpellMgr::IsSpellProcEventCanTriggeredBy(SpellInfo const* spellProto, Spell
if (!(spellProcEvent->spellFamilyMask & procSpell->SpellFamilyFlags))
return false;
hasFamilyMask = true;
- // Some spells are not considered as active even with have spellfamilyflags
+ // Some spells are not considered as active even with spellfamilyflags set
if (!(procEvent_procEx & PROC_EX_ONLY_ACTIVE_SPELL))
active = true;
}
@@ -1121,27 +1121,27 @@ SpellAreaForAreaMapBounds SpellMgr::GetSpellAreaForAreaMapBounds(uint32 area_id)
bool SpellArea::IsFitToRequirements(Player const* player, uint32 newZone, uint32 newArea) const
{
- if (gender != GENDER_NONE) // not in expected gender
+ if (gender != GENDER_NONE) // is not expected gender
if (!player || gender != player->getGender())
return false;
- if (raceMask) // not in expected race
+ if (raceMask) // is not expected race
if (!player || !(raceMask & player->getRaceMask()))
return false;
- if (areaId) // not in expected zone
+ if (areaId) // is not in expected zone
if (newZone != areaId && newArea != areaId)
return false;
- if (questStart) // not in expected required quest state
+ if (questStart) // is not in expected required quest state
if (!player || (((1 << player->GetQuestStatus(questStart)) & questStartStatus) == 0))
return false;
- if (questEnd) // not in expected forbidden quest state
+ if (questEnd) // is not in expected forbidden quest state
if (!player || (((1 << player->GetQuestStatus(questEnd)) & questEndStatus) == 0))
return false;
- if (auraSpell) // not have expected aura
+ if (auraSpell) // does not have expected aura
if (!player || (auraSpell > 0 && !player->HasAura(auraSpell)) || (auraSpell < 0 && player->HasAura(-auraSpell)))
return false;
@@ -1341,7 +1341,7 @@ void SpellMgr::LoadSpellRanks()
SpellInfo const* first = GetSpellInfo(lastSpell);
if (!first)
{
- TC_LOG_ERROR("sql.sql", "Spell rank identifier(first_spell_id) %u listed in `spell_ranks` does not exist!", lastSpell);
+ TC_LOG_ERROR("sql.sql", "The spell rank identifier(first_spell_id) %u listed in `spell_ranks` does not exist!", lastSpell);
continue;
}
// check if chain is long enough
@@ -1358,14 +1358,14 @@ void SpellMgr::LoadSpellRanks()
SpellInfo const* spell = GetSpellInfo(itr->first);
if (!spell)
{
- TC_LOG_ERROR("sql.sql", "Spell %u (rank %u) listed in `spell_ranks` for chain %u does not exist!", itr->first, itr->second, lastSpell);
+ TC_LOG_ERROR("sql.sql", "The spell %u (rank %u) listed in `spell_ranks` for chain %u does not exist!", itr->first, itr->second, lastSpell);
valid = false;
break;
}
++curRank;
if (itr->second != curRank)
{
- TC_LOG_ERROR("sql.sql", "Spell %u (rank %u) listed in `spell_ranks` for chain %u does not have proper rank value(should be %u)!", itr->first, itr->second, lastSpell, curRank);
+ TC_LOG_ERROR("sql.sql", "The spell %u (rank %u) listed in `spell_ranks` for chain %u does not have a proper rank value (should be %u)!", itr->first, itr->second, lastSpell, curRank);
valid = false;
break;
}
@@ -1381,7 +1381,7 @@ void SpellMgr::LoadSpellRanks()
int32 addedSpell = itr->first;
if (mSpellInfoMap[addedSpell]->ChainEntry)
- TC_LOG_ERROR("sql.sql", "Spell %u (rank: %u, first: %u) listed in `spell_ranks` has already ChainEntry from dbc.", addedSpell, itr->second, lastSpell);
+ TC_LOG_ERROR("sql.sql", "The spell %u (rank: %u, first: %u) listed in `spell_ranks` already has ChainEntry from dbc.", addedSpell, itr->second, lastSpell);
mSpellChains[addedSpell].first = GetSpellInfo(lastSpell);
mSpellChains[addedSpell].last = GetSpellInfo(rankChain.back().first);
@@ -1435,26 +1435,26 @@ void SpellMgr::LoadSpellRequired()
SpellInfo const* spell = GetSpellInfo(spell_id);
if (!spell)
{
- TC_LOG_ERROR("sql.sql", "spell_id %u in `spell_required` table is not found in dbcs, skipped", spell_id);
+ TC_LOG_ERROR("sql.sql", "spell_id %u in `spell_required` table could not be found in dbc, skipped.", spell_id);
continue;
}
SpellInfo const* reqSpell = GetSpellInfo(spell_req);
if (!reqSpell)
{
- TC_LOG_ERROR("sql.sql", "req_spell %u in `spell_required` table is not found in dbcs, skipped", spell_req);
+ TC_LOG_ERROR("sql.sql", "req_spell %u in `spell_required` table could not be found in dbc, skipped.", spell_req);
continue;
}
if (spell->IsRankOf(reqSpell))
{
- TC_LOG_ERROR("sql.sql", "req_spell %u and spell_id %u in `spell_required` table are ranks of the same spell, entry not needed, skipped", spell_req, spell_id);
+ TC_LOG_ERROR("sql.sql", "req_spell %u and spell_id %u in `spell_required` table are ranks of the same spell, entry not needed, skipped.", spell_req, spell_id);
continue;
}
if (IsSpellRequiringSpell(spell_id, spell_req))
{
- TC_LOG_ERROR("sql.sql", "duplicated entry of req_spell %u and spell_id %u in `spell_required`, skipped", spell_req, spell_id);
+ TC_LOG_ERROR("sql.sql", "Duplicate entry of req_spell %u and spell_id %u in `spell_required`, skipped.", spell_req, spell_id);
continue;
}
@@ -1532,19 +1532,19 @@ void SpellMgr::LoadSpellLearnSpells()
if (!GetSpellInfo(spell_id))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_learn_spell` does not exist", spell_id);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_learn_spell` does not exist.", spell_id);
continue;
}
if (!GetSpellInfo(node.spell))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_learn_spell` learning not existed spell %u", spell_id, node.spell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_learn_spell` learning non-existing spell %u.", spell_id, node.spell);
continue;
}
if (GetTalentSpellCost(node.spell))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_learn_spell` attempt learning talent spell %u, skipped", spell_id, node.spell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_learn_spell` attempts learning talent spell %u, skipped.", spell_id, node.spell);
continue;
}
@@ -1586,7 +1586,7 @@ void SpellMgr::LoadSpellLearnSpells()
{
if (itr->second.spell == dbc_node.spell)
{
- TC_LOG_ERROR("sql.sql", "Spell %u auto-learn spell %u in spell.dbc then the record in `spell_learn_spell` is redundant, please fix DB.",
+ TC_LOG_ERROR("sql.sql", "The spell %u is an auto-learn spell %u in spell.dbc and the record in `spell_learn_spell` is redundant. Please update your DB.",
spell, dbc_node.spell);
found = true;
break;
@@ -1663,7 +1663,7 @@ void SpellMgr::LoadSpellTargetPositions()
}
else
{
- TC_LOG_ERROR("sql.sql", "Spell (Id: %u, effIndex: %u) listed in `spell_target_position` does not have target TARGET_DEST_DB (17).", Spell_ID, effIndex);
+ TC_LOG_ERROR("sql.sql", "Spell (Id: %u, effIndex: %u) listed in `spell_target_position` does not have a target TARGET_DEST_DB (17).", Spell_ID, effIndex);
continue;
}
@@ -1700,7 +1700,7 @@ void SpellMgr::LoadSpellTargetPositions()
if (found)
{
if (!sSpellMgr->GetSpellTargetPosition(i))
- TC_LOG_DEBUG("spells", "Spell (ID: %u) does not have record in `spell_target_position`", i);
+ TC_LOG_DEBUG("spells", "Spell (ID: %u) does not have a record in `spell_target_position`.", i);
}
}*/
@@ -1759,12 +1759,12 @@ void SpellMgr::LoadSpellGroups()
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_group` does not exist", itr->second);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_group` does not exist", itr->second);
mSpellGroupSpell.erase(itr++);
}
else if (spellInfo->GetRank() > 1)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_group` is not first rank of spell", itr->second);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_group` is not the first rank of the spell.", itr->second);
mSpellGroupSpell.erase(itr++);
}
else
@@ -1810,7 +1810,7 @@ void SpellMgr::LoadSpellGroupStackRules()
uint8 stack_rule = fields[1].GetInt8();
if (stack_rule >= SPELL_GROUP_STACK_RULE_MAX)
{
- TC_LOG_ERROR("sql.sql", "SpellGroupStackRule %u listed in `spell_group_stack_rules` does not exist", stack_rule);
+ TC_LOG_ERROR("sql.sql", "SpellGroupStackRule %u listed in `spell_group_stack_rules` does not exist.", stack_rule);
continue;
}
@@ -1818,7 +1818,7 @@ void SpellMgr::LoadSpellGroupStackRules()
if (spellGroup.first == spellGroup.second)
{
- TC_LOG_ERROR("sql.sql", "SpellGroup id %u listed in `spell_group_stack_rules` does not exist", group_id);
+ TC_LOG_ERROR("sql.sql", "SpellGroup id %u listed in `spell_group_stack_rules` does not exist.", group_id);
continue;
}
@@ -1862,18 +1862,18 @@ void SpellMgr::LoadSpellProcEvents()
SpellInfo const* spellInfo = GetSpellInfo(spellId);
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc_event` does not exist", spellId);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc_event` does not exist.", spellId);
continue;
}
if (allRanks)
{
if (!spellInfo->IsRanked())
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc_event` with all ranks, but spell has no ranks.", spellId);
+ TC_LOG_ERROR("sql.sql", "The spell %u is listed in `spell_proc_event` with all ranks, but spell has no ranks.", spellId);
if (spellInfo->GetFirstRankSpell()->Id != uint32(spellId))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc_event` is not first rank of spell.", spellId);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc_event` is not first rank of spell.", spellId);
continue;
}
}
@@ -1895,12 +1895,12 @@ void SpellMgr::LoadSpellProcEvents()
{
if (mSpellProcEventMap.find(spellInfo->Id) != mSpellProcEventMap.end())
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc_event` already has its first rank in table.", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc_event` already has its first rank in table.", spellInfo->Id);
break;
}
if (!spellInfo->ProcFlags && !spellProcEvent.procFlags)
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc_event` probably not triggered spell", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc_event` is probably not a triggered spell.", spellInfo->Id);
mSpellProcEventMap[spellInfo->Id] = spellProcEvent;
@@ -1948,18 +1948,18 @@ void SpellMgr::LoadSpellProcs()
SpellInfo const* spellInfo = GetSpellInfo(spellId);
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc` does not exist", spellId);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc` does not exist", spellId);
continue;
}
if (allRanks)
{
if (!spellInfo->IsRanked())
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc` with all ranks, but spell has no ranks.", spellId);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc` with all ranks, but spell has no ranks.", spellId);
if (spellInfo->GetFirstRankSpell()->Id != uint32(spellId))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc` is not first rank of spell.", spellId);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc` is not the first rank of the spell.", spellId);
continue;
}
}
@@ -1986,7 +1986,7 @@ void SpellMgr::LoadSpellProcs()
{
if (mSpellProcMap.find(spellInfo->Id) != mSpellProcMap.end())
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_proc` already has its first rank in table.", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_proc` already has its first rank in the table.", spellInfo->Id);
break;
}
@@ -2007,42 +2007,42 @@ void SpellMgr::LoadSpellProcs()
TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has wrong `spellFamilyName` set: %u", spellInfo->Id, procEntry.spellFamilyName);
if (procEntry.chance < 0)
{
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has negative value in `chance` field", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has negative value in the `chance` field", spellInfo->Id);
procEntry.chance = 0;
}
if (procEntry.ratePerMinute < 0)
{
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has negative value in `ratePerMinute` field", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has negative value in the `ratePerMinute` field", spellInfo->Id);
procEntry.ratePerMinute = 0;
}
if (cooldown < 0)
{
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has negative value in `cooldown` field", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has negative value in the `cooldown` field", spellInfo->Id);
procEntry.cooldown = 0;
}
if (procEntry.chance == 0 && procEntry.ratePerMinute == 0)
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u doesn't have `chance` and `ratePerMinute` values defined, proc will not be triggered", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u doesn't have any `chance` and `ratePerMinute` values defined, proc will not be triggered", spellInfo->Id);
if (procEntry.charges > 99)
{
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has too big value in `charges` field", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u has a too big `charges` field value.", spellInfo->Id);
procEntry.charges = 99;
}
if (!procEntry.typeMask)
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u doesn't have `typeMask` value defined, proc will not be triggered", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u doesn't have any `typeMask` value defined, proc will not be triggered.", spellInfo->Id);
if (procEntry.spellTypeMask & ~PROC_SPELL_TYPE_MASK_ALL)
TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has wrong `spellTypeMask` set: %u", spellInfo->Id, procEntry.spellTypeMask);
if (procEntry.spellTypeMask && !(procEntry.typeMask & (SPELL_PROC_FLAG_MASK | PERIODIC_PROC_FLAG_MASK)))
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has `spellTypeMask` value defined, but it won't be used for defined `typeMask` value", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u has `spellTypeMask` value defined, but it will not be used for the defined `typeMask` value.", spellInfo->Id);
if (!procEntry.spellPhaseMask && procEntry.typeMask & REQ_SPELL_PHASE_PROC_FLAG_MASK)
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u doesn't have `spellPhaseMask` value defined, but it's required for defined `typeMask` value, proc will not be triggered", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u doesn't have any `spellPhaseMask` value defined, but it is required for the defined `typeMask` value. Proc will not be triggered.", spellInfo->Id);
if (procEntry.spellPhaseMask & ~PROC_SPELL_PHASE_MASK_ALL)
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has wrong `spellPhaseMask` set: %u", spellInfo->Id, procEntry.spellPhaseMask);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u has wrong `spellPhaseMask` set: %u", spellInfo->Id, procEntry.spellPhaseMask);
if (procEntry.spellPhaseMask && !(procEntry.typeMask & REQ_SPELL_PHASE_PROC_FLAG_MASK))
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has `spellPhaseMask` value defined, but it won't be used for defined `typeMask` value", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u has a `spellPhaseMask` value defined, but it will not be used for the defined `typeMask` value.", spellInfo->Id);
if (procEntry.hitMask & ~PROC_HIT_MASK_ALL)
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has wrong `hitMask` set: %u", spellInfo->Id, procEntry.hitMask);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u has wrong `hitMask` set: %u", spellInfo->Id, procEntry.hitMask);
if (procEntry.hitMask && !(procEntry.typeMask & TAKEN_HIT_PROC_FLAG_MASK || (procEntry.typeMask & DONE_HIT_PROC_FLAG_MASK && (!procEntry.spellPhaseMask || procEntry.spellPhaseMask & (PROC_SPELL_PHASE_HIT | PROC_SPELL_PHASE_FINISH)))))
- TC_LOG_ERROR("sql.sql", "`spell_proc` table entry for spellId %u has `hitMask` value defined, but it won't be used for defined `typeMask` and `spellPhaseMask` values", spellInfo->Id);
+ TC_LOG_ERROR("sql.sql", "The `spell_proc` table entry for spellId %u has `hitMask` value defined, but it will not be used for defined `typeMask` and `spellPhaseMask` values.", spellInfo->Id);
mSpellProcMap[spellInfo->Id] = procEntry;
@@ -2081,7 +2081,7 @@ void SpellMgr::LoadSpellBonusess()
SpellInfo const* spell = GetSpellInfo(entry);
if (!spell)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_bonus_data` does not exist", entry);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_bonus_data` does not exist.", entry);
continue;
}
@@ -2120,7 +2120,7 @@ void SpellMgr::LoadSpellThreats()
if (!GetSpellInfo(entry))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_threat` does not exist", entry);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_threat` does not exist.", entry);
continue;
}
@@ -2189,21 +2189,21 @@ void SpellMgr::LoadSpellPetAuras()
SpellInfo const* spellInfo = GetSpellInfo(spell);
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_pet_auras` does not exist", spell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_pet_auras` does not exist.", spell);
continue;
}
if (spellInfo->Effects[eff].Effect != SPELL_EFFECT_DUMMY &&
(spellInfo->Effects[eff].Effect != SPELL_EFFECT_APPLY_AURA ||
spellInfo->Effects[eff].ApplyAuraName != SPELL_AURA_DUMMY))
{
- TC_LOG_ERROR("spells", "Spell %u listed in `spell_pet_auras` does not have dummy aura or dummy effect", spell);
+ TC_LOG_ERROR("spells", "The spell %u listed in `spell_pet_auras` does not have any dummy aura or dummy effect.", spell);
continue;
}
SpellInfo const* spellInfo2 = GetSpellInfo(aura);
if (!spellInfo2)
{
- TC_LOG_ERROR("sql.sql", "Aura %u listed in `spell_pet_auras` does not exist", aura);
+ TC_LOG_ERROR("sql.sql", "The aura %u listed in `spell_pet_auras` does not exist.", aura);
continue;
}
@@ -2281,7 +2281,7 @@ void SpellMgr::LoadSpellEnchantProcData()
SpellItemEnchantmentEntry const* ench = sSpellItemEnchantmentStore.LookupEntry(enchantId);
if (!ench)
{
- TC_LOG_ERROR("sql.sql", "Enchancment %u listed in `spell_enchant_proc_data` does not exist", enchantId);
+ TC_LOG_ERROR("sql.sql", "The enchancment %u listed in `spell_enchant_proc_data` does not exist.", enchantId);
continue;
}
@@ -2325,7 +2325,7 @@ void SpellMgr::LoadSpellLinked()
SpellInfo const* spellInfo = GetSpellInfo(abs(trigger));
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_linked_spell` does not exist", abs(trigger));
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_linked_spell` does not exist.", abs(trigger));
continue;
}
@@ -2333,13 +2333,13 @@ void SpellMgr::LoadSpellLinked()
for (uint8 j = 0; j < MAX_SPELL_EFFECTS; ++j)
{
if (spellInfo->Effects[j].CalcValue() == abs(effect))
- TC_LOG_ERROR("sql.sql", "Spell %u Effect: %u listed in `spell_linked_spell` has same bp%u like effect (possible hack)", abs(trigger), abs(effect), j);
+ TC_LOG_ERROR("sql.sql", "The spell %u Effect: %u listed in `spell_linked_spell` has same bp%u like effect (possible hack).", abs(trigger), abs(effect), j);
}
spellInfo = GetSpellInfo(abs(effect));
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_linked_spell` does not exist", abs(effect));
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_linked_spell` does not exist.", abs(effect));
continue;
}
@@ -2584,7 +2584,7 @@ void SpellMgr::LoadSpellAreas()
}
else
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` does not exist", spell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` does not exist", spell);
continue;
}
@@ -2613,20 +2613,20 @@ void SpellMgr::LoadSpellAreas()
if (!ok)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` already listed with similar requirements.", spell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` is already listed with similar requirements.", spell);
continue;
}
}
if (spellArea.areaId && !sAreaTableStore.LookupEntry(spellArea.areaId))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong area (%u) requirement", spell, spellArea.areaId);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has a wrong area (%u) requirement.", spell, spellArea.areaId);
continue;
}
if (spellArea.questStart && !sObjectMgr->GetQuestTemplate(spellArea.questStart))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong start quest (%u) requirement", spell, spellArea.questStart);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has a wrong start quest (%u) requirement.", spell, spellArea.questStart);
continue;
}
@@ -2634,7 +2634,7 @@ void SpellMgr::LoadSpellAreas()
{
if (!sObjectMgr->GetQuestTemplate(spellArea.questEnd))
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong end quest (%u) requirement", spell, spellArea.questEnd);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has a wrong ending quest (%u) requirement.", spell, spellArea.questEnd);
continue;
}
}
@@ -2644,13 +2644,13 @@ void SpellMgr::LoadSpellAreas()
SpellInfo const* spellInfo = GetSpellInfo(abs(spellArea.auraSpell));
if (!spellInfo)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong aura spell (%u) requirement", spell, abs(spellArea.auraSpell));
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has wrong aura spell (%u) requirement", spell, abs(spellArea.auraSpell));
continue;
}
if (uint32(abs(spellArea.auraSpell)) == spellArea.spellId)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have aura spell (%u) requirement for itself", spell, abs(spellArea.auraSpell));
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has aura spell (%u) requirement for itself", spell, abs(spellArea.auraSpell));
continue;
}
@@ -2670,7 +2670,7 @@ void SpellMgr::LoadSpellAreas()
if (chain)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have aura spell (%u) requirement that itself autocast from aura", spell, spellArea.auraSpell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has the aura spell (%u) requirement that it autocasts itself from the aura.", spell, spellArea.auraSpell);
continue;
}
@@ -2686,7 +2686,7 @@ void SpellMgr::LoadSpellAreas()
if (chain)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have aura spell (%u) requirement that itself autocast from aura", spell, spellArea.auraSpell);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has the aura spell (%u) requirement that the spell itself autocasts from the aura.", spell, spellArea.auraSpell);
continue;
}
}
@@ -2694,13 +2694,13 @@ void SpellMgr::LoadSpellAreas()
if (spellArea.raceMask && (spellArea.raceMask & RACEMASK_ALL_PLAYABLE) == 0)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong race mask (%u) requirement", spell, spellArea.raceMask);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has wrong race mask (%u) requirement.", spell, spellArea.raceMask);
continue;
}
if (spellArea.gender != GENDER_NONE && spellArea.gender != GENDER_FEMALE && spellArea.gender != GENDER_MALE)
{
- TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong gender (%u) requirement", spell, spellArea.gender);
+ TC_LOG_ERROR("sql.sql", "The spell %u listed in `spell_area` has wrong gender (%u) requirement.", spell, spellArea.gender);
continue;
}
diff --git a/src/server/game/Weather/Weather.cpp b/src/server/game/Weather/Weather.cpp
index f774916f4a5..7ef16e32031 100644
--- a/src/server/game/Weather/Weather.cpp
+++ b/src/server/game/Weather/Weather.cpp
@@ -152,7 +152,7 @@ bool Weather::ReGenerate()
uint32 chance2 = chance1+ m_weatherChances->data[season].snowChance;
uint32 chance3 = chance2+ m_weatherChances->data[season].stormChance;
- uint32 rnd = urand(0, 99);
+ uint32 rnd = urand(1, 100);
if (rnd <= chance1)
m_type = WEATHER_TYPE_RAIN;
else if (rnd <= chance2)
diff --git a/src/server/scripts/CMakeLists.txt b/src/server/scripts/CMakeLists.txt
index a0bbe988787..545902dca66 100644
--- a/src/server/scripts/CMakeLists.txt
+++ b/src/server/scripts/CMakeLists.txt
@@ -16,9 +16,15 @@ if (USE_SCRIPTPCH)
endif ()
message(STATUS "SCRIPT PREPARATIONS")
-include(Spells/CMakeLists.txt)
-include(Commands/CMakeLists.txt)
+macro(PrepareScripts name out)
+ file(GLOB_RECURSE found
+ ${name}/*.h
+ ${name}/*.cpp
+ )
+ list(APPEND ${out} ${found})
+ message(STATUS " -> Prepared: ${name}")
+endmacro(PrepareScripts)
set(scripts_STAT_SRCS
${scripts_STAT_SRCS}
@@ -28,16 +34,20 @@ set(scripts_STAT_SRCS
../game/Maps/AreaBoundary.cpp
)
+PrepareScripts(Spells scripts_STAT_SRCS)
+PrepareScripts(Commands scripts_STAT_SRCS)
+
if(SCRIPTS)
- include(Custom/CMakeLists.txt)
- include(World/CMakeLists.txt)
- include(OutdoorPvP/CMakeLists.txt)
- include(EasternKingdoms/CMakeLists.txt)
- include(Kalimdor/CMakeLists.txt)
- include(Outland/CMakeLists.txt)
- include(Northrend/CMakeLists.txt)
- include(Events/CMakeLists.txt)
- include(Pet/CMakeLists.txt)
+ PrepareScripts(Commands scripts_STAT_SRCS)
+ PrepareScripts(Custom scripts_STAT_SRCS)
+ PrepareScripts(World scripts_STAT_SRCS)
+ PrepareScripts(OutdoorPvP scripts_STAT_SRCS)
+ PrepareScripts(EasternKingdoms scripts_STAT_SRCS)
+ PrepareScripts(Kalimdor scripts_STAT_SRCS)
+ PrepareScripts(Outland scripts_STAT_SRCS)
+ PrepareScripts(Northrend scripts_STAT_SRCS)
+ PrepareScripts(Events scripts_STAT_SRCS)
+ PrepareScripts(Pet scripts_STAT_SRCS)
endif()
message(STATUS "SCRIPT PREPARATION COMPLETE")
diff --git a/src/server/scripts/Commands/CMakeLists.txt b/src/server/scripts/Commands/CMakeLists.txt
deleted file mode 100644
index d4d75cd175f..00000000000
--- a/src/server/scripts/Commands/CMakeLists.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-file(GLOB_RECURSE sources_Commands Commands/*.cpp Commands/*.h)
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- ${sources_Commands}
-)
-
-message(" -> Prepared: Commands")
diff --git a/src/server/scripts/Commands/cs_character.cpp b/src/server/scripts/Commands/cs_character.cpp
index e048aabd4d7..eb1aa98f4ff 100644
--- a/src/server/scripts/Commands/cs_character.cpp
+++ b/src/server/scripts/Commands/cs_character.cpp
@@ -133,7 +133,7 @@ public:
info.name = fields[1].GetString();
info.accountId = fields[2].GetUInt32();
- // account name will be empty for not existed account
+ // account name will be empty for nonexisting account
AccountMgr::GetName(info.accountId, info.accountName);
info.deleteDate = time_t(fields[3].GetUInt32());
foundList.push_back(info);
@@ -169,11 +169,11 @@ public:
if (!handler->GetSession())
handler->PSendSysMessage(LANG_CHARACTER_DELETED_LIST_LINE_CONSOLE,
- itr->guid.GetCounter(), itr->name.c_str(), itr->accountName.empty() ? "<Not existed>" : itr->accountName.c_str(),
+ itr->guid.GetCounter(), itr->name.c_str(), itr->accountName.empty() ? "<Not existing>" : itr->accountName.c_str(),
itr->accountId, dateStr.c_str());
else
handler->PSendSysMessage(LANG_CHARACTER_DELETED_LIST_LINE_CHAT,
- itr->guid.GetCounter(), itr->name.c_str(), itr->accountName.empty() ? "<Not existed>" : itr->accountName.c_str(),
+ itr->guid.GetCounter(), itr->name.c_str(), itr->accountName.empty() ? "<Not existing>" : itr->accountName.c_str(),
itr->accountId, dateStr.c_str());
}
@@ -193,7 +193,7 @@ public:
*/
static void HandleCharacterDeletedRestoreHelper(DeletedInfo const& delInfo, ChatHandler* handler)
{
- if (delInfo.accountName.empty()) // account not exist
+ if (delInfo.accountName.empty()) // account does not exist
{
handler->PSendSysMessage(LANG_CHARACTER_DELETED_SKIP_ACCOUNT, delInfo.name.c_str(), delInfo.guid.GetCounter(), delInfo.accountId);
return;
@@ -660,7 +660,7 @@ public:
if (newCharName.empty())
{
- // Drop not existed account cases
+ // Drop nonexisting account cases
for (DeletedInfoList::iterator itr = foundList.begin(); itr != foundList.end(); ++itr)
HandleCharacterDeletedRestoreHelper(*itr, handler);
}
@@ -810,7 +810,7 @@ public:
if (levelStr && isalpha(levelStr[0]))
{
nameStr = levelStr;
- levelStr = NULL; // current level will used
+ levelStr = NULL; // current level will be used
}
Player* target;
diff --git a/src/server/scripts/Commands/cs_script_loader.cpp b/src/server/scripts/Commands/cs_script_loader.cpp
new file mode 100644
index 00000000000..449e7053942
--- /dev/null
+++ b/src/server/scripts/Commands/cs_script_loader.cpp
@@ -0,0 +1,104 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_account_commandscript();
+void AddSC_achievement_commandscript();
+void AddSC_ahbot_commandscript();
+void AddSC_arena_commandscript();
+void AddSC_ban_commandscript();
+void AddSC_bf_commandscript();
+void AddSC_cast_commandscript();
+void AddSC_character_commandscript();
+void AddSC_cheat_commandscript();
+void AddSC_debug_commandscript();
+void AddSC_deserter_commandscript();
+void AddSC_disable_commandscript();
+void AddSC_event_commandscript();
+void AddSC_gm_commandscript();
+void AddSC_go_commandscript();
+void AddSC_gobject_commandscript();
+void AddSC_group_commandscript();
+void AddSC_guild_commandscript();
+void AddSC_honor_commandscript();
+void AddSC_instance_commandscript();
+void AddSC_learn_commandscript();
+void AddSC_lfg_commandscript();
+void AddSC_list_commandscript();
+void AddSC_lookup_commandscript();
+void AddSC_message_commandscript();
+void AddSC_misc_commandscript();
+void AddSC_mmaps_commandscript();
+void AddSC_modify_commandscript();
+void AddSC_npc_commandscript();
+void AddSC_pet_commandscript();
+void AddSC_quest_commandscript();
+void AddSC_rbac_commandscript();
+void AddSC_reload_commandscript();
+void AddSC_reset_commandscript();
+void AddSC_send_commandscript();
+void AddSC_server_commandscript();
+void AddSC_tele_commandscript();
+void AddSC_ticket_commandscript();
+void AddSC_titles_commandscript();
+void AddSC_wp_commandscript();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddCommandsScripts()
+{
+ AddSC_account_commandscript();
+ AddSC_achievement_commandscript();
+ AddSC_ahbot_commandscript();
+ AddSC_arena_commandscript();
+ AddSC_ban_commandscript();
+ AddSC_bf_commandscript();
+ AddSC_cast_commandscript();
+ AddSC_character_commandscript();
+ AddSC_cheat_commandscript();
+ AddSC_debug_commandscript();
+ AddSC_deserter_commandscript();
+ AddSC_disable_commandscript();
+ AddSC_event_commandscript();
+ AddSC_gm_commandscript();
+ AddSC_go_commandscript();
+ AddSC_gobject_commandscript();
+ AddSC_group_commandscript();
+ AddSC_guild_commandscript();
+ AddSC_honor_commandscript();
+ AddSC_instance_commandscript();
+ AddSC_learn_commandscript();
+ AddSC_lookup_commandscript();
+ AddSC_lfg_commandscript();
+ AddSC_list_commandscript();
+ AddSC_message_commandscript();
+ AddSC_misc_commandscript();
+ AddSC_mmaps_commandscript();
+ AddSC_modify_commandscript();
+ AddSC_npc_commandscript();
+ AddSC_quest_commandscript();
+ AddSC_pet_commandscript();
+ AddSC_rbac_commandscript();
+ AddSC_reload_commandscript();
+ AddSC_reset_commandscript();
+ AddSC_send_commandscript();
+ AddSC_server_commandscript();
+ AddSC_tele_commandscript();
+ AddSC_ticket_commandscript();
+ AddSC_titles_commandscript();
+ AddSC_wp_commandscript();
+}
diff --git a/src/server/scripts/Commands/cs_send.cpp b/src/server/scripts/Commands/cs_send.cpp
index 672db3a3ab0..31544543426 100644
--- a/src/server/scripts/Commands/cs_send.cpp
+++ b/src/server/scripts/Commands/cs_send.cpp
@@ -74,7 +74,7 @@ public:
std::string subject = msgSubject;
std::string text = msgText;
- // from console show not existed sender
+ // from console, use non-existing sender
MailSender sender(MAIL_NORMAL, handler->GetSession() ? handler->GetSession()->GetPlayer()->GetGUID().GetCounter() : 0, MAIL_STATIONERY_GM);
/// @todo Fix poor design
@@ -173,7 +173,7 @@ public:
}
}
- // from console show not existed sender
+ // from console show nonexisting sender
MailSender sender(MAIL_NORMAL, handler->GetSession() ? handler->GetSession()->GetPlayer()->GetGUID().GetCounter() : 0, MAIL_STATIONERY_GM);
// fill mail
@@ -185,7 +185,7 @@ public:
{
if (Item* item = Item::CreateItem(itr->first, itr->second, handler->GetSession() ? handler->GetSession()->GetPlayer() : 0))
{
- item->SaveToDB(trans); // save for prevent lost at next mail load, if send fail then item will deleted
+ item->SaveToDB(trans); // Save to prevent being lost at next mail load. If send fails, the item will be deleted.
draft.AddItem(item);
}
}
@@ -233,7 +233,7 @@ public:
std::string subject = msgSubject;
std::string text = msgText;
- // from console show not existed sender
+ // from console show nonexisting sender
MailSender sender(MAIL_NORMAL, handler->GetSession() ? handler->GetSession()->GetPlayer()->GetGUID().GetCounter() : 0, MAIL_STATIONERY_GM);
SQLTransaction trans = CharacterDatabase.BeginTransaction();
@@ -260,7 +260,7 @@ public:
if (!msgStr)
return false;
- ///- Check that he is not logging out.
+ /// - Check if player is logging out.
if (player->GetSession()->isLogingOut())
{
handler->SendSysMessage(LANG_PLAYER_NOT_FOUND);
diff --git a/src/server/scripts/Commands/cs_titles.cpp b/src/server/scripts/Commands/cs_titles.cpp
index 2f5d7b8364c..6309e7279c9 100644
--- a/src/server/scripts/Commands/cs_titles.cpp
+++ b/src/server/scripts/Commands/cs_titles.cpp
@@ -225,7 +225,7 @@ public:
if (CharTitlesEntry const* tEntry = sCharTitlesStore.LookupEntry(i))
titles2 &= ~(uint64(1) << tEntry->bit_index);
- titles &= ~titles2; // remove not existed titles
+ titles &= ~titles2; // remove non-existing titles
target->SetUInt64Value(PLAYER__FIELD_KNOWN_TITLES, titles);
handler->SendSysMessage(LANG_DONE);
diff --git a/src/server/scripts/Custom/CMakeLists.txt b/src/server/scripts/Custom/CMakeLists.txt
deleted file mode 100644
index 595ff801813..00000000000
--- a/src/server/scripts/Custom/CMakeLists.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-# file(GLOB_RECURSE sources_Custom Custom/*.cpp Custom/*.h)
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
-# ${sources_Custom}
-)
-
-message(" -> Prepared: Custom")
diff --git a/src/server/scripts/Custom/custom_script_loader.cpp b/src/server/scripts/Custom/custom_script_loader.cpp
new file mode 100644
index 00000000000..dd4b5e99d77
--- /dev/null
+++ b/src/server/scripts/Custom/custom_script_loader.cpp
@@ -0,0 +1,25 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddCustomScripts()
+{
+}
diff --git a/src/server/scripts/EasternKingdoms/CMakeLists.txt b/src/server/scripts/EasternKingdoms/CMakeLists.txt
deleted file mode 100644
index 8e6616347f9..00000000000
--- a/src/server/scripts/EasternKingdoms/CMakeLists.txt
+++ /dev/null
@@ -1,204 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- EasternKingdoms/zone_ghostlands.cpp
- EasternKingdoms/AlteracValley/boss_galvangar.cpp
- EasternKingdoms/AlteracValley/boss_balinda.cpp
- EasternKingdoms/AlteracValley/boss_drekthar.cpp
- EasternKingdoms/AlteracValley/boss_vanndar.cpp
- EasternKingdoms/AlteracValley/alterac_valley.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_high_interrogator_gerstahn.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_tomb_of_seven.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_general_angerforge.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_ambassador_flamelash.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_moira_bronzebeard.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp
- EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_magmus.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_chromaggus.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_razorgore.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_firemaw.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_broodlord_lashlayer.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_ebonroc.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_vaelastrasz.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_nefarian.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/boss_flamegor.cpp
- EasternKingdoms/BlackrockMountain/BlackwingLair/blackwing_lair.h
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_pyroguard_emberseer.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_drakkisath.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_warmaster_voone.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_mother_smolderweb.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_quartermaster_zigris.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_halycon.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_overlord_wyrmthalak.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_shadow_hunter_voshgajin.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_highlord_omokk.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_the_beast.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gizrul_the_slavener.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_urok_doomhowl.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_lord_valthalak.cpp
- EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h
- EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_gehennas.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_lucifron.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_golemagg.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_majordomo_executus.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_baron_geddon.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_garr.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h
- EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_sulfuron_harbinger.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_magmadar.cpp
- EasternKingdoms/BlackrockMountain/MoltenCore/boss_shazzrah.cpp
- EasternKingdoms/Scholomance/boss_the_ravenian.cpp
- EasternKingdoms/Scholomance/boss_instructor_malicia.cpp
- EasternKingdoms/Scholomance/boss_death_knight_darkreaver.cpp
- EasternKingdoms/Scholomance/boss_illucia_barov.cpp
- EasternKingdoms/Scholomance/scholomance.h
- EasternKingdoms/Scholomance/boss_vectus.cpp
- EasternKingdoms/Scholomance/boss_jandice_barov.cpp
- EasternKingdoms/Scholomance/boss_kormok.cpp
- EasternKingdoms/Scholomance/boss_lord_alexei_barov.cpp
- EasternKingdoms/Scholomance/boss_doctor_theolen_krastinov.cpp
- EasternKingdoms/Scholomance/boss_darkmaster_gandling.cpp
- EasternKingdoms/Scholomance/instance_scholomance.cpp
- EasternKingdoms/Scholomance/boss_lorekeeper_polkelt.cpp
- EasternKingdoms/Scholomance/boss_ras_frostwhisper.cpp
- EasternKingdoms/Scholomance/boss_kirtonos_the_herald.cpp
- EasternKingdoms/zone_isle_of_queldanas.cpp
- EasternKingdoms/ZulGurub/boss_hakkar.cpp
- EasternKingdoms/ZulGurub/boss_mandokir.cpp
- EasternKingdoms/ZulGurub/boss_marli.cpp
- EasternKingdoms/ZulGurub/boss_hazzarah.cpp
- EasternKingdoms/ZulGurub/boss_jeklik.cpp
- EasternKingdoms/ZulGurub/boss_grilek.cpp
- EasternKingdoms/ZulGurub/zulgurub.h
- EasternKingdoms/ZulGurub/boss_renataki.cpp
- EasternKingdoms/ZulGurub/boss_arlokk.cpp
- EasternKingdoms/ZulGurub/boss_gahzranka.cpp
- EasternKingdoms/ZulGurub/boss_venoxis.cpp
- EasternKingdoms/ZulGurub/instance_zulgurub.cpp
- EasternKingdoms/ZulGurub/boss_jindo.cpp
- EasternKingdoms/ZulGurub/boss_wushoolay.cpp
- EasternKingdoms/ZulGurub/boss_thekal.cpp
- EasternKingdoms/zone_wetlands.cpp
- EasternKingdoms/zone_arathi_highlands.cpp
- EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp
- EasternKingdoms/Gnomeregan/gnomeregan.cpp
- EasternKingdoms/Gnomeregan/gnomeregan.h
- EasternKingdoms/zone_redridge_mountains.cpp
- EasternKingdoms/ScarletEnclave/chapter2.cpp
- EasternKingdoms/ScarletEnclave/chapter5.cpp
- EasternKingdoms/ScarletEnclave/chapter1.cpp
- EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp
- EasternKingdoms/zone_eastern_plaguelands.cpp
- EasternKingdoms/Stratholme/boss_baroness_anastari.cpp
- EasternKingdoms/Stratholme/boss_nerubenkan.cpp
- EasternKingdoms/Stratholme/instance_stratholme.cpp
- EasternKingdoms/Stratholme/boss_dathrohan_balnazzar.cpp
- EasternKingdoms/Stratholme/boss_timmy_the_cruel.cpp
- EasternKingdoms/Stratholme/boss_baron_rivendare.cpp
- EasternKingdoms/Stratholme/boss_magistrate_barthilas.cpp
- EasternKingdoms/Stratholme/boss_order_of_silver_hand.cpp
- EasternKingdoms/Stratholme/boss_ramstein_the_gorger.cpp
- EasternKingdoms/Stratholme/boss_cannon_master_willey.cpp
- EasternKingdoms/Stratholme/boss_maleki_the_pallid.cpp
- EasternKingdoms/Stratholme/boss_postmaster_malown.cpp
- EasternKingdoms/Stratholme/stratholme.h
- EasternKingdoms/Stratholme/stratholme.cpp
- EasternKingdoms/zone_tirisfal_glades.cpp
- EasternKingdoms/SunkenTemple/sunken_temple.cpp
- EasternKingdoms/SunkenTemple/sunken_temple.h
- EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp
- EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp
- EasternKingdoms/MagistersTerrace/magisters_terrace.h
- EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp
- EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp
- EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp
- EasternKingdoms/MagistersTerrace/boss_vexallus.cpp
- EasternKingdoms/MagistersTerrace/magisters_terrace.cpp
- EasternKingdoms/Uldaman/uldaman.cpp
- EasternKingdoms/Uldaman/boss_ironaya.cpp
- EasternKingdoms/Uldaman/uldaman.h
- EasternKingdoms/Uldaman/instance_uldaman.cpp
- EasternKingdoms/Uldaman/boss_archaedas.cpp
- EasternKingdoms/zone_swamp_of_sorrows.cpp
- EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp
- EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp
- EasternKingdoms/SunwellPlateau/sunwell_plateau.h
- EasternKingdoms/SunwellPlateau/boss_muru.cpp
- EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp
- EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp
- EasternKingdoms/SunwellPlateau/boss_brutallus.cpp
- EasternKingdoms/SunwellPlateau/sunwell_plateau.cpp
- EasternKingdoms/SunwellPlateau/boss_felmyst.cpp
- EasternKingdoms/zone_stranglethorn_vale.cpp
- EasternKingdoms/Deadmines/deadmines.h
- EasternKingdoms/Deadmines/deadmines.cpp
- EasternKingdoms/Deadmines/boss_mr_smite.cpp
- EasternKingdoms/Deadmines/instance_deadmines.cpp
- EasternKingdoms/zone_duskwood.cpp
- EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp
- EasternKingdoms/ScarletMonastery/boss_mograine_and_whitemane.cpp
- EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp
- EasternKingdoms/ScarletMonastery/boss_interrogator_vishas.cpp
- EasternKingdoms/ScarletMonastery/boss_headless_horseman.cpp
- EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp
- EasternKingdoms/ScarletMonastery/boss_houndmaster_loksey.cpp
- EasternKingdoms/ScarletMonastery/scarlet_monastery.h
- EasternKingdoms/ScarletMonastery/boss_high_inquisitor_fairbanks.cpp
- EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp
- EasternKingdoms/ScarletMonastery/boss_herod.cpp
- EasternKingdoms/ScarletMonastery/boss_scorn.cpp
- EasternKingdoms/zone_undercity.cpp
- EasternKingdoms/zone_loch_modan.cpp
- EasternKingdoms/ShadowfangKeep/shadowfang_keep.cpp
- EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp
- EasternKingdoms/ShadowfangKeep/shadowfang_keep.h
- EasternKingdoms/zone_burning_steppes.cpp
- EasternKingdoms/zone_blasted_lands.cpp
- EasternKingdoms/zone_stormwind_city.cpp
- EasternKingdoms/ZulAman/boss_halazzi.cpp
- EasternKingdoms/ZulAman/boss_hexlord.cpp
- EasternKingdoms/ZulAman/boss_zuljin.cpp
- EasternKingdoms/ZulAman/boss_akilzon.cpp
- EasternKingdoms/ZulAman/instance_zulaman.cpp
- EasternKingdoms/ZulAman/boss_janalai.cpp
- EasternKingdoms/ZulAman/boss_nalorakk.cpp
- EasternKingdoms/ZulAman/zulaman.cpp
- EasternKingdoms/ZulAman/zulaman.h
- EasternKingdoms/zone_hinterlands.cpp
- EasternKingdoms/zone_western_plaguelands.cpp
- EasternKingdoms/zone_silverpine_forest.cpp
- EasternKingdoms/Karazhan/instance_karazhan.cpp
- EasternKingdoms/Karazhan/boss_nightbane.cpp
- EasternKingdoms/Karazhan/karazhan.cpp
- EasternKingdoms/Karazhan/boss_curator.cpp
- EasternKingdoms/Karazhan/boss_shade_of_aran.cpp
- EasternKingdoms/Karazhan/boss_netherspite.cpp
- EasternKingdoms/Karazhan/boss_maiden_of_virtue.cpp
- EasternKingdoms/Karazhan/boss_midnight.cpp
- EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp
- EasternKingdoms/Karazhan/bosses_opera.cpp
- EasternKingdoms/Karazhan/boss_moroes.cpp
- EasternKingdoms/Karazhan/boss_terestian_illhoof.cpp
- EasternKingdoms/Karazhan/karazhan.h
- EasternKingdoms/TheStockade/instance_the_stockade.cpp
-)
-
-message(" -> Prepared: Eastern Kingdoms")
diff --git a/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp b/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp
new file mode 100644
index 00000000000..8c781bb9001
--- /dev/null
+++ b/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp
@@ -0,0 +1,372 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_alterac_valley(); //Alterac Valley
+void AddSC_boss_balinda();
+void AddSC_boss_drekthar();
+void AddSC_boss_galvangar();
+void AddSC_boss_vanndar();
+void AddSC_blackrock_depths(); //Blackrock Depths
+void AddSC_boss_ambassador_flamelash();
+void AddSC_boss_draganthaurissan();
+void AddSC_boss_general_angerforge();
+void AddSC_boss_high_interrogator_gerstahn();
+void AddSC_boss_magmus();
+void AddSC_boss_moira_bronzebeard();
+void AddSC_boss_tomb_of_seven();
+void AddSC_instance_blackrock_depths();
+void AddSC_boss_drakkisath(); //Blackrock Spire
+void AddSC_boss_halycon();
+void AddSC_boss_highlordomokk();
+void AddSC_boss_mothersmolderweb();
+void AddSC_boss_overlordwyrmthalak();
+void AddSC_boss_shadowvosh();
+void AddSC_boss_thebeast();
+void AddSC_boss_warmastervoone();
+void AddSC_boss_quatermasterzigris();
+void AddSC_boss_pyroguard_emberseer();
+void AddSC_boss_gyth();
+void AddSC_boss_rend_blackhand();
+void AddSC_boss_gizrul_the_slavener();
+void AddSC_boss_urok_doomhowl();
+void AddSC_boss_lord_valthalak();
+void AddSC_instance_blackrock_spire();
+void AddSC_boss_razorgore(); //Blackwing lair
+void AddSC_boss_vaelastrasz();
+void AddSC_boss_broodlord();
+void AddSC_boss_firemaw();
+void AddSC_boss_ebonroc();
+void AddSC_boss_flamegor();
+void AddSC_boss_chromaggus();
+void AddSC_boss_nefarian();
+void AddSC_instance_blackwing_lair();
+void AddSC_deadmines(); //Deadmines
+void AddSC_instance_deadmines();
+void AddSC_boss_mr_smite();
+void AddSC_gnomeregan(); //Gnomeregan
+void AddSC_instance_gnomeregan();
+void AddSC_boss_attumen(); //Karazhan
+void AddSC_boss_curator();
+void AddSC_boss_maiden_of_virtue();
+void AddSC_boss_shade_of_aran();
+void AddSC_boss_malchezaar();
+void AddSC_boss_terestian_illhoof();
+void AddSC_boss_moroes();
+void AddSC_bosses_opera();
+void AddSC_boss_netherspite();
+void AddSC_instance_karazhan();
+void AddSC_karazhan();
+void AddSC_boss_nightbane();
+void AddSC_boss_felblood_kaelthas(); // Magister's Terrace
+void AddSC_boss_selin_fireheart();
+void AddSC_boss_vexallus();
+void AddSC_boss_priestess_delrissa();
+void AddSC_instance_magisters_terrace();
+void AddSC_magisters_terrace();
+void AddSC_boss_lucifron(); //Molten core
+void AddSC_boss_magmadar();
+void AddSC_boss_gehennas();
+void AddSC_boss_garr();
+void AddSC_boss_baron_geddon();
+void AddSC_boss_shazzrah();
+void AddSC_boss_golemagg();
+void AddSC_boss_sulfuron();
+void AddSC_boss_majordomo();
+void AddSC_boss_ragnaros();
+void AddSC_instance_molten_core();
+void AddSC_instance_ragefire_chasm(); //Ragefire Chasm
+void AddSC_the_scarlet_enclave(); //Scarlet Enclave
+void AddSC_the_scarlet_enclave_c1();
+void AddSC_the_scarlet_enclave_c2();
+void AddSC_the_scarlet_enclave_c5();
+void AddSC_boss_arcanist_doan(); //Scarlet Monastery
+void AddSC_boss_azshir_the_sleepless();
+void AddSC_boss_bloodmage_thalnos();
+void AddSC_boss_headless_horseman();
+void AddSC_boss_herod();
+void AddSC_boss_high_inquisitor_fairbanks();
+void AddSC_boss_houndmaster_loksey();
+void AddSC_boss_interrogator_vishas();
+void AddSC_boss_scorn();
+void AddSC_instance_scarlet_monastery();
+void AddSC_boss_mograine_and_whitemane();
+void AddSC_boss_darkmaster_gandling(); //Scholomance
+void AddSC_boss_death_knight_darkreaver();
+void AddSC_boss_theolenkrastinov();
+void AddSC_boss_illuciabarov();
+void AddSC_boss_instructormalicia();
+void AddSC_boss_jandicebarov();
+void AddSC_boss_kormok();
+void AddSC_boss_lordalexeibarov();
+void AddSC_boss_lorekeeperpolkelt();
+void AddSC_boss_rasfrost();
+void AddSC_boss_theravenian();
+void AddSC_boss_vectus();
+void AddSC_boss_kirtonos_the_herald();
+void AddSC_instance_scholomance();
+void AddSC_shadowfang_keep(); //Shadowfang keep
+void AddSC_instance_shadowfang_keep();
+void AddSC_boss_magistrate_barthilas(); //Stratholme
+void AddSC_boss_maleki_the_pallid();
+void AddSC_boss_nerubenkan();
+void AddSC_boss_cannon_master_willey();
+void AddSC_boss_baroness_anastari();
+void AddSC_boss_ramstein_the_gorger();
+void AddSC_boss_timmy_the_cruel();
+void AddSC_boss_postmaster_malown();
+void AddSC_boss_baron_rivendare();
+void AddSC_boss_dathrohan_balnazzar();
+void AddSC_boss_order_of_silver_hand();
+void AddSC_instance_stratholme();
+void AddSC_stratholme();
+void AddSC_sunken_temple(); // Sunken Temple
+void AddSC_instance_sunken_temple();
+void AddSC_instance_sunwell_plateau(); //Sunwell Plateau
+void AddSC_boss_kalecgos();
+void AddSC_boss_brutallus();
+void AddSC_boss_felmyst();
+void AddSC_boss_eredar_twins();
+void AddSC_boss_muru();
+void AddSC_boss_kiljaeden();
+void AddSC_sunwell_plateau();
+void AddSC_boss_archaedas(); //Uldaman
+void AddSC_boss_ironaya();
+void AddSC_uldaman();
+void AddSC_instance_uldaman();
+void AddSC_instance_the_stockade(); //The Stockade
+void AddSC_boss_akilzon(); //Zul'Aman
+void AddSC_boss_halazzi();
+void AddSC_boss_hex_lord_malacrass();
+void AddSC_boss_janalai();
+void AddSC_boss_nalorakk();
+void AddSC_boss_zuljin();
+void AddSC_instance_zulaman();
+void AddSC_zulaman();
+void AddSC_boss_jeklik(); //Zul'Gurub
+void AddSC_boss_venoxis();
+void AddSC_boss_marli();
+void AddSC_boss_mandokir();
+void AddSC_boss_gahzranka();
+void AddSC_boss_thekal();
+void AddSC_boss_arlokk();
+void AddSC_boss_jindo();
+void AddSC_boss_hakkar();
+void AddSC_boss_grilek();
+void AddSC_boss_hazzarah();
+void AddSC_boss_renataki();
+void AddSC_boss_wushoolay();
+void AddSC_instance_zulgurub();
+//void AddSC_alterac_mountains();
+void AddSC_arathi_highlands();
+void AddSC_blasted_lands();
+void AddSC_burning_steppes();
+void AddSC_duskwood();
+void AddSC_eastern_plaguelands();
+void AddSC_ghostlands();
+void AddSC_hinterlands();
+void AddSC_isle_of_queldanas();
+void AddSC_loch_modan();
+void AddSC_redridge_mountains();
+void AddSC_silverpine_forest();
+void AddSC_stormwind_city();
+void AddSC_stranglethorn_vale();
+void AddSC_swamp_of_sorrows();
+void AddSC_tirisfal_glades();
+void AddSC_undercity();
+void AddSC_western_plaguelands();
+void AddSC_wetlands();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddEasternKingdomsScripts()
+{
+ AddSC_alterac_valley(); //Alterac Valley
+ AddSC_boss_balinda();
+ AddSC_boss_drekthar();
+ AddSC_boss_galvangar();
+ AddSC_boss_vanndar();
+ AddSC_blackrock_depths(); //Blackrock Depths
+ AddSC_boss_ambassador_flamelash();
+ AddSC_boss_draganthaurissan();
+ AddSC_boss_general_angerforge();
+ AddSC_boss_high_interrogator_gerstahn();
+ AddSC_boss_magmus();
+ AddSC_boss_moira_bronzebeard();
+ AddSC_boss_tomb_of_seven();
+ AddSC_instance_blackrock_depths();
+ AddSC_boss_drakkisath(); //Blackrock Spire
+ AddSC_boss_halycon();
+ AddSC_boss_highlordomokk();
+ AddSC_boss_mothersmolderweb();
+ AddSC_boss_overlordwyrmthalak();
+ AddSC_boss_shadowvosh();
+ AddSC_boss_thebeast();
+ AddSC_boss_warmastervoone();
+ AddSC_boss_quatermasterzigris();
+ AddSC_boss_pyroguard_emberseer();
+ AddSC_boss_gyth();
+ AddSC_boss_rend_blackhand();
+ AddSC_boss_gizrul_the_slavener();
+ AddSC_boss_urok_doomhowl();
+ AddSC_boss_lord_valthalak();
+ AddSC_instance_blackrock_spire();
+ AddSC_boss_razorgore(); //Blackwing lair
+ AddSC_boss_vaelastrasz();
+ AddSC_boss_broodlord();
+ AddSC_boss_firemaw();
+ AddSC_boss_ebonroc();
+ AddSC_boss_flamegor();
+ AddSC_boss_chromaggus();
+ AddSC_boss_nefarian();
+ AddSC_instance_blackwing_lair();
+ AddSC_deadmines(); //Deadmines
+ AddSC_boss_mr_smite();
+ AddSC_instance_deadmines();
+ AddSC_gnomeregan(); //Gnomeregan
+ AddSC_instance_gnomeregan();
+ AddSC_boss_attumen(); //Karazhan
+ AddSC_boss_curator();
+ AddSC_boss_maiden_of_virtue();
+ AddSC_boss_shade_of_aran();
+ AddSC_boss_malchezaar();
+ AddSC_boss_terestian_illhoof();
+ AddSC_boss_moroes();
+ AddSC_bosses_opera();
+ AddSC_boss_netherspite();
+ AddSC_instance_karazhan();
+ AddSC_karazhan();
+ AddSC_boss_nightbane();
+ AddSC_boss_felblood_kaelthas(); // Magister's Terrace
+ AddSC_boss_selin_fireheart();
+ AddSC_boss_vexallus();
+ AddSC_boss_priestess_delrissa();
+ AddSC_instance_magisters_terrace();
+ AddSC_magisters_terrace();
+ AddSC_boss_lucifron(); //Molten core
+ AddSC_boss_magmadar();
+ AddSC_boss_gehennas();
+ AddSC_boss_garr();
+ AddSC_boss_baron_geddon();
+ AddSC_boss_shazzrah();
+ AddSC_boss_golemagg();
+ AddSC_boss_sulfuron();
+ AddSC_boss_majordomo();
+ AddSC_boss_ragnaros();
+ AddSC_instance_molten_core();
+ AddSC_instance_ragefire_chasm(); //Ragefire Chasm
+ AddSC_the_scarlet_enclave(); //Scarlet Enclave
+ AddSC_the_scarlet_enclave_c1();
+ AddSC_the_scarlet_enclave_c2();
+ AddSC_the_scarlet_enclave_c5();
+ AddSC_boss_arcanist_doan(); //Scarlet Monastery
+ AddSC_boss_azshir_the_sleepless();
+ AddSC_boss_bloodmage_thalnos();
+ AddSC_boss_headless_horseman();
+ AddSC_boss_herod();
+ AddSC_boss_high_inquisitor_fairbanks();
+ AddSC_boss_houndmaster_loksey();
+ AddSC_boss_interrogator_vishas();
+ AddSC_boss_scorn();
+ AddSC_instance_scarlet_monastery();
+ AddSC_boss_mograine_and_whitemane();
+ AddSC_boss_darkmaster_gandling(); //Scholomance
+ AddSC_boss_death_knight_darkreaver();
+ AddSC_boss_theolenkrastinov();
+ AddSC_boss_illuciabarov();
+ AddSC_boss_instructormalicia();
+ AddSC_boss_jandicebarov();
+ AddSC_boss_kormok();
+ AddSC_boss_lordalexeibarov();
+ AddSC_boss_lorekeeperpolkelt();
+ AddSC_boss_rasfrost();
+ AddSC_boss_theravenian();
+ AddSC_boss_vectus();
+ AddSC_boss_kirtonos_the_herald();
+ AddSC_instance_scholomance();
+ AddSC_shadowfang_keep(); //Shadowfang keep
+ AddSC_instance_shadowfang_keep();
+ AddSC_boss_magistrate_barthilas(); //Stratholme
+ AddSC_boss_maleki_the_pallid();
+ AddSC_boss_nerubenkan();
+ AddSC_boss_cannon_master_willey();
+ AddSC_boss_baroness_anastari();
+ AddSC_boss_ramstein_the_gorger();
+ AddSC_boss_timmy_the_cruel();
+ AddSC_boss_postmaster_malown();
+ AddSC_boss_baron_rivendare();
+ AddSC_boss_dathrohan_balnazzar();
+ AddSC_boss_order_of_silver_hand();
+ AddSC_instance_stratholme();
+ AddSC_stratholme();
+ AddSC_sunken_temple(); // Sunken Temple
+ AddSC_instance_sunken_temple();
+ AddSC_instance_sunwell_plateau(); //Sunwell Plateau
+ AddSC_boss_kalecgos();
+ AddSC_boss_brutallus();
+ AddSC_boss_felmyst();
+ AddSC_boss_eredar_twins();
+ AddSC_boss_muru();
+ AddSC_boss_kiljaeden();
+ AddSC_sunwell_plateau();
+ AddSC_instance_the_stockade(); //The Stockade
+ AddSC_boss_archaedas(); //Uldaman
+ AddSC_boss_ironaya();
+ AddSC_uldaman();
+ AddSC_instance_uldaman();
+ AddSC_boss_akilzon(); //Zul'Aman
+ AddSC_boss_halazzi();
+ AddSC_boss_hex_lord_malacrass();
+ AddSC_boss_janalai();
+ AddSC_boss_nalorakk();
+ AddSC_boss_zuljin();
+ AddSC_instance_zulaman();
+ AddSC_zulaman();
+ AddSC_boss_jeklik(); //Zul'Gurub
+ AddSC_boss_venoxis();
+ AddSC_boss_marli();
+ AddSC_boss_mandokir();
+ AddSC_boss_gahzranka();
+ AddSC_boss_thekal();
+ AddSC_boss_arlokk();
+ AddSC_boss_jindo();
+ AddSC_boss_hakkar();
+ AddSC_boss_grilek();
+ AddSC_boss_hazzarah();
+ AddSC_boss_renataki();
+ AddSC_boss_wushoolay();
+ AddSC_instance_zulgurub();
+ //AddSC_alterac_mountains();
+ AddSC_arathi_highlands();
+ AddSC_blasted_lands();
+ AddSC_burning_steppes();
+ AddSC_duskwood();
+ AddSC_eastern_plaguelands();
+ AddSC_ghostlands();
+ AddSC_hinterlands();
+ AddSC_isle_of_queldanas();
+ AddSC_loch_modan();
+ AddSC_redridge_mountains();
+ AddSC_silverpine_forest();
+ AddSC_stormwind_city();
+ AddSC_stranglethorn_vale();
+ AddSC_swamp_of_sorrows();
+ AddSC_tirisfal_glades();
+ AddSC_undercity();
+ AddSC_western_plaguelands();
+ AddSC_wetlands();
+}
diff --git a/src/server/scripts/Events/CMakeLists.txt b/src/server/scripts/Events/CMakeLists.txt
deleted file mode 100644
index 1c9e5cfe8e1..00000000000
--- a/src/server/scripts/Events/CMakeLists.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-file(GLOB_RECURSE sources_Events Events/*.cpp Events/*.h)
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- ${sources_Events}
-)
-
-message(" -> Prepared: Events")
diff --git a/src/server/scripts/Events/events_script_loader.cpp b/src/server/scripts/Events/events_script_loader.cpp
new file mode 100644
index 00000000000..625c08f5389
--- /dev/null
+++ b/src/server/scripts/Events/events_script_loader.cpp
@@ -0,0 +1,26 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_event_childrens_week();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddEventsScripts()
+{
+ AddSC_event_childrens_week();
+}
diff --git a/src/server/scripts/Kalimdor/CMakeLists.txt b/src/server/scripts/Kalimdor/CMakeLists.txt
deleted file mode 100644
index 2d1b4b49649..00000000000
--- a/src/server/scripts/Kalimdor/CMakeLists.txt
+++ /dev/null
@@ -1,121 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- Kalimdor/zone_stonetalon_mountains.cpp
- Kalimdor/zone_silithus.cpp
- Kalimdor/zone_moonglade.cpp
- Kalimdor/RazorfenDowns/razorfen_downs.cpp
- Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp
- Kalimdor/RazorfenDowns/boss_tuten_kash.cpp
- Kalimdor/RazorfenDowns/boss_mordresh_fire_eye.cpp
- Kalimdor/RazorfenDowns/boss_glutton.cpp
- Kalimdor/RazorfenDowns/boss_amnennar_the_coldbringer.cpp
- Kalimdor/RazorfenDowns/razorfen_downs.h
- Kalimdor/ZulFarrak/zulfarrak.cpp
- Kalimdor/ZulFarrak/instance_zulfarrak.cpp
- Kalimdor/ZulFarrak/boss_zum_rah.cpp
- Kalimdor/ZulFarrak/zulfarrak.h
- Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_epoch_hunter.cpp
- Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h
- Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_leutenant_drake.cpp
- Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp
- Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp
- Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_archimonde.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.h
- Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.h
- Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_kazrogal.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_rage_winterchill.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h
- Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_azgalor.cpp
- Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/boss_infinite_corruptor.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/boss_salramm_the_fleshcrafter.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/boss_meathook.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/boss_mal_ganis.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/boss_chrono_lord_epoch.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp
- Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h
- Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h
- Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp
- Kalimdor/CavernsOfTime/TheBlackMorass/boss_chrono_lord_deja.cpp
- Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp
- Kalimdor/CavernsOfTime/TheBlackMorass/boss_aeonus.cpp
- Kalimdor/CavernsOfTime/TheBlackMorass/boss_temporus.cpp
- Kalimdor/BlackfathomDeeps/boss_kelris.cpp
- Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp
- Kalimdor/BlackfathomDeeps/boss_gelihast.cpp
- Kalimdor/BlackfathomDeeps/blackfathom_deeps.cpp
- Kalimdor/BlackfathomDeeps/boss_aku_mai.cpp
- Kalimdor/BlackfathomDeeps/blackfathom_deeps.h
- Kalimdor/zone_azuremyst_isle.cpp
- Kalimdor/zone_orgrimmar.cpp
- Kalimdor/zone_desolace.cpp
- Kalimdor/zone_feralas.cpp
- Kalimdor/Maraudon/boss_princess_theradras.cpp
- Kalimdor/Maraudon/boss_landslide.cpp
- Kalimdor/Maraudon/boss_celebras_the_cursed.cpp
- Kalimdor/Maraudon/boss_noxxion.cpp
- Kalimdor/Maraudon/instance_maraudon.cpp
- Kalimdor/TempleOfAhnQiraj/boss_fankriss.cpp
- Kalimdor/TempleOfAhnQiraj/boss_huhuran.cpp
- Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp
- Kalimdor/TempleOfAhnQiraj/mob_anubisath_sentinel.cpp
- Kalimdor/TempleOfAhnQiraj/boss_viscidus.cpp
- Kalimdor/TempleOfAhnQiraj/boss_twinemperors.cpp
- Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp
- Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp
- Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h
- Kalimdor/TempleOfAhnQiraj/boss_skeram.cpp
- Kalimdor/TempleOfAhnQiraj/boss_ouro.cpp
- Kalimdor/TempleOfAhnQiraj/boss_bug_trio.cpp
- Kalimdor/zone_darkshore.cpp
- Kalimdor/RuinsOfAhnQiraj/boss_buru.cpp
- Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp
- Kalimdor/RuinsOfAhnQiraj/boss_rajaxx.cpp
- Kalimdor/RuinsOfAhnQiraj/boss_ossirian.cpp
- Kalimdor/RuinsOfAhnQiraj/boss_ayamiss.cpp
- Kalimdor/RuinsOfAhnQiraj/boss_moam.cpp
- Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h
- Kalimdor/RuinsOfAhnQiraj/boss_kurinnaxx.cpp
- Kalimdor/zone_bloodmyst_isle.cpp
- Kalimdor/zone_thunder_bluff.cpp
- Kalimdor/zone_azshara.cpp
- Kalimdor/RazorfenKraul/razorfen_kraul.h
- Kalimdor/RazorfenKraul/instance_razorfen_kraul.cpp
- Kalimdor/RazorfenKraul/razorfen_kraul.cpp
- Kalimdor/zone_the_barrens.cpp
- Kalimdor/zone_ungoro_crater.cpp
- Kalimdor/WailingCaverns/wailing_caverns.h
- Kalimdor/WailingCaverns/instance_wailing_caverns.cpp
- Kalimdor/WailingCaverns/wailing_caverns.cpp
- Kalimdor/zone_durotar.cpp
- Kalimdor/zone_felwood.cpp
- Kalimdor/boss_azuregos.cpp
- Kalimdor/zone_tanaris.cpp
- Kalimdor/zone_dustwallow_marsh.cpp
- Kalimdor/zone_winterspring.cpp
- Kalimdor/zone_thousand_needles.cpp
- Kalimdor/zone_ashenvale.cpp
- Kalimdor/OnyxiasLair/boss_onyxia.cpp
- Kalimdor/OnyxiasLair/onyxias_lair.h
- Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp
- Kalimdor/RagefireChasm/instance_ragefire_chasm.cpp
- Kalimdor/DireMaul/instance_dire_maul.cpp
-)
-
-message(" -> Prepared: Kalimdor")
diff --git a/src/server/scripts/Kalimdor/kalimdor_script_loader.cpp b/src/server/scripts/Kalimdor/kalimdor_script_loader.cpp
new file mode 100644
index 00000000000..f1969a063d6
--- /dev/null
+++ b/src/server/scripts/Kalimdor/kalimdor_script_loader.cpp
@@ -0,0 +1,206 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_blackfathom_deeps(); //Blackfathom Depths
+void AddSC_boss_gelihast();
+void AddSC_boss_kelris();
+void AddSC_boss_aku_mai();
+void AddSC_instance_blackfathom_deeps();
+void AddSC_hyjal(); //CoT Battle for Mt. Hyjal
+void AddSC_boss_archimonde();
+void AddSC_instance_mount_hyjal();
+void AddSC_hyjal_trash();
+void AddSC_boss_rage_winterchill();
+void AddSC_boss_anetheron();
+void AddSC_boss_kazrogal();
+void AddSC_boss_azgalor();
+void AddSC_boss_captain_skarloc(); //CoT Old Hillsbrad
+void AddSC_boss_epoch_hunter();
+void AddSC_boss_lieutenant_drake();
+void AddSC_instance_old_hillsbrad();
+void AddSC_old_hillsbrad();
+void AddSC_boss_aeonus(); //CoT The Black Morass
+void AddSC_boss_chrono_lord_deja();
+void AddSC_boss_temporus();
+void AddSC_the_black_morass();
+void AddSC_instance_the_black_morass();
+void AddSC_boss_epoch(); //CoT Culling Of Stratholme
+void AddSC_boss_infinite_corruptor();
+void AddSC_boss_salramm();
+void AddSC_boss_mal_ganis();
+void AddSC_boss_meathook();
+void AddSC_culling_of_stratholme();
+void AddSC_instance_culling_of_stratholme();
+void AddSC_instance_dire_maul(); //Dire Maul
+void AddSC_boss_celebras_the_cursed(); //Maraudon
+void AddSC_boss_landslide();
+void AddSC_boss_noxxion();
+void AddSC_boss_ptheradras();
+void AddSC_instance_maraudon();
+void AddSC_boss_onyxia(); //Onyxia's Lair
+void AddSC_instance_onyxias_lair();
+void AddSC_boss_tuten_kash(); //Razorfen Downs
+void AddSC_boss_mordresh_fire_eye();
+void AddSC_boss_glutton();
+void AddSC_boss_amnennar_the_coldbringer();
+void AddSC_razorfen_downs();
+void AddSC_instance_razorfen_downs();
+void AddSC_razorfen_kraul(); //Razorfen Kraul
+void AddSC_instance_razorfen_kraul();
+void AddSC_boss_kurinnaxx(); //Ruins of ahn'qiraj
+void AddSC_boss_rajaxx();
+void AddSC_boss_moam();
+void AddSC_boss_buru();
+void AddSC_boss_ayamiss();
+void AddSC_boss_ossirian();
+void AddSC_instance_ruins_of_ahnqiraj();
+void AddSC_boss_cthun(); //Temple of ahn'qiraj
+void AddSC_boss_viscidus();
+void AddSC_boss_fankriss();
+void AddSC_boss_huhuran();
+void AddSC_bug_trio();
+void AddSC_boss_sartura();
+void AddSC_boss_skeram();
+void AddSC_boss_twinemperors();
+void AddSC_boss_ouro();
+void AddSC_npc_anubisath_sentinel();
+void AddSC_instance_temple_of_ahnqiraj();
+void AddSC_wailing_caverns(); //Wailing caverns
+void AddSC_instance_wailing_caverns();
+void AddSC_boss_zum_rah(); //Zul'Farrak
+void AddSC_zulfarrak();
+void AddSC_instance_zulfarrak();
+
+void AddSC_ashenvale();
+void AddSC_azshara();
+void AddSC_azuremyst_isle();
+void AddSC_bloodmyst_isle();
+void AddSC_boss_azuregos();
+void AddSC_darkshore();
+void AddSC_desolace();
+void AddSC_durotar();
+void AddSC_dustwallow_marsh();
+void AddSC_felwood();
+void AddSC_feralas();
+void AddSC_moonglade();
+void AddSC_orgrimmar();
+void AddSC_silithus();
+void AddSC_stonetalon_mountains();
+void AddSC_tanaris();
+void AddSC_the_barrens();
+void AddSC_thousand_needles();
+void AddSC_thunder_bluff();
+void AddSC_ungoro_crater();
+void AddSC_winterspring();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddKalimdorScripts()
+{
+ AddSC_blackfathom_deeps(); //Blackfathom Depths
+ AddSC_boss_gelihast();
+ AddSC_boss_kelris();
+ AddSC_boss_aku_mai();
+ AddSC_instance_blackfathom_deeps();
+ AddSC_hyjal(); //CoT Battle for Mt. Hyjal
+ AddSC_boss_archimonde();
+ AddSC_instance_mount_hyjal();
+ AddSC_hyjal_trash();
+ AddSC_boss_rage_winterchill();
+ AddSC_boss_anetheron();
+ AddSC_boss_kazrogal();
+ AddSC_boss_azgalor();
+ AddSC_boss_captain_skarloc(); //CoT Old Hillsbrad
+ AddSC_boss_epoch_hunter();
+ AddSC_boss_lieutenant_drake();
+ AddSC_instance_old_hillsbrad();
+ AddSC_old_hillsbrad();
+ AddSC_boss_aeonus(); //CoT The Black Morass
+ AddSC_boss_chrono_lord_deja();
+ AddSC_boss_temporus();
+ AddSC_the_black_morass();
+ AddSC_instance_the_black_morass();
+ AddSC_boss_epoch(); //CoT Culling Of Stratholme
+ AddSC_boss_infinite_corruptor();
+ AddSC_boss_salramm();
+ AddSC_boss_mal_ganis();
+ AddSC_boss_meathook();
+ AddSC_culling_of_stratholme();
+ AddSC_instance_culling_of_stratholme();
+ AddSC_instance_dire_maul(); //Dire Maul
+ AddSC_boss_celebras_the_cursed(); //Maraudon
+ AddSC_boss_landslide();
+ AddSC_boss_noxxion();
+ AddSC_boss_ptheradras();
+ AddSC_instance_maraudon();
+ AddSC_boss_onyxia(); //Onyxia's Lair
+ AddSC_instance_onyxias_lair();
+ AddSC_boss_tuten_kash(); //Razorfen Downs
+ AddSC_boss_mordresh_fire_eye();
+ AddSC_boss_glutton();
+ AddSC_boss_amnennar_the_coldbringer();
+ AddSC_razorfen_downs();
+ AddSC_instance_razorfen_downs();
+ AddSC_razorfen_kraul(); //Razorfen Kraul
+ AddSC_instance_razorfen_kraul();
+ AddSC_boss_kurinnaxx(); //Ruins of ahn'qiraj
+ AddSC_boss_rajaxx();
+ AddSC_boss_moam();
+ AddSC_boss_buru();
+ AddSC_boss_ayamiss();
+ AddSC_boss_ossirian();
+ AddSC_instance_ruins_of_ahnqiraj();
+ AddSC_boss_cthun(); //Temple of ahn'qiraj
+ AddSC_boss_viscidus();
+ AddSC_boss_fankriss();
+ AddSC_boss_huhuran();
+ AddSC_bug_trio();
+ AddSC_boss_sartura();
+ AddSC_boss_skeram();
+ AddSC_boss_twinemperors();
+ AddSC_boss_ouro();
+ AddSC_npc_anubisath_sentinel();
+ AddSC_instance_temple_of_ahnqiraj();
+ AddSC_wailing_caverns(); //Wailing caverns
+ AddSC_instance_wailing_caverns();
+ AddSC_boss_zum_rah(); //Zul'Farrak
+ AddSC_zulfarrak();
+ AddSC_instance_zulfarrak();
+
+ AddSC_ashenvale();
+ AddSC_azshara();
+ AddSC_azuremyst_isle();
+ AddSC_bloodmyst_isle();
+ AddSC_boss_azuregos();
+ AddSC_darkshore();
+ AddSC_desolace();
+ AddSC_durotar();
+ AddSC_dustwallow_marsh();
+ AddSC_felwood();
+ AddSC_feralas();
+ AddSC_moonglade();
+ AddSC_orgrimmar();
+ AddSC_silithus();
+ AddSC_stonetalon_mountains();
+ AddSC_tanaris();
+ AddSC_the_barrens();
+ AddSC_thousand_needles();
+ AddSC_thunder_bluff();
+ AddSC_ungoro_crater();
+ AddSC_winterspring();
+}
diff --git a/src/server/scripts/Northrend/CMakeLists.txt b/src/server/scripts/Northrend/CMakeLists.txt
deleted file mode 100644
index 1dc453ad416..00000000000
--- a/src/server/scripts/Northrend/CMakeLists.txt
+++ /dev/null
@@ -1,199 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- Northrend/zone_wintergrasp.cpp
- Northrend/isle_of_conquest.cpp
- Northrend/zone_storm_peaks.cpp
- Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp
- Northrend/Ulduar/HallsOfLightning/boss_bjarngrim.cpp
- Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h
- Northrend/Ulduar/HallsOfLightning/boss_ionar.cpp
- Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp
- Northrend/Ulduar/HallsOfLightning/boss_loken.cpp
- Northrend/Ulduar/Ulduar/boss_general_vezax.cpp
- Northrend/Ulduar/Ulduar/boss_thorim.cpp
- Northrend/Ulduar/Ulduar/boss_ignis.cpp
- Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp
- Northrend/Ulduar/Ulduar/instance_ulduar.cpp
- Northrend/Ulduar/Ulduar/boss_auriaya.cpp
- Northrend/Ulduar/Ulduar/boss_yogg_saron.cpp
- Northrend/Ulduar/Ulduar/boss_hodir.cpp
- Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp
- Northrend/Ulduar/Ulduar/boss_flame_leviathan.cpp
- Northrend/Ulduar/Ulduar/boss_xt002.cpp
- Northrend/Ulduar/Ulduar/boss_mimiron.cpp
- Northrend/Ulduar/Ulduar/ulduar.h
- Northrend/Ulduar/Ulduar/boss_freya.cpp
- Northrend/Ulduar/Ulduar/boss_razorscale.cpp
- Northrend/Ulduar/Ulduar/boss_kologarn.cpp
- Northrend/Ulduar/HallsOfStone/boss_krystallus.cpp
- Northrend/Ulduar/HallsOfStone/halls_of_stone.h
- Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp
- Northrend/Ulduar/HallsOfStone/boss_maiden_of_grief.cpp
- Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp
- Northrend/Ulduar/HallsOfStone/halls_of_stone.cpp
- Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp
- Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h
- Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp
- Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.cpp
- Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp
- Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h
- Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.cpp
- Northrend/ChamberOfAspects/RubySanctum/boss_baltharus_the_warborn.cpp
- Northrend/ChamberOfAspects/RubySanctum/boss_saviana_ragefire.cpp
- Northrend/ChamberOfAspects/RubySanctum/boss_general_zarithrian.cpp
- Northrend/ChamberOfAspects/RubySanctum/boss_halion.cpp
- Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h
- Northrend/FrozenHalls/HallsOfReflection/boss_falric.cpp
- Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp
- Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.cpp
- Northrend/FrozenHalls/HallsOfReflection/boss_marwyn.cpp
- Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp
- Northrend/FrozenHalls/PitOfSaron/boss_krickandick.cpp
- Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp
- Northrend/FrozenHalls/PitOfSaron/boss_scourgelord_tyrannus.cpp
- Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h
- Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp
- Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.cpp
- Northrend/FrozenHalls/ForgeOfSouls/boss_bronjahm.cpp
- Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp
- Northrend/FrozenHalls/ForgeOfSouls/boss_devourer_of_souls.cpp
- Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h
- Northrend/Nexus/EyeOfEternity/boss_malygos.cpp
- Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp
- Northrend/Nexus/EyeOfEternity/eye_of_eternity.h
- Northrend/Nexus/Oculus/boss_eregos.cpp
- Northrend/Nexus/Oculus/boss_drakos.cpp
- Northrend/Nexus/Oculus/oculus.h
- Northrend/Nexus/Oculus/boss_varos.cpp
- Northrend/Nexus/Oculus/boss_urom.cpp
- Northrend/Nexus/Oculus/oculus.cpp
- Northrend/Nexus/Oculus/instance_oculus.cpp
- Northrend/Nexus/Nexus/boss_nexus_commanders.cpp
- Northrend/Nexus/Nexus/boss_ormorok.cpp
- Northrend/Nexus/Nexus/boss_magus_telestra.cpp
- Northrend/Nexus/Nexus/instance_nexus.cpp
- Northrend/Nexus/Nexus/boss_keristrasza.cpp
- Northrend/Nexus/Nexus/boss_anomalus.cpp
- Northrend/Nexus/Nexus/nexus.h
- Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_anubarak_trial.cpp
- Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp
- Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_lord_jaraxxus.cpp
- Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.h
- Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp
- Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.cpp
- Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp
- Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp
- Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h
- Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.cpp
- Northrend/CrusadersColiseum/TrialOfTheChampion/boss_grand_champions.cpp
- Northrend/CrusadersColiseum/TrialOfTheChampion/boss_black_knight.cpp
- Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp
- Northrend/CrusadersColiseum/TrialOfTheChampion/boss_argent_challenge.cpp
- Northrend/Naxxramas/boss_loatheb.cpp
- Northrend/Naxxramas/boss_anubrekhan.cpp
- Northrend/Naxxramas/boss_maexxna.cpp
- Northrend/Naxxramas/boss_patchwerk.cpp
- Northrend/Naxxramas/boss_gothik.cpp
- Northrend/Naxxramas/boss_faerlina.cpp
- Northrend/Naxxramas/boss_gluth.cpp
- Northrend/Naxxramas/boss_four_horsemen.cpp
- Northrend/Naxxramas/naxxramas.h
- Northrend/Naxxramas/boss_kelthuzad.cpp
- Northrend/Naxxramas/boss_heigan.cpp
- Northrend/Naxxramas/boss_thaddius.cpp
- Northrend/Naxxramas/boss_razuvious.cpp
- Northrend/Naxxramas/boss_sapphiron.cpp
- Northrend/Naxxramas/instance_naxxramas.cpp
- Northrend/Naxxramas/boss_grobbulus.cpp
- Northrend/Naxxramas/boss_noth.cpp
- Northrend/zone_crystalsong_forest.cpp
- Northrend/VaultOfArchavon/boss_archavon.cpp
- Northrend/VaultOfArchavon/boss_koralon.cpp
- Northrend/VaultOfArchavon/vault_of_archavon.h
- Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp
- Northrend/VaultOfArchavon/boss_emalon.cpp
- Northrend/VaultOfArchavon/boss_toravon.cpp
- Northrend/zone_sholazar_basin.cpp
- Northrend/UtgardeKeep/UtgardePinnacle/boss_svala.cpp
- Northrend/UtgardeKeep/UtgardePinnacle/boss_palehoof.cpp
- Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp
- Northrend/UtgardeKeep/UtgardePinnacle/boss_ymiron.cpp
- Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp
- Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h
- Northrend/UtgardeKeep/UtgardeKeep/boss_ingvar_the_plunderer.cpp
- Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp
- Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.h
- Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp
- Northrend/UtgardeKeep/UtgardeKeep/boss_keleseth.cpp
- Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.cpp
- Northrend/zone_dragonblight.cpp
- Northrend/zone_grizzly_hills.cpp
- Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h
- Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp
- Northrend/AzjolNerub/AzjolNerub/boss_krikthir_the_gatewatcher.cpp
- Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp
- Northrend/AzjolNerub/AzjolNerub/boss_anubarak.cpp
- Northrend/AzjolNerub/Ahnkahet/boss_herald_volazj.cpp
- Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp
- Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp
- Northrend/AzjolNerub/Ahnkahet/boss_jedoga_shadowseeker.cpp
- Northrend/AzjolNerub/Ahnkahet/boss_elder_nadox.cpp
- Northrend/AzjolNerub/Ahnkahet/boss_amanitar.cpp
- Northrend/AzjolNerub/Ahnkahet/ahnkahet.h
- Northrend/VioletHold/boss_zuramat.cpp
- Northrend/VioletHold/instance_violet_hold.cpp
- Northrend/VioletHold/boss_lavanthor.cpp
- Northrend/VioletHold/boss_cyanigosa.cpp
- Northrend/VioletHold/violet_hold.h
- Northrend/VioletHold/boss_ichoron.cpp
- Northrend/VioletHold/boss_moragg.cpp
- Northrend/VioletHold/boss_xevozz.cpp
- Northrend/VioletHold/boss_erekem.cpp
- Northrend/VioletHold/violet_hold.cpp
- Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp
- Northrend/IcecrownCitadel/icecrown_citadel.cpp
- Northrend/IcecrownCitadel/icecrown_citadel.h
- Northrend/IcecrownCitadel/icecrown_citadel_teleport.cpp
- Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp
- Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp
- Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp
- Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp
- Northrend/IcecrownCitadel/boss_festergut.cpp
- Northrend/IcecrownCitadel/boss_rotface.cpp
- Northrend/IcecrownCitadel/boss_professor_putricide.cpp
- Northrend/IcecrownCitadel/boss_blood_prince_council.cpp
- Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
- Northrend/IcecrownCitadel/boss_valithria_dreamwalker.cpp
- Northrend/IcecrownCitadel/boss_sindragosa.cpp
- Northrend/IcecrownCitadel/boss_the_lich_king.cpp
- Northrend/zone_zuldrak.cpp
- Northrend/zone_icecrown.cpp
- Northrend/Gundrak/boss_slad_ran.cpp
- Northrend/Gundrak/instance_gundrak.cpp
- Northrend/Gundrak/boss_drakkari_colossus.cpp
- Northrend/Gundrak/gundrak.h
- Northrend/Gundrak/boss_gal_darah.cpp
- Northrend/Gundrak/boss_moorabi.cpp
- Northrend/Gundrak/boss_eck.cpp
- Northrend/zone_borean_tundra.cpp
- Northrend/zone_howling_fjord.cpp
- Northrend/zone_dalaran.cpp
- Northrend/DraktharonKeep/boss_trollgore.cpp
- Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp
- Northrend/DraktharonKeep/boss_novos.cpp
- Northrend/DraktharonKeep/drak_tharon_keep.h
- Northrend/DraktharonKeep/boss_tharon_ja.cpp
- Northrend/DraktharonKeep/boss_king_dred.cpp
-)
-
-message(" -> Prepared: Northrend")
diff --git a/src/server/scripts/Northrend/northrend_script_loader.cpp b/src/server/scripts/Northrend/northrend_script_loader.cpp
new file mode 100644
index 00000000000..7d104b85f6d
--- /dev/null
+++ b/src/server/scripts/Northrend/northrend_script_loader.cpp
@@ -0,0 +1,374 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_boss_slad_ran();
+void AddSC_boss_moorabi();
+void AddSC_boss_drakkari_colossus();
+void AddSC_boss_gal_darah();
+void AddSC_boss_eck();
+void AddSC_instance_gundrak();
+
+// Azjol-Nerub - Azjol-Nerub
+void AddSC_boss_krik_thir();
+void AddSC_boss_hadronox();
+void AddSC_boss_anub_arak();
+void AddSC_instance_azjol_nerub();
+
+// Azjol-Nerub - Ahn'kahet
+void AddSC_boss_elder_nadox();
+void AddSC_boss_taldaram();
+void AddSC_boss_amanitar();
+void AddSC_boss_jedoga_shadowseeker();
+void AddSC_boss_volazj();
+void AddSC_instance_ahnkahet();
+
+// Drak'Tharon Keep
+void AddSC_boss_trollgore();
+void AddSC_boss_novos();
+void AddSC_boss_king_dred();
+void AddSC_boss_tharon_ja();
+void AddSC_instance_drak_tharon_keep();
+
+void AddSC_boss_argent_challenge(); //Trial of the Champion
+void AddSC_boss_black_knight();
+void AddSC_boss_grand_champions();
+void AddSC_instance_trial_of_the_champion();
+void AddSC_trial_of_the_champion();
+void AddSC_boss_anubarak_trial(); //Trial of the Crusader
+void AddSC_boss_faction_champions();
+void AddSC_boss_jaraxxus();
+void AddSC_boss_northrend_beasts();
+void AddSC_boss_twin_valkyr();
+void AddSC_trial_of_the_crusader();
+void AddSC_instance_trial_of_the_crusader();
+void AddSC_boss_anubrekhan(); //Naxxramas
+void AddSC_boss_maexxna();
+void AddSC_boss_patchwerk();
+void AddSC_boss_grobbulus();
+void AddSC_boss_razuvious();
+void AddSC_boss_kelthuzad();
+void AddSC_boss_loatheb();
+void AddSC_boss_noth();
+void AddSC_boss_gluth();
+void AddSC_boss_sapphiron();
+void AddSC_boss_four_horsemen();
+void AddSC_boss_faerlina();
+void AddSC_boss_heigan();
+void AddSC_boss_gothik();
+void AddSC_boss_thaddius();
+void AddSC_instance_naxxramas();
+void AddSC_boss_nexus_commanders(); // The Nexus Nexus
+void AddSC_boss_magus_telestra();
+void AddSC_boss_anomalus();
+void AddSC_boss_ormorok();
+void AddSC_boss_keristrasza();
+void AddSC_instance_nexus();
+void AddSC_boss_drakos(); //The Nexus The Oculus
+void AddSC_boss_urom();
+void AddSC_boss_varos();
+void AddSC_boss_eregos();
+void AddSC_instance_oculus();
+void AddSC_oculus();
+void AddSC_boss_malygos(); // The Nexus: Eye of Eternity
+void AddSC_instance_eye_of_eternity();
+void AddSC_boss_sartharion(); //Obsidian Sanctum
+void AddSC_obsidian_sanctum();
+void AddSC_instance_obsidian_sanctum();
+void AddSC_boss_bjarngrim(); //Ulduar Halls of Lightning
+void AddSC_boss_loken();
+void AddSC_boss_ionar();
+void AddSC_boss_volkhan();
+void AddSC_instance_halls_of_lightning();
+void AddSC_boss_maiden_of_grief(); //Ulduar Halls of Stone
+void AddSC_boss_krystallus();
+void AddSC_boss_sjonnir();
+void AddSC_instance_halls_of_stone();
+void AddSC_halls_of_stone();
+void AddSC_boss_auriaya(); //Ulduar Ulduar
+void AddSC_boss_flame_leviathan();
+void AddSC_boss_ignis();
+void AddSC_boss_razorscale();
+void AddSC_boss_xt002();
+void AddSC_boss_kologarn();
+void AddSC_boss_assembly_of_iron();
+void AddSC_boss_general_vezax();
+void AddSC_boss_mimiron();
+void AddSC_boss_hodir();
+void AddSC_boss_freya();
+void AddSC_boss_yogg_saron();
+void AddSC_boss_algalon_the_observer();
+void AddSC_instance_ulduar();
+
+// Utgarde Keep - Utgarde Keep
+void AddSC_boss_keleseth();
+void AddSC_boss_skarvald_dalronn();
+void AddSC_boss_ingvar_the_plunderer();
+void AddSC_instance_utgarde_keep();
+void AddSC_utgarde_keep();
+
+// Utgarde Keep - Utgarde Pinnacle
+void AddSC_boss_svala();
+void AddSC_boss_palehoof();
+void AddSC_boss_skadi();
+void AddSC_boss_ymiron();
+void AddSC_instance_utgarde_pinnacle();
+
+// Vault of Archavon
+void AddSC_boss_archavon();
+void AddSC_boss_emalon();
+void AddSC_boss_koralon();
+void AddSC_boss_toravon();
+void AddSC_instance_vault_of_archavon();
+
+void AddSC_boss_cyanigosa(); //Violet Hold
+void AddSC_boss_erekem();
+void AddSC_boss_ichoron();
+void AddSC_boss_lavanthor();
+void AddSC_boss_moragg();
+void AddSC_boss_xevozz();
+void AddSC_boss_zuramat();
+void AddSC_instance_violet_hold();
+void AddSC_violet_hold();
+void AddSC_instance_forge_of_souls(); //Forge of Souls
+void AddSC_forge_of_souls();
+void AddSC_boss_bronjahm();
+void AddSC_boss_devourer_of_souls();
+void AddSC_instance_pit_of_saron(); //Pit of Saron
+void AddSC_pit_of_saron();
+void AddSC_boss_garfrost();
+void AddSC_boss_ick();
+void AddSC_boss_tyrannus();
+void AddSC_instance_halls_of_reflection(); // Halls of Reflection
+void AddSC_halls_of_reflection();
+void AddSC_boss_falric();
+void AddSC_boss_marwyn();
+void AddSC_boss_lord_marrowgar(); // Icecrown Citadel
+void AddSC_boss_lady_deathwhisper();
+void AddSC_boss_icecrown_gunship_battle();
+void AddSC_boss_deathbringer_saurfang();
+void AddSC_boss_festergut();
+void AddSC_boss_rotface();
+void AddSC_boss_professor_putricide();
+void AddSC_boss_blood_prince_council();
+void AddSC_boss_blood_queen_lana_thel();
+void AddSC_boss_valithria_dreamwalker();
+void AddSC_boss_sindragosa();
+void AddSC_boss_the_lich_king();
+void AddSC_icecrown_citadel_teleport();
+void AddSC_instance_icecrown_citadel();
+void AddSC_icecrown_citadel();
+void AddSC_instance_ruby_sanctum(); // Ruby Sanctum
+void AddSC_ruby_sanctum();
+void AddSC_boss_baltharus_the_warborn();
+void AddSC_boss_saviana_ragefire();
+void AddSC_boss_general_zarithrian();
+void AddSC_boss_halion();
+
+void AddSC_dalaran();
+void AddSC_borean_tundra();
+void AddSC_dragonblight();
+void AddSC_grizzly_hills();
+void AddSC_howling_fjord();
+void AddSC_icecrown();
+void AddSC_sholazar_basin();
+void AddSC_storm_peaks();
+void AddSC_wintergrasp();
+void AddSC_zuldrak();
+void AddSC_crystalsong_forest();
+void AddSC_isle_of_conquest();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddNorthrendScripts()
+{
+ AddSC_boss_slad_ran(); //Gundrak
+ AddSC_boss_moorabi();
+ AddSC_boss_drakkari_colossus();
+ AddSC_boss_gal_darah();
+ AddSC_boss_eck();
+ AddSC_instance_gundrak();
+
+ // Azjol-Nerub - Ahn'kahet
+ AddSC_boss_elder_nadox();
+ AddSC_boss_taldaram();
+ AddSC_boss_amanitar();
+ AddSC_boss_jedoga_shadowseeker();
+ AddSC_boss_volazj();
+ AddSC_instance_ahnkahet();
+
+ // Azjol-Nerub - Azjol-Nerub
+ AddSC_boss_krik_thir();
+ AddSC_boss_hadronox();
+ AddSC_boss_anub_arak();
+ AddSC_instance_azjol_nerub();
+
+ // Drak'Tharon Keep
+ AddSC_boss_trollgore();
+ AddSC_boss_novos();
+ AddSC_boss_king_dred();
+ AddSC_boss_tharon_ja();
+ AddSC_instance_drak_tharon_keep();
+
+ AddSC_boss_argent_challenge(); //Trial of the Champion
+ AddSC_boss_black_knight();
+ AddSC_boss_grand_champions();
+ AddSC_instance_trial_of_the_champion();
+ AddSC_trial_of_the_champion();
+ AddSC_boss_anubarak_trial(); //Trial of the Crusader
+ AddSC_boss_faction_champions();
+ AddSC_boss_jaraxxus();
+ AddSC_trial_of_the_crusader();
+ AddSC_boss_twin_valkyr();
+ AddSC_boss_northrend_beasts();
+ AddSC_instance_trial_of_the_crusader();
+ AddSC_boss_anubrekhan(); //Naxxramas
+ AddSC_boss_maexxna();
+ AddSC_boss_patchwerk();
+ AddSC_boss_grobbulus();
+ AddSC_boss_razuvious();
+ AddSC_boss_kelthuzad();
+ AddSC_boss_loatheb();
+ AddSC_boss_noth();
+ AddSC_boss_gluth();
+ AddSC_boss_sapphiron();
+ AddSC_boss_four_horsemen();
+ AddSC_boss_faerlina();
+ AddSC_boss_heigan();
+ AddSC_boss_gothik();
+ AddSC_boss_thaddius();
+ AddSC_instance_naxxramas();
+ AddSC_boss_nexus_commanders(); // The Nexus Nexus
+ AddSC_boss_magus_telestra();
+ AddSC_boss_anomalus();
+ AddSC_boss_ormorok();
+ AddSC_boss_keristrasza();
+ AddSC_instance_nexus();
+ AddSC_boss_drakos(); //The Nexus The Oculus
+ AddSC_boss_urom();
+ AddSC_boss_varos();
+ AddSC_boss_eregos();
+ AddSC_instance_oculus();
+ AddSC_oculus();
+ AddSC_boss_malygos(); // The Nexus: Eye of Eternity
+ AddSC_instance_eye_of_eternity();
+ AddSC_boss_sartharion(); //Obsidian Sanctum
+ AddSC_obsidian_sanctum();
+ AddSC_instance_obsidian_sanctum();
+ AddSC_boss_bjarngrim(); //Ulduar Halls of Lightning
+ AddSC_boss_loken();
+ AddSC_boss_ionar();
+ AddSC_boss_volkhan();
+ AddSC_instance_halls_of_lightning();
+ AddSC_boss_maiden_of_grief(); //Ulduar Halls of Stone
+ AddSC_boss_krystallus();
+ AddSC_boss_sjonnir();
+ AddSC_instance_halls_of_stone();
+ AddSC_halls_of_stone();
+ AddSC_boss_auriaya(); //Ulduar Ulduar
+ AddSC_boss_flame_leviathan();
+ AddSC_boss_ignis();
+ AddSC_boss_razorscale();
+ AddSC_boss_xt002();
+ AddSC_boss_general_vezax();
+ AddSC_boss_assembly_of_iron();
+ AddSC_boss_kologarn();
+ AddSC_boss_mimiron();
+ AddSC_boss_hodir();
+ AddSC_boss_freya();
+ AddSC_boss_yogg_saron();
+ AddSC_boss_algalon_the_observer();
+ AddSC_instance_ulduar();
+
+ // Utgarde Keep - Utgarde Keep
+ AddSC_boss_keleseth();
+ AddSC_boss_skarvald_dalronn();
+ AddSC_boss_ingvar_the_plunderer();
+ AddSC_instance_utgarde_keep();
+ AddSC_utgarde_keep();
+
+ // Utgarde Keep - Utgarde Pinnacle
+ AddSC_boss_svala();
+ AddSC_boss_palehoof();
+ AddSC_boss_skadi();
+ AddSC_boss_ymiron();
+ AddSC_instance_utgarde_pinnacle();
+
+ // Vault of Archavon
+ AddSC_boss_archavon();
+ AddSC_boss_emalon();
+ AddSC_boss_koralon();
+ AddSC_boss_toravon();
+ AddSC_instance_vault_of_archavon();
+
+ AddSC_boss_cyanigosa(); //Violet Hold
+ AddSC_boss_erekem();
+ AddSC_boss_ichoron();
+ AddSC_boss_lavanthor();
+ AddSC_boss_moragg();
+ AddSC_boss_xevozz();
+ AddSC_boss_zuramat();
+ AddSC_instance_violet_hold();
+ AddSC_violet_hold();
+ AddSC_instance_forge_of_souls(); //Forge of Souls
+ AddSC_forge_of_souls();
+ AddSC_boss_bronjahm();
+ AddSC_boss_devourer_of_souls();
+ AddSC_instance_pit_of_saron(); //Pit of Saron
+ AddSC_pit_of_saron();
+ AddSC_boss_garfrost();
+ AddSC_boss_ick();
+ AddSC_boss_tyrannus();
+ AddSC_instance_halls_of_reflection(); // Halls of Reflection
+ AddSC_halls_of_reflection();
+ AddSC_boss_falric();
+ AddSC_boss_marwyn();
+ AddSC_boss_lord_marrowgar(); // Icecrown Citadel
+ AddSC_boss_lady_deathwhisper();
+ AddSC_boss_icecrown_gunship_battle();
+ AddSC_boss_deathbringer_saurfang();
+ AddSC_boss_festergut();
+ AddSC_boss_rotface();
+ AddSC_boss_professor_putricide();
+ AddSC_boss_blood_prince_council();
+ AddSC_boss_blood_queen_lana_thel();
+ AddSC_boss_valithria_dreamwalker();
+ AddSC_boss_sindragosa();
+ AddSC_boss_the_lich_king();
+ AddSC_icecrown_citadel_teleport();
+ AddSC_instance_icecrown_citadel();
+ AddSC_icecrown_citadel();
+ AddSC_instance_ruby_sanctum(); // Ruby Sanctum
+ AddSC_ruby_sanctum();
+ AddSC_boss_baltharus_the_warborn();
+ AddSC_boss_saviana_ragefire();
+ AddSC_boss_general_zarithrian();
+ AddSC_boss_halion();
+
+ AddSC_dalaran();
+ AddSC_borean_tundra();
+ AddSC_dragonblight();
+ AddSC_grizzly_hills();
+ AddSC_howling_fjord();
+ AddSC_icecrown();
+ AddSC_sholazar_basin();
+ AddSC_storm_peaks();
+ AddSC_wintergrasp();
+ AddSC_zuldrak();
+ AddSC_crystalsong_forest();
+ AddSC_isle_of_conquest();
+}
diff --git a/src/server/scripts/OutdoorPvP/CMakeLists.txt b/src/server/scripts/OutdoorPvP/CMakeLists.txt
deleted file mode 100644
index 91ce4ce4186..00000000000
--- a/src/server/scripts/OutdoorPvP/CMakeLists.txt
+++ /dev/null
@@ -1,27 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- OutdoorPvP/OutdoorPvPTF.cpp
- OutdoorPvP/OutdoorPvPSI.cpp
- OutdoorPvP/OutdoorPvPSI.h
- OutdoorPvP/OutdoorPvPZM.cpp
- OutdoorPvP/OutdoorPvPNA.cpp
- OutdoorPvP/OutdoorPvPHP.cpp
- OutdoorPvP/OutdoorPvPTF.h
- OutdoorPvP/OutdoorPvPEP.h
- OutdoorPvP/OutdoorPvPEP.cpp
- OutdoorPvP/OutdoorPvPHP.h
- OutdoorPvP/OutdoorPvPZM.h
- OutdoorPvP/OutdoorPvPNA.h
-)
-
-message(" -> Prepared: Outdoor PVP Zones")
diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPScriptLoader.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPScriptLoader.cpp
new file mode 100644
index 00000000000..ebf29910046
--- /dev/null
+++ b/src/server/scripts/OutdoorPvP/OutdoorPvPScriptLoader.cpp
@@ -0,0 +1,36 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_outdoorpvp_ep();
+void AddSC_outdoorpvp_hp();
+void AddSC_outdoorpvp_na();
+void AddSC_outdoorpvp_si();
+void AddSC_outdoorpvp_tf();
+void AddSC_outdoorpvp_zm();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddOutdoorPvPScripts()
+{
+ AddSC_outdoorpvp_ep();
+ AddSC_outdoorpvp_hp();
+ AddSC_outdoorpvp_na();
+ AddSC_outdoorpvp_si();
+ AddSC_outdoorpvp_tf();
+ AddSC_outdoorpvp_zm();
+}
diff --git a/src/server/scripts/Outland/CMakeLists.txt b/src/server/scripts/Outland/CMakeLists.txt
deleted file mode 100644
index 55b0452fb0b..00000000000
--- a/src/server/scripts/Outland/CMakeLists.txt
+++ /dev/null
@@ -1,128 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- Outland/zone_nagrand.cpp
- Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h
- Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp
- Outland/HellfireCitadel/MagtheridonsLair/boss_magtheridon.cpp
- Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp
- Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp
- Outland/HellfireCitadel/HellfireRamparts/boss_watchkeeper_gargolmar.cpp
- Outland/HellfireCitadel/HellfireRamparts/boss_vazruden_the_herald.cpp
- Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h
- Outland/HellfireCitadel/BloodFurnace/boss_the_maker.cpp
- Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp
- Outland/HellfireCitadel/BloodFurnace/blood_furnace.h
- Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp
- Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp
- Outland/HellfireCitadel/ShatteredHalls/shattered_halls.h
- Outland/HellfireCitadel/ShatteredHalls/boss_warchief_kargath_bladefist.cpp
- Outland/HellfireCitadel/ShatteredHalls/boss_nethekurse.cpp
- Outland/HellfireCitadel/ShatteredHalls/shattered_halls.cpp
- Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp
- Outland/HellfireCitadel/ShatteredHalls/boss_warbringer_omrogg.cpp
- Outland/CoilfangReservoir/SteamVault/boss_mekgineer_steamrigger.cpp
- Outland/CoilfangReservoir/SteamVault/instance_steam_vault.cpp
- Outland/CoilfangReservoir/SteamVault/boss_hydromancer_thespia.cpp
- Outland/CoilfangReservoir/SteamVault/boss_warlord_kalithresh.cpp
- Outland/CoilfangReservoir/SteamVault/steam_vault.h
- Outland/CoilfangReservoir/SerpentShrine/boss_hydross_the_unstable.cpp
- Outland/CoilfangReservoir/SerpentShrine/boss_fathomlord_karathress.cpp
- Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp
- Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h
- Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp
- Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp
- Outland/CoilfangReservoir/SerpentShrine/boss_lurker_below.cpp
- Outland/CoilfangReservoir/SerpentShrine/boss_morogrim_tidewalker.cpp
- Outland/CoilfangReservoir/TheSlavePens/instance_the_slave_pens.cpp
- Outland/CoilfangReservoir/TheSlavePens/the_slave_pens.h
- Outland/CoilfangReservoir/TheSlavePens/boss_mennu_the_betrayer.cpp
- Outland/CoilfangReservoir/TheSlavePens/boss_rokmar_the_crackler.cpp
- Outland/CoilfangReservoir/TheSlavePens/boss_quagmirran.cpp
- Outland/CoilfangReservoir/TheUnderbog/instance_the_underbog.cpp
- Outland/CoilfangReservoir/TheUnderbog/boss_hungarfen.cpp
- Outland/CoilfangReservoir/TheUnderbog/boss_the_black_stalker.cpp
- Outland/zone_shattrath_city.cpp
- Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp
- Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp
- Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp
- Outland/TempestKeep/Mechanar/mechanar.h
- Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp
- Outland/TempestKeep/Mechanar/instance_mechanar.cpp
- Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp
- Outland/TempestKeep/Eye/the_eye.h
- Outland/TempestKeep/Eye/instance_the_eye.cpp
- Outland/TempestKeep/Eye/boss_void_reaver.cpp
- Outland/TempestKeep/Eye/boss_astromancer.cpp
- Outland/TempestKeep/Eye/boss_alar.cpp
- Outland/TempestKeep/Eye/boss_kaelthas.cpp
- Outland/TempestKeep/Eye/the_eye.cpp
- Outland/TempestKeep/botanica/the_botanica.h
- Outland/TempestKeep/botanica/instance_the_botanica.cpp
- Outland/TempestKeep/botanica/boss_commander_sarannis.cpp
- Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp
- Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp
- Outland/TempestKeep/botanica/boss_warp_splinter.cpp
- Outland/TempestKeep/botanica/boss_laj.cpp
- Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp
- Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp
- Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp
- Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp
- Outland/TempestKeep/arcatraz/instance_arcatraz.cpp
- Outland/TempestKeep/arcatraz/arcatraz.h
- Outland/TempestKeep/arcatraz/arcatraz.cpp
- Outland/Auchindoun/AuchenaiCrypts/boss_shirrak_the_dead_watcher.cpp
- Outland/Auchindoun/AuchenaiCrypts/boss_exarch_maladaar.cpp
- Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp
- Outland/Auchindoun/AuchenaiCrypts/auchenai_crypts.h
- Outland/Auchindoun/ManaTombs/boss_pandemonius.cpp
- Outland/Auchindoun/ManaTombs/boss_nexusprince_shaffar.cpp
- Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp
- Outland/Auchindoun/ManaTombs/mana_tombs.h
- Outland/Auchindoun/SethekkHalls/boss_darkweaver_syth.cpp
- Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp
- Outland/Auchindoun/SethekkHalls/boss_anzu.cpp
- Outland/Auchindoun/SethekkHalls/instance_sethekk_halls.cpp
- Outland/Auchindoun/SethekkHalls/sethekk_halls.h
- Outland/Auchindoun/ShadowLabyrinth/boss_ambassador_hellmaw.cpp
- Outland/Auchindoun/ShadowLabyrinth/boss_blackheart_the_inciter.cpp
- Outland/Auchindoun/ShadowLabyrinth/boss_grandmaster_vorpil.cpp
- Outland/Auchindoun/ShadowLabyrinth/boss_murmur.cpp
- Outland/Auchindoun/ShadowLabyrinth/instance_shadow_labyrinth.cpp
- Outland/Auchindoun/ShadowLabyrinth/shadow_labyrinth.h
- Outland/boss_doomwalker.cpp
- Outland/zone_terokkar_forest.cpp
- Outland/zone_hellfire_peninsula.cpp
- Outland/boss_doomlord_kazzak.cpp
- Outland/BlackTemple/boss_teron_gorefiend.cpp
- Outland/BlackTemple/black_temple.h
- Outland/BlackTemple/illidari_council.cpp
- Outland/BlackTemple/boss_shade_of_akama.cpp
- Outland/BlackTemple/boss_supremus.cpp
- Outland/BlackTemple/black_temple.cpp
- Outland/BlackTemple/boss_mother_shahraz.cpp
- Outland/BlackTemple/instance_black_temple.cpp
- Outland/BlackTemple/boss_reliquary_of_souls.cpp
- Outland/BlackTemple/boss_warlord_najentus.cpp
- Outland/BlackTemple/boss_gurtogg_bloodboil.cpp
- Outland/BlackTemple/boss_illidan.cpp
- Outland/zone_shadowmoon_valley.cpp
- Outland/zone_blades_edge_mountains.cpp
- Outland/GruulsLair/boss_high_king_maulgar.cpp
- Outland/GruulsLair/boss_gruul.cpp
- Outland/GruulsLair/gruuls_lair.h
- Outland/GruulsLair/instance_gruuls_lair.cpp
- Outland/zone_netherstorm.cpp
- Outland/zone_zangarmarsh.cpp
-)
-
-message(" -> Prepared: Outland")
diff --git a/src/server/scripts/Outland/outland_script_loader.cpp b/src/server/scripts/Outland/outland_script_loader.cpp
new file mode 100644
index 00000000000..91ba4e5689f
--- /dev/null
+++ b/src/server/scripts/Outland/outland_script_loader.cpp
@@ -0,0 +1,256 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+// Auchindoun - Auchenai Crypts
+void AddSC_boss_shirrak_the_dead_watcher();
+void AddSC_boss_exarch_maladaar();
+void AddSC_instance_auchenai_crypts();
+
+// Auchindoun - Mana Tombs
+void AddSC_boss_pandemonius();
+void AddSC_boss_nexusprince_shaffar();
+void AddSC_instance_mana_tombs();
+
+// Auchindoun - Sekketh Halls
+void AddSC_boss_darkweaver_syth();
+void AddSC_boss_talon_king_ikiss();
+void AddSC_boss_anzu();
+void AddSC_instance_sethekk_halls();
+
+// Auchindoun - Shadow Labyrinth
+void AddSC_boss_ambassador_hellmaw();
+void AddSC_boss_blackheart_the_inciter();
+void AddSC_boss_grandmaster_vorpil();
+void AddSC_boss_murmur();
+void AddSC_instance_shadow_labyrinth();
+
+// Black Temple
+void AddSC_black_temple();
+void AddSC_boss_illidan();
+void AddSC_boss_shade_of_akama();
+void AddSC_boss_supremus();
+void AddSC_boss_gurtogg_bloodboil();
+void AddSC_boss_mother_shahraz();
+void AddSC_boss_reliquary_of_souls();
+void AddSC_boss_teron_gorefiend();
+void AddSC_boss_najentus();
+void AddSC_boss_illidari_council();
+void AddSC_instance_black_temple();
+
+// Coilfang Reservoir - Serpent Shrine Cavern
+void AddSC_boss_fathomlord_karathress();
+void AddSC_boss_hydross_the_unstable();
+void AddSC_boss_lady_vashj();
+void AddSC_boss_leotheras_the_blind();
+void AddSC_boss_morogrim_tidewalker();
+void AddSC_instance_serpentshrine_cavern();
+void AddSC_boss_the_lurker_below();
+
+// Coilfang Reservoir - The Steam Vault
+void AddSC_boss_hydromancer_thespia();
+void AddSC_boss_mekgineer_steamrigger();
+void AddSC_boss_warlord_kalithresh();
+void AddSC_instance_steam_vault();
+
+// Coilfang Reservoir - The Slave Pens
+void AddSC_instance_the_slave_pens();
+void AddSC_boss_mennu_the_betrayer();
+void AddSC_boss_rokmar_the_crackler();
+void AddSC_boss_quagmirran();
+
+// Coilfang Reservoir - The Underbog
+void AddSC_instance_the_underbog();
+void AddSC_boss_hungarfen();
+void AddSC_boss_the_black_stalker();
+
+// Gruul's Lair
+void AddSC_boss_gruul();
+void AddSC_boss_high_king_maulgar();
+void AddSC_instance_gruuls_lair();
+void AddSC_boss_broggok(); //HC Blood Furnace
+void AddSC_boss_kelidan_the_breaker();
+void AddSC_boss_the_maker();
+void AddSC_instance_blood_furnace();
+void AddSC_boss_magtheridon(); //HC Magtheridon's Lair
+void AddSC_instance_magtheridons_lair();
+void AddSC_boss_grand_warlock_nethekurse(); //HC Shattered Halls
+void AddSC_boss_warbringer_omrogg();
+void AddSC_boss_warchief_kargath_bladefist();
+void AddSC_shattered_halls();
+void AddSC_instance_shattered_halls();
+void AddSC_boss_watchkeeper_gargolmar(); //HC Ramparts
+void AddSC_boss_omor_the_unscarred();
+void AddSC_boss_vazruden_the_herald();
+void AddSC_instance_ramparts();
+void AddSC_arcatraz(); //TK Arcatraz
+void AddSC_boss_zereketh_the_unbound();
+void AddSC_boss_dalliah_the_doomsayer();
+void AddSC_boss_wrath_scryer_soccothrates();
+void AddSC_boss_harbinger_skyriss();
+void AddSC_instance_arcatraz();
+void AddSC_boss_high_botanist_freywinn(); //TK Botanica
+void AddSC_boss_laj();
+void AddSC_boss_warp_splinter();
+void AddSC_boss_thorngrin_the_tender();
+void AddSC_boss_commander_sarannis();
+void AddSC_instance_the_botanica();
+void AddSC_boss_alar(); //TK The Eye
+void AddSC_boss_kaelthas();
+void AddSC_boss_void_reaver();
+void AddSC_boss_high_astromancer_solarian();
+void AddSC_instance_the_eye();
+void AddSC_the_eye();
+void AddSC_boss_gatewatcher_iron_hand(); //TK The Mechanar
+void AddSC_boss_gatewatcher_gyrokill();
+void AddSC_boss_nethermancer_sepethrea();
+void AddSC_boss_pathaleon_the_calculator();
+void AddSC_boss_mechano_lord_capacitus();
+void AddSC_instance_mechanar();
+
+void AddSC_blades_edge_mountains();
+void AddSC_boss_doomlordkazzak();
+void AddSC_boss_doomwalker();
+void AddSC_hellfire_peninsula();
+void AddSC_nagrand();
+void AddSC_netherstorm();
+void AddSC_shadowmoon_valley();
+void AddSC_shattrath_city();
+void AddSC_terokkar_forest();
+void AddSC_zangarmarsh();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddOutlandScripts()
+{
+ // Auchindoun - Auchenai Crypts
+ AddSC_boss_shirrak_the_dead_watcher();
+ AddSC_boss_exarch_maladaar();
+ AddSC_instance_auchenai_crypts();
+
+ // Auchindoun - Mana Tombs
+ AddSC_boss_pandemonius();
+ AddSC_boss_nexusprince_shaffar();
+ AddSC_instance_mana_tombs();
+
+ // Auchindoun - Sekketh Halls
+ AddSC_boss_darkweaver_syth();
+ AddSC_boss_talon_king_ikiss();
+ AddSC_boss_anzu();
+ AddSC_instance_sethekk_halls();
+
+ // Auchindoun - Shadow Labyrinth
+ AddSC_boss_ambassador_hellmaw();
+ AddSC_boss_blackheart_the_inciter();
+ AddSC_boss_grandmaster_vorpil();
+ AddSC_boss_murmur();
+ AddSC_instance_shadow_labyrinth();
+
+ // Black Temple
+ AddSC_black_temple();
+ AddSC_boss_illidan();
+ AddSC_boss_shade_of_akama();
+ AddSC_boss_supremus();
+ AddSC_boss_gurtogg_bloodboil();
+ AddSC_boss_mother_shahraz();
+ AddSC_boss_reliquary_of_souls();
+ AddSC_boss_teron_gorefiend();
+ AddSC_boss_najentus();
+ AddSC_boss_illidari_council();
+ AddSC_instance_black_temple();
+
+ // Coilfang Reservoir - Serpent Shrine Cavern
+ AddSC_boss_fathomlord_karathress();
+ AddSC_boss_hydross_the_unstable();
+ AddSC_boss_lady_vashj();
+ AddSC_boss_leotheras_the_blind();
+ AddSC_boss_morogrim_tidewalker();
+ AddSC_instance_serpentshrine_cavern();
+ AddSC_boss_the_lurker_below();
+
+ // Coilfang Reservoir - The Steam Vault
+ AddSC_instance_steam_vault();
+ AddSC_boss_hydromancer_thespia();
+ AddSC_boss_mekgineer_steamrigger();
+ AddSC_boss_warlord_kalithresh();
+
+ // Coilfang Reservoir - The Slave Pens
+ AddSC_instance_the_slave_pens();
+ AddSC_boss_mennu_the_betrayer();
+ AddSC_boss_rokmar_the_crackler();
+ AddSC_boss_quagmirran();
+
+ // Coilfang Reservoir - The Underbog
+ AddSC_instance_the_underbog();
+ AddSC_boss_hungarfen();
+ AddSC_boss_the_black_stalker();
+
+ // Gruul's Lair
+ AddSC_boss_gruul();
+ AddSC_boss_high_king_maulgar();
+ AddSC_instance_gruuls_lair();
+ AddSC_boss_broggok(); //HC Blood Furnace
+ AddSC_boss_kelidan_the_breaker();
+ AddSC_boss_the_maker();
+ AddSC_instance_blood_furnace();
+ AddSC_boss_magtheridon(); //HC Magtheridon's Lair
+ AddSC_instance_magtheridons_lair();
+ AddSC_boss_grand_warlock_nethekurse(); //HC Shattered Halls
+ AddSC_boss_warbringer_omrogg();
+ AddSC_boss_warchief_kargath_bladefist();
+ AddSC_shattered_halls();
+ AddSC_instance_shattered_halls();
+ AddSC_boss_watchkeeper_gargolmar(); //HC Ramparts
+ AddSC_boss_omor_the_unscarred();
+ AddSC_boss_vazruden_the_herald();
+ AddSC_instance_ramparts();
+ AddSC_arcatraz(); //TK Arcatraz
+ AddSC_boss_zereketh_the_unbound();
+ AddSC_boss_dalliah_the_doomsayer();
+ AddSC_boss_wrath_scryer_soccothrates();
+ AddSC_boss_harbinger_skyriss();
+ AddSC_instance_arcatraz();
+ AddSC_boss_high_botanist_freywinn(); //TK Botanica
+ AddSC_boss_laj();
+ AddSC_boss_warp_splinter();
+ AddSC_boss_thorngrin_the_tender();
+ AddSC_boss_commander_sarannis();
+ AddSC_instance_the_botanica();
+ AddSC_boss_alar(); //TK The Eye
+ AddSC_boss_kaelthas();
+ AddSC_boss_void_reaver();
+ AddSC_boss_high_astromancer_solarian();
+ AddSC_instance_the_eye();
+ AddSC_the_eye();
+ AddSC_boss_gatewatcher_iron_hand(); //TK The Mechanar
+ AddSC_boss_gatewatcher_gyrokill();
+ AddSC_boss_nethermancer_sepethrea();
+ AddSC_boss_pathaleon_the_calculator();
+ AddSC_boss_mechano_lord_capacitus();
+ AddSC_instance_mechanar();
+
+ AddSC_blades_edge_mountains();
+ AddSC_boss_doomlordkazzak();
+ AddSC_boss_doomwalker();
+ AddSC_hellfire_peninsula();
+ AddSC_nagrand();
+ AddSC_netherstorm();
+ AddSC_shadowmoon_valley();
+ AddSC_shattrath_city();
+ AddSC_terokkar_forest();
+ AddSC_zangarmarsh();
+}
diff --git a/src/server/scripts/Outland/zone_terokkar_forest.cpp b/src/server/scripts/Outland/zone_terokkar_forest.cpp
index 06a8af947b7..04ec1e4dc07 100644
--- a/src/server/scripts/Outland/zone_terokkar_forest.cpp
+++ b/src/server/scripts/Outland/zone_terokkar_forest.cpp
@@ -27,7 +27,6 @@ EndScriptData */
npc_unkor_the_ruthless
npc_infested_root_walker
npc_rotting_forest_rager
-npc_netherweb_victim
npc_floon
npc_isla_starmane
npc_slim
@@ -287,65 +286,6 @@ public:
};
/*######
-## npc_netherweb_victim
-######*/
-
-enum NetherwebVictim
-{
- QUEST_TARGET = 22459
- //SPELL_FREE_WEBBED = 38950
-};
-
-const uint32 netherwebVictims[6] =
-{
- 18470, 16805, 21242, 18452, 22482, 21285
-};
-
-class npc_netherweb_victim : public CreatureScript
-{
-public:
- npc_netherweb_victim() : CreatureScript("npc_netherweb_victim") { }
-
- CreatureAI* GetAI(Creature* creature) const override
- {
- return new npc_netherweb_victimAI(creature);
- }
-
- struct npc_netherweb_victimAI : public ScriptedAI
- {
- npc_netherweb_victimAI(Creature* creature) : ScriptedAI(creature) { }
-
- void Reset() override { }
- void EnterCombat(Unit* /*who*/) override { }
- void MoveInLineOfSight(Unit* /*who*/) override { }
-
-
- void JustDied(Unit* killer) override
- {
- Player* player = killer->ToPlayer();
- if (!player)
- return;
-
- if (player->GetQuestStatus(10873) == QUEST_STATUS_INCOMPLETE)
- {
- if (rand32() % 100 < 25)
- {
- me->SummonCreature(QUEST_TARGET, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 60000);
- player->KilledMonsterCredit(QUEST_TARGET);
- }
- else
- me->SummonCreature(netherwebVictims[rand32() % 6], 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 60000);
-
- if (rand32() % 100 < 75)
- me->SummonCreature(netherwebVictims[rand32() % 6], 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 60000);
-
- me->SummonCreature(netherwebVictims[rand32() % 6], 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 60000);
- }
- }
- };
-};
-
-/*######
## npc_floon
######*/
@@ -719,7 +659,6 @@ void AddSC_terokkar_forest()
new npc_unkor_the_ruthless();
new npc_infested_root_walker();
new npc_rotting_forest_rager();
- new npc_netherweb_victim();
new npc_floon();
new npc_isla_starmane();
new go_skull_pile();
diff --git a/src/server/scripts/Pet/CMakeLists.txt b/src/server/scripts/Pet/CMakeLists.txt
deleted file mode 100644
index 9ca268a9a3f..00000000000
--- a/src/server/scripts/Pet/CMakeLists.txt
+++ /dev/null
@@ -1,21 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- Pet/pet_dk.cpp
- Pet/pet_generic.cpp
- Pet/pet_hunter.cpp
- Pet/pet_mage.cpp
- Pet/pet_priest.cpp
- Pet/pet_shaman.cpp
-)
-
-message(" -> Prepared: Pet")
diff --git a/src/server/scripts/Pet/pet_script_loader.cpp b/src/server/scripts/Pet/pet_script_loader.cpp
new file mode 100644
index 00000000000..c3c0079fd46
--- /dev/null
+++ b/src/server/scripts/Pet/pet_script_loader.cpp
@@ -0,0 +1,36 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_deathknight_pet_scripts();
+void AddSC_generic_pet_scripts();
+void AddSC_hunter_pet_scripts();
+void AddSC_mage_pet_scripts();
+void AddSC_priest_pet_scripts();
+void AddSC_shaman_pet_scripts();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddPetScripts()
+{
+ AddSC_deathknight_pet_scripts();
+ AddSC_generic_pet_scripts();
+ AddSC_hunter_pet_scripts();
+ AddSC_mage_pet_scripts();
+ AddSC_priest_pet_scripts();
+ AddSC_shaman_pet_scripts();
+}
diff --git a/src/server/scripts/Spells/CMakeLists.txt b/src/server/scripts/Spells/CMakeLists.txt
deleted file mode 100644
index 7434d98cf49..00000000000
--- a/src/server/scripts/Spells/CMakeLists.txt
+++ /dev/null
@@ -1,30 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- Spells/spell_shaman.cpp
- Spells/spell_hunter.cpp
- Spells/spell_rogue.cpp
- Spells/spell_druid.cpp
- Spells/spell_dk.cpp
- Spells/spell_quest.cpp
- Spells/spell_warrior.cpp
- Spells/spell_generic.cpp
- Spells/spell_warlock.cpp
- Spells/spell_priest.cpp
- Spells/spell_mage.cpp
- Spells/spell_paladin.cpp
- Spells/spell_item.cpp
- Spells/spell_holiday.cpp
- Spells/spell_pet.cpp
-)
-
-message(" -> Prepared: Spells")
diff --git a/src/server/scripts/Spells/spell_script_loader.cpp b/src/server/scripts/Spells/spell_script_loader.cpp
new file mode 100644
index 00000000000..b2c8d6663fa
--- /dev/null
+++ b/src/server/scripts/Spells/spell_script_loader.cpp
@@ -0,0 +1,52 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+// This is where scripts' loading functions should be declared:
+void AddSC_deathknight_spell_scripts();
+void AddSC_druid_spell_scripts();
+void AddSC_generic_spell_scripts();
+void AddSC_hunter_spell_scripts();
+void AddSC_mage_spell_scripts();
+void AddSC_paladin_spell_scripts();
+void AddSC_priest_spell_scripts();
+void AddSC_rogue_spell_scripts();
+void AddSC_shaman_spell_scripts();
+void AddSC_warlock_spell_scripts();
+void AddSC_warrior_spell_scripts();
+void AddSC_quest_spell_scripts();
+void AddSC_item_spell_scripts();
+void AddSC_holiday_spell_scripts();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddSpellsScripts()
+{
+ AddSC_deathknight_spell_scripts();
+ AddSC_druid_spell_scripts();
+ AddSC_generic_spell_scripts();
+ AddSC_hunter_spell_scripts();
+ AddSC_mage_spell_scripts();
+ AddSC_paladin_spell_scripts();
+ AddSC_priest_spell_scripts();
+ AddSC_rogue_spell_scripts();
+ AddSC_shaman_spell_scripts();
+ AddSC_warlock_spell_scripts();
+ AddSC_warrior_spell_scripts();
+ AddSC_quest_spell_scripts();
+ AddSC_item_spell_scripts();
+ AddSC_holiday_spell_scripts();
+}
diff --git a/src/server/scripts/World/CMakeLists.txt b/src/server/scripts/World/CMakeLists.txt
deleted file mode 100644
index 17b3f2d8492..00000000000
--- a/src/server/scripts/World/CMakeLists.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
-#
-# This file is free software; as a special exception the author gives
-# unlimited permission to copy and/or distribute it, with or without
-# modifications, as long as this notice is preserved.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-file(GLOB_RECURSE sources_World World/*.cpp World/*.h)
-
-set(scripts_STAT_SRCS
- ${scripts_STAT_SRCS}
- ${sources_World}
-)
-
-message(" -> Prepared: World")
diff --git a/src/server/scripts/World/world_script_loader.cpp b/src/server/scripts/World/world_script_loader.cpp
new file mode 100644
index 00000000000..0167024799f
--- /dev/null
+++ b/src/server/scripts/World/world_script_loader.cpp
@@ -0,0 +1,59 @@
+/*
+ * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
+ *
+ * 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/>.
+ */
+
+#include "World.h"
+
+// This is where scripts' loading functions should be declared:
+// world
+void AddSC_areatrigger_scripts();
+void AddSC_emerald_dragons();
+void AddSC_generic_creature();
+void AddSC_go_scripts();
+void AddSC_guards();
+void AddSC_item_scripts();
+void AddSC_npc_professions();
+void AddSC_npc_innkeeper();
+void AddSC_npcs_special();
+void AddSC_achievement_scripts();
+void AddSC_action_ip_logger();
+void AddSC_duel_reset();
+// player
+void AddSC_chat_log();
+void AddSC_action_ip_logger();
+
+// The name of this function should match:
+// void Add${NameOfDirectory}Scripts()
+void AddWorldScripts()
+{
+ AddSC_areatrigger_scripts();
+ AddSC_emerald_dragons();
+ AddSC_generic_creature();
+ AddSC_go_scripts();
+ AddSC_guards();
+ AddSC_item_scripts();
+ AddSC_npc_professions();
+ AddSC_npc_innkeeper();
+ AddSC_npcs_special();
+ AddSC_achievement_scripts();
+ AddSC_chat_log(); // location: scripts\World\chat_log.cpp
+
+ // FIXME: This should be moved in a script validation hook.
+ // To avoid duplicate code, we check once /*ONLY*/ if logging is permitted or not.
+ if (sWorld->getBoolConfig(CONFIG_IP_BASED_ACTION_LOGGING))
+ AddSC_action_ip_logger(); // location: scripts\World\action_ip_logger.cpp
+ AddSC_duel_reset();
+}
diff --git a/src/server/shared/Networking/AsyncAcceptor.h b/src/server/shared/Networking/AsyncAcceptor.h
index 260e1c8ea11..0f3fd9a145b 100644
--- a/src/server/shared/Networking/AsyncAcceptor.h
+++ b/src/server/shared/Networking/AsyncAcceptor.h
@@ -20,34 +20,39 @@
#include "Log.h"
#include <boost/asio.hpp>
+#include <functional>
using boost::asio::ip::tcp;
class AsyncAcceptor
{
public:
- typedef void(*ManagerAcceptHandler)(tcp::socket&& newSocket);
+ typedef void(*AcceptCallback)(tcp::socket&& newSocket, uint32 threadIndex);
AsyncAcceptor(boost::asio::io_service& ioService, std::string const& bindIp, uint16 port) :
_acceptor(ioService, tcp::endpoint(boost::asio::ip::address::from_string(bindIp), port)),
- _socket(ioService)
+ _socket(ioService), _closed(false), _socketFactory(std::bind(&AsyncAcceptor::DefeaultSocketFactory, this))
{
}
- template <class T>
+ template<class T>
void AsyncAccept();
- void AsyncAcceptManaged(ManagerAcceptHandler mgrHandler)
+ template<AcceptCallback acceptCallback>
+ void AsyncAcceptWithCallback()
{
- _acceptor.async_accept(_socket, [this, mgrHandler](boost::system::error_code error)
+ tcp::socket* socket;
+ uint32 threadIndex;
+ std::tie(socket, threadIndex) = _socketFactory();
+ _acceptor.async_accept(*socket, [this, socket, threadIndex](boost::system::error_code error)
{
if (!error)
{
try
{
- _socket.non_blocking(true);
+ socket->non_blocking(true);
- mgrHandler(std::move(_socket));
+ acceptCallback(std::move(*socket), threadIndex);
}
catch (boost::system::system_error const& err)
{
@@ -55,13 +60,29 @@ public:
}
}
- AsyncAcceptManaged(mgrHandler);
+ if (!_closed)
+ this->AsyncAcceptWithCallback<acceptCallback>();
});
}
+ void Close()
+ {
+ if (_closed.exchange(true))
+ return;
+
+ boost::system::error_code err;
+ _acceptor.close(err);
+ }
+
+ void SetSocketFactory(std::function<std::pair<tcp::socket*, uint32>()> func) { _socketFactory = func; }
+
private:
+ std::pair<tcp::socket*, uint32> DefeaultSocketFactory() { return std::make_pair(&_socket, 0); }
+
tcp::acceptor _acceptor;
tcp::socket _socket;
+ std::atomic<bool> _closed;
+ std::function<std::pair<tcp::socket*, uint32>()> _socketFactory;
};
template<class T>
@@ -83,7 +104,8 @@ void AsyncAcceptor::AsyncAccept()
}
// lets slap some more this-> on this so we can fix this bug with gcc 4.7.2 throwing internals in yo face
- this->AsyncAccept<T>();
+ if (!_closed)
+ this->AsyncAccept<T>();
});
}
diff --git a/src/server/shared/Networking/MessageBuffer.h b/src/server/shared/Networking/MessageBuffer.h
index 189a56f18b6..d68bee181b1 100644
--- a/src/server/shared/Networking/MessageBuffer.h
+++ b/src/server/shared/Networking/MessageBuffer.h
@@ -105,7 +105,7 @@ public:
return std::move(_storage);
}
- MessageBuffer& operator=(MessageBuffer& right)
+ MessageBuffer& operator=(MessageBuffer const& right)
{
if (this != &right)
{
diff --git a/src/server/shared/Networking/NetworkThread.h b/src/server/shared/Networking/NetworkThread.h
index ac216838bce..be0e9f10176 100644
--- a/src/server/shared/Networking/NetworkThread.h
+++ b/src/server/shared/Networking/NetworkThread.h
@@ -22,6 +22,8 @@
#include "Errors.h"
#include "Log.h"
#include "Timer.h"
+#include <boost/asio/ip/tcp.hpp>
+#include <boost/asio/deadline_timer.hpp>
#include <atomic>
#include <chrono>
#include <memory>
@@ -29,11 +31,14 @@
#include <set>
#include <thread>
+using boost::asio::ip::tcp;
+
template<class SocketType>
class NetworkThread
{
public:
- NetworkThread() : _connections(0), _stopped(false), _thread(nullptr)
+ NetworkThread() : _connections(0), _stopped(false), _thread(nullptr),
+ _acceptSocket(_io_service), _updateTimer(_io_service)
{
}
@@ -50,6 +55,7 @@ public:
void Stop()
{
_stopped = true;
+ _io_service.stop();
}
bool Start()
@@ -80,10 +86,12 @@ public:
std::lock_guard<std::mutex> lock(_newSocketsLock);
++_connections;
- _newSockets.insert(sock);
+ _newSockets.push_back(sock);
SocketAdded(sock);
}
+ tcp::socket* GetSocketForAccept() { return &_acceptSocket; }
+
protected:
virtual void SocketAdded(std::shared_ptr<SocketType> /*sock*/) { }
virtual void SocketRemoved(std::shared_ptr<SocketType> /*sock*/) { }
@@ -95,16 +103,15 @@ protected:
if (_newSockets.empty())
return;
- for (typename SocketSet::const_iterator i = _newSockets.begin(); i != _newSockets.end(); ++i)
+ for (std::shared_ptr<SocketType> sock : _newSockets)
{
- if (!(*i)->IsOpen())
+ if (!sock->IsOpen())
{
- SocketRemoved(*i);
-
+ SocketRemoved(sock);
--_connections;
}
else
- _Sockets.insert(*i);
+ _sockets.push_back(sock);
}
_newSockets.clear();
@@ -114,53 +121,58 @@ protected:
{
TC_LOG_DEBUG("misc", "Network Thread Starting");
- typename SocketSet::iterator i, t;
+ _updateTimer.expires_from_now(boost::posix_time::milliseconds(10));
+ _updateTimer.async_wait(std::bind(&NetworkThread<SocketType>::Update, this));
+ _io_service.run();
- uint32 sleepTime = 10;
- uint32 tickStart = 0, diff = 0;
- while (!_stopped)
- {
- std::this_thread::sleep_for(std::chrono::milliseconds(sleepTime));
+ TC_LOG_DEBUG("misc", "Network Thread exits");
+ _newSockets.clear();
+ _sockets.clear();
+ }
+
+ void Update()
+ {
+ if (_stopped)
+ return;
- tickStart = getMSTime();
+ _updateTimer.expires_from_now(boost::posix_time::milliseconds(10));
+ _updateTimer.async_wait(std::bind(&NetworkThread<SocketType>::Update, this));
- AddNewSockets();
+ AddNewSockets();
- for (i = _Sockets.begin(); i != _Sockets.end();)
+ _sockets.erase(std::remove_if(_sockets.begin(), _sockets.end(), [this](std::shared_ptr<SocketType> sock)
+ {
+ if (!sock->Update())
{
- if (!(*i)->Update())
- {
- if ((*i)->IsOpen())
- (*i)->CloseSocket();
-
- SocketRemoved(*i);
-
- --_connections;
- _Sockets.erase(i++);
- }
- else
- ++i;
- }
+ if (sock->IsOpen())
+ sock->CloseSocket();
- diff = GetMSTimeDiffToNow(tickStart);
- sleepTime = diff > 10 ? 0 : 10 - diff;
- }
+ this->SocketRemoved(sock);
- TC_LOG_DEBUG("misc", "Network Thread exits");
+ --this->_connections;
+ return true;
+ }
+
+ return false;
+ }), _sockets.end());
}
private:
- typedef std::set<std::shared_ptr<SocketType> > SocketSet;
+ typedef std::vector<std::shared_ptr<SocketType>> SocketContainer;
std::atomic<int32> _connections;
std::atomic<bool> _stopped;
std::thread* _thread;
- SocketSet _Sockets;
+ SocketContainer _sockets;
std::mutex _newSocketsLock;
- SocketSet _newSockets;
+ SocketContainer _newSockets;
+
+ boost::asio::io_service _io_service;
+ tcp::socket _acceptSocket;
+ boost::asio::deadline_timer _updateTimer;
};
#endif // NetworkThread_h__
diff --git a/src/server/shared/Networking/Socket.h b/src/server/shared/Networking/Socket.h
index a2f57b5029e..d1ba7f49aa4 100644
--- a/src/server/shared/Networking/Socket.h
+++ b/src/server/shared/Networking/Socket.h
@@ -21,15 +21,11 @@
#include "MessageBuffer.h"
#include "Log.h"
#include <atomic>
-#include <vector>
-#include <mutex>
#include <queue>
#include <memory>
#include <functional>
#include <type_traits>
#include <boost/asio/ip/tcp.hpp>
-#include <boost/asio/write.hpp>
-#include <boost/asio/read.hpp>
using boost::asio::ip::tcp;
@@ -63,14 +59,10 @@ public:
return false;
#ifndef TC_SOCKET_USE_IOCP
- std::unique_lock<std::mutex> guard(_writeLock);
- if (!guard)
+ if (_isWritingAsync || _writeQueue.empty())
return true;
- if (_isWritingAsync || (!_writeBuffer.GetActiveSize() && _writeQueue.empty()))
- return true;
-
- for (; WriteHandler(guard);)
+ for (; HandleQueue();)
;
#endif
@@ -98,14 +90,12 @@ public:
std::bind(&Socket<T>::ReadHandlerInternal, this->shared_from_this(), std::placeholders::_1, std::placeholders::_2));
}
- void QueuePacket(MessageBuffer&& buffer, std::unique_lock<std::mutex>& guard)
+ void QueuePacket(MessageBuffer&& buffer)
{
_writeQueue.push(std::move(buffer));
#ifdef TC_SOCKET_USE_IOCP
- AsyncProcessQueue(guard);
-#else
- (void)guard;
+ AsyncProcessQueue();
#endif
}
@@ -135,7 +125,7 @@ protected:
virtual void ReadHandler() = 0;
- bool AsyncProcessQueue(std::unique_lock<std::mutex>&)
+ bool AsyncProcessQueue()
{
if (_isWritingAsync)
return false;
@@ -154,14 +144,6 @@ protected:
return false;
}
- std::mutex _writeLock;
- std::queue<MessageBuffer> _writeQueue;
-#ifndef TC_SOCKET_USE_IOCP
- MessageBuffer _writeBuffer;
-#endif
-
- boost::asio::io_service& io_service() { return _socket.get_io_service(); }
-
private:
void ReadHandlerInternal(boost::system::error_code error, size_t transferredBytes)
{
@@ -181,15 +163,13 @@ private:
{
if (!error)
{
- std::unique_lock<std::mutex> deleteGuard(_writeLock);
-
_isWritingAsync = false;
_writeQueue.front().ReadCompleted(transferedBytes);
if (!_writeQueue.front().GetActiveSize())
_writeQueue.pop();
if (!_writeQueue.empty())
- AsyncProcessQueue(deleteGuard);
+ AsyncProcessQueue();
else if (_closing)
CloseSocket();
}
@@ -201,48 +181,15 @@ private:
void WriteHandlerWrapper(boost::system::error_code /*error*/, std::size_t /*transferedBytes*/)
{
- std::unique_lock<std::mutex> guard(_writeLock);
_isWritingAsync = false;
- WriteHandler(guard);
+ HandleQueue();
}
- bool WriteHandler(std::unique_lock<std::mutex>& guard)
+ bool HandleQueue()
{
if (!IsOpen())
return false;
- std::size_t bytesToSend = _writeBuffer.GetActiveSize();
-
- if (bytesToSend == 0)
- return HandleQueue(guard);
-
- boost::system::error_code error;
- std::size_t bytesWritten = _socket.write_some(boost::asio::buffer(_writeBuffer.GetReadPointer(), bytesToSend), error);
-
- if (error)
- {
- if (error == boost::asio::error::would_block || error == boost::asio::error::try_again)
- return AsyncProcessQueue(guard);
-
- return false;
- }
- else if (bytesWritten == 0)
- return false;
- else if (bytesWritten < bytesToSend)
- {
- _writeBuffer.ReadCompleted(bytesWritten);
- _writeBuffer.Normalize();
- return AsyncProcessQueue(guard);
- }
-
- // now bytesWritten == bytesToSend
- _writeBuffer.Reset();
-
- return HandleQueue(guard);
- }
-
- bool HandleQueue(std::unique_lock<std::mutex>& guard)
- {
if (_writeQueue.empty())
return false;
@@ -256,7 +203,7 @@ private:
if (error)
{
if (error == boost::asio::error::would_block || error == boost::asio::error::try_again)
- return AsyncProcessQueue(guard);
+ return AsyncProcessQueue();
_writeQueue.pop();
return false;
@@ -269,7 +216,7 @@ private:
else if (bytesSent < bytesToSend) // now n > 0
{
queuedMessage.ReadCompleted(bytesSent);
- return AsyncProcessQueue(guard);
+ return AsyncProcessQueue();
}
_writeQueue.pop();
@@ -284,6 +231,7 @@ private:
uint16 _remotePort;
MessageBuffer _readBuffer;
+ std::queue<MessageBuffer> _writeQueue;
std::atomic<bool> _closed;
std::atomic<bool> _closing;
diff --git a/src/server/shared/Networking/SocketMgr.h b/src/server/shared/Networking/SocketMgr.h
index ce5bc2d8fc2..b14aac4ca47 100644
--- a/src/server/shared/Networking/SocketMgr.h
+++ b/src/server/shared/Networking/SocketMgr.h
@@ -33,7 +33,7 @@ class SocketMgr
public:
virtual ~SocketMgr()
{
- delete[] _threads;
+ ASSERT(!_threads && !_acceptor && !_threadCount, "StopNetwork must be called prior to SocketMgr destruction");
}
virtual bool StartNetwork(boost::asio::io_service& service, std::string const& bindIp, uint16 port)
@@ -68,11 +68,19 @@ public:
virtual void StopNetwork()
{
+ _acceptor->Close();
+
if (_threadCount != 0)
for (int32 i = 0; i < _threadCount; ++i)
_threads[i].Stop();
Wait();
+
+ delete _acceptor;
+ _acceptor = nullptr;
+ delete[] _threads;
+ _threads = nullptr;
+ _threadCount = 0;
}
void Wait()
@@ -82,20 +90,14 @@ public:
_threads[i].Wait();
}
- virtual void OnSocketOpen(tcp::socket&& sock)
+ virtual void OnSocketOpen(tcp::socket&& sock, uint32 threadIndex)
{
- size_t min = 0;
-
- for (int32 i = 1; i < _threadCount; ++i)
- if (_threads[i].GetConnectionCount() < _threads[min].GetConnectionCount())
- min = i;
-
try
{
std::shared_ptr<SocketType> newSocket = std::make_shared<SocketType>(std::move(sock));
newSocket->Start();
- _threads[min].AddSocket(newSocket);
+ _threads[threadIndex].AddSocket(newSocket);
}
catch (boost::system::system_error const& err)
{
@@ -105,6 +107,23 @@ public:
int32 GetNetworkThreadCount() const { return _threadCount; }
+ uint32 SelectThreadWithMinConnections() const
+ {
+ uint32 min = 0;
+
+ for (int32 i = 1; i < _threadCount; ++i)
+ if (_threads[i].GetConnectionCount() < _threads[min].GetConnectionCount())
+ min = i;
+
+ return min;
+ }
+
+ std::pair<tcp::socket*, uint32> GetSocketForAccept()
+ {
+ uint32 threadIndex = SelectThreadWithMinConnections();
+ return std::make_pair(_threads[threadIndex].GetSocketForAccept(), threadIndex);
+ }
+
protected:
SocketMgr() : _acceptor(nullptr), _threads(nullptr), _threadCount(1)
{
diff --git a/src/server/worldserver/CMakeLists.txt b/src/server/worldserver/CMakeLists.txt
index 535383ac605..99495986842 100644
--- a/src/server/worldserver/CMakeLists.txt
+++ b/src/server/worldserver/CMakeLists.txt
@@ -131,10 +131,10 @@ set_target_properties(worldserver PROPERTIES LINK_FLAGS "${worldserver_LINK_FLAG
target_link_libraries(worldserver
game
- common
+ scripts
shared
database
- scripts
+ common
g3dlib
gsoap
Detour
diff --git a/src/server/worldserver/worldserver.conf.dist b/src/server/worldserver/worldserver.conf.dist
index 0f60a71405a..05d303cfd9b 100644
--- a/src/server/worldserver/worldserver.conf.dist
+++ b/src/server/worldserver/worldserver.conf.dist
@@ -161,6 +161,45 @@ BindIP = "0.0.0.0"
ThreadPool = 2
#
+# CMakeCommand
+# Description: The path to your CMake binary.
+# If the path is left empty, the built-in CMAKE_COMMAND is used.
+# Example: "C:/Program Files (x86)/CMake/bin/cmake.exe"
+# "/usr/bin/cmake"
+# Default: ""
+
+CMakeCommand = ""
+
+#
+# BuildDirectory
+# Description: The path to your build directory.
+# If the path is left empty, the built-in CMAKE_BINARY_DIR is used.
+# Example: "../TrinityCore"
+# Default: ""
+
+BuildDirectory = ""
+
+#
+# SourceDirectory
+# Description: The path to your TrinityCore source directory.
+# If the path is left empty, the built-in CMAKE_SOURCE_DIR is used.
+# Example: "../TrinityCore"
+# Default: ""
+
+SourceDirectory = ""
+
+#
+# MySQLExecutable
+# Description: The path to your mysql cli binary.
+# If the path is left empty, built-in path from cmake is used.
+# Example: "C:/Program Files/MySQL/MySQL Server 5.6/bin/mysql.exe"
+# "mysql.exe"
+# "/usr/bin/mysql"
+# Default: ""
+
+MySQLExecutable = ""
+
+#
###################################################################################################
###################################################################################################
@@ -1167,26 +1206,6 @@ BirthdayTime = 1222964635
Updates.EnableDatabases = 7
#
-# Updates.SourcePath
-# Description: The path to your TrinityCore source directory.
-# If the path is left empty, built-in CMAKE_SOURCE_DIR is used.
-# Example: "../TrinityCore"
-# Default: ""
-
-Updates.SourcePath = ""
-
-#
-# Updates.MySqlCLIPath
-# Description: The path to your mysql cli binary.
-# If the path is left empty, built-in path from cmake is used.
-# Example: "C:/Program Files/MySQL/MySQL Server 5.6/bin/mysql.exe"
-# "mysql.exe"
-# "/usr/bin/mysql"
-# Default: ""
-
-Updates.MySqlCLIPath = ""
-
-#
# Updates.AutoSetup
# Description: Auto populate empty databases.
# Default: 1 - (Enabled)
diff --git a/src/tools/mmaps_generator/MapBuilder.cpp b/src/tools/mmaps_generator/MapBuilder.cpp
index 3a63f9718db..80b7b266f27 100644
--- a/src/tools/mmaps_generator/MapBuilder.cpp
+++ b/src/tools/mmaps_generator/MapBuilder.cpp
@@ -699,7 +699,7 @@ namespace MMAP
iv.polyMesh = rcAllocPolyMesh();
if (!iv.polyMesh)
{
- printf("%s alloc iv.polyMesh FIALED!\n", tileString);
+ printf("%s alloc iv.polyMesh FAILED!\n", tileString);
delete[] pmmerge;
delete[] dmmerge;
delete[] tiles;
@@ -710,7 +710,7 @@ namespace MMAP
iv.polyMeshDetail = rcAllocPolyMeshDetail();
if (!iv.polyMeshDetail)
{
- printf("%s alloc m_dmesh FIALED!\n", tileString);
+ printf("%s alloc m_dmesh FAILED!\n", tileString);
delete[] pmmerge;
delete[] dmmerge;
delete[] tiles;