TrinityCore
Loading...
Searching...
No Matches
world_script_loader.cpp
Go to the documentation of this file.
1/*
2 * This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the
6 * Free Software Foundation; either version 2 of the License, or (at your
7 * option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18#include "World.h"
19
20// This is where scripts' loading functions should be declared:
21// world
24void AddSC_go_scripts();
25void AddSC_npc_guard();
32void AddSC_duel_reset();
33void AddSC_xp_boost();
34// player
35void AddSC_chat_log();
37
38// The name of this function should match:
39// void Add${NameOfDirectory}Scripts()
41{
51 AddSC_chat_log(); // location: scripts\World\chat_log.cpp
52
53 // FIXME: This should be moved in a script validation hook.
54 // To avoid duplicate code, we check once /*ONLY*/ if logging is permitted or not.
55 if (sWorld->getBoolConfig(CONFIG_IP_BASED_ACTION_LOGGING))
56 AddSC_action_ip_logger(); // location: scripts\World\action_ip_logger.cpp
58 if (sWorld->getIntConfig(CONFIG_XP_BOOST_DAYMASK) != 0)
60}
#define sWorld
Definition World.h:900
@ CONFIG_XP_BOOST_DAYMASK
Definition World.h:357
@ CONFIG_IP_BASED_ACTION_LOGGING
Definition World.h:161
void AddSC_go_scripts()
void AddSC_item_scripts()
void AddSC_npc_innkeeper()
void AddSC_npc_professions()
void AddSC_achievement_scripts()
void AddSC_action_ip_logger()
void AddWorldScripts()
void AddSC_areatrigger_scripts()
void AddSC_emerald_dragons()
void AddSC_npcs_special()
void AddSC_xp_boost()
void AddSC_npc_guard()
void AddSC_chat_log()
Definition chat_log.cpp:144
void AddSC_duel_reset()