aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/Examples
AgeCommit message (Collapse)Author
2014-09-21Scripts/Examples: Remove outdated example scriptsjackpoz
Remove outdated misleading example scripts not following anymore current TC codestyle and standards. Please refer to the wiki or forum for up to date examples and documentation.
2014-09-14Scripts/Commands: Fixed build with -DSCRIPTS=0Shauren
2014-09-14Core/Entities: Use ObjectGuid class in game projectShauren
2014-07-22Core/Misc: Replace rand() calls with SFMTjackpoz
2014-04-29Core/Misc: Remove obsolete C++11 backward compatibility macrosDehravor
OVERRIDE, FINAL, DELETE_MEMBER
2014-01-01Update copyright note for 2014.Vincent_Michael
Happy new year.
2013-12-25Core/Scripting: Replace casted with cast as casted is not a word.Malcrom
2013-12-23Core/Chat: Refactored building chat packetsShauren
* Moved everything into one specialized method instead of being scattered all over the place * Allow localizing creature names in chat messages (when using $N) * Send SMSG_GM_MESSAGECHAT for gm messages
2013-11-08Core/Logging: Remove LOG_FILTER_XXX defines with it's value (remember logger ↵Spp
names are case-sensitive)
2013-10-27Core/Code: Unify codestyle for brackets: {} to { }.Ascathor
Also added missing copyright to some files.
2013-10-22Scripts/Misc: Coding Style unification? (by Aokromes)Vincent_Michael
2013-08-07Scripts/DrakTharonKeep: add some spellscripts, add yells to novos, and do ↵joschiwald
some cosmetic changes
2013-07-06Misc: Use override and final C++11 keywords in a few places (mostly scripts)Nay
OVERRIDE and FINAL are TC macros (expand to nothing if compiler does not support C++11)
2013-07-06Scripted/Misc: Some cleanupVincent-Michael
2013-06-22Scripts: Convert DoCast(me->GetVictim(), SPELL_XXXXX); in ↵Vincent-Michael
DoCastVictim(SPELL_XXX);
2013-06-11Core: Some function renaming.Malcrom
2013-05-13Core/Logging: Performance-related tweaks to logging systemSpp
All sLog->out* functions (except outCommand atm) are replaced with TC_LOG_* macros. Memleak fix
2013-02-19Core/Scripts: Removed useless const modifier on method parameters accepting ↵Shauren
primitive types passed by value
2013-01-01Update copyright note for 2013.Vincent_Michael
Happy new year.
2012-11-26Core/DB: Convert 25 more scripts to creature textGacko
2012-11-17Core: Remove Player.h dependency from all the possible headersSpp
2012-10-24Core/Misc: reduced amount of string memory allocations (Step I)Spp
2012-08-03Core/Logging: Add Asyncronous logging with Loggers ("What to log") and ↵Spp
Appenders ("Where to log") system. Will allow to select to full log some parts of core while others are not even logged. - Logging System is asyncronous to improve performance. - Each msg and Logger has a Log Type and Log Level assigned. Each msg is assigned the Logger of same Log Type or "root" Logger is selected if there is no Logger configured for the given Log Type - Loggers have a list of Appenders to send the msg to. The Msg in the Logger is not sent to Appenders if the msg LogLevel is lower than Logger LogLevel. - There are three (at the moment) types of Appenders: Console, File or DB (this is WIP, not working ATM). Msg is not written to the resource if msg LogLevel is lower than Appender LogLevel. - Appender and Console Log levels can be changed while server is active with command '.set loglevel (a/l) name level' Explanation of use with Sample config: Appender.Console.Type=1 (1 = Console) Appender.Console.Level=2 (2 = Debug) Appender.Server.Type=2 (2 = File) Appender.Server.Level=3 (3 = Info) Appender.Server.File=Server.log Appender.SQL.Type=2 (2 = File) Appender.SQL.Level=1 (1 = Trace) Appender.SQL.File=sql.log Appenders=Console Server (NOTE: SQL has not been included here... that will make core ignore the config for "SQL" as it's not in this list) Logger.root.Type=0 (0 = Default - if it's not created by config, server will create it with LogLevel = DISABLED) Logger.root.Level=5 (5 = Error) Logger.root.Appenders=Console Logger.SQL.Type=26 (26 = SQL) Logger.SQL.Level=3 (2 = Debug) Logger.SQL.Appenders=Console Server SQL Logger.SomeRandomName.Type=24 (24 = Guild) Logger.SomeRandomName.Level=5 (5 = Error) Loggers=root SQL SomeRandomName * At loading Appender SQL will be ignored, as it's not present on "Appenders" * sLog->outDebug(LOG_FILTER_GUILD, "Some log msg related to Guilds") - Msg is sent to Logger of Type LOG_FILTER_GUILD (24). Logger with name SomeRandomName is found but it's LogLevel = 5 and Msg LogLevel=2... Msg is not logged * sLog->outError(LOG_FILTER_GUILD, "Some error log msg related to Guilds") - Msg is sent to Logger of Type LOG_FILTER_GUILD (24). Logger with name SomeRandomeName is found with proper LogLevel but Logger does not have any Appenders assigned to that logger... Msg is not logged * sLog->outDebug(LOG_FILTER_SQL, "Some msg related to SQLs") - Msg is sent to Logger SQL (matches type), as it matches LogLevel the msg is sent to Appenders Console, Server and SQL - Appender Console has lower Log Level: Msg is logged to Console - Appender Server has higher Log Level: Msg is not logged to file - Appender SQL has lower Log Level: Msg is logged to file sql.log * sLog->outDebug(LOG_FILTER_BATTLEGROUND, "Some msg related to Battelgrounds") - Msg is sent to Logger root (Type 0) as no Logger was found with Type LOG_FILTER_BATTLEGROUND (13). As Logger has higher LogLevel msg is not sent to any appender * sLog->outError(LOG_FILTER_BATTLEGROUND, "Some error msg related to Battelgrounds") - Msg is sent to Logger root (Type 0) as no Logger was found with Type LOG_FILTER_BATTLEGROUND (13). Msg has lower LogLevel and is sent to Appender Console - Appender Console has lower LogLevel: Msg is logged to Console
2012-07-30Core/Misc: Use proper headers to optimize compileVincent-Michael
2012-04-28Core/SpellScripts: rename GetTarget*() functions to GetExplTarget*(), so the ↵QAston
names reflect better what those functions do. Also update some comments.
2012-03-29Core/Script: Code style.Gyx
WaypointReached(uint32 i) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 uiPointId) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*point*/) -> WaypointReached(uint32 /*waypointId*/) WaypointReached(uint32 uiI) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*i*/) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 uiWPointId) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*wp*/) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*point*/) -> WaypointReached(uint32 waypointId) Signed-off-by: Gyx <2359980687@qq.com>
2012-03-28Core/Script: Code style and remove unused core.Gyx
Signed-off-by: Gyx <2359980687@qq.com>
2012-03-14Core/Script: Clean-Up in Scripts.Gyx
Creature* c -> Creature* creature Signed-off-by: Gyx <2359980687@qq.com>
2012-03-11Update forgotten copyright-headers for 2012.frozenarmor
Signed-off-by: frozenarmor <venom.victorios@gmail.com>
2012-03-07Warning fixes and some random cleanup here and thereSpp
2012-02-18Core: Clean up whitespace and tabs in the base sourcetreeclick
2012-01-01Update headers for 2012. HAPPY NEW YEAR!!!kiper
2011-12-31Core/SpellScripts: Add BeforeCast, OnCast and AfterCast hooks to SpellScripts.QAston
2011-09-29Cosmetic: Multiple cosmetic changesSpp
- Added missing space to 'if', 'for', 'while' and 'switch' when it's followed by '(' - Added missing space after a comma and remove space before comma (with some exceptions) - Remove trailing spaces - Convert tab to spaces Note: Only affects files with extension "cpp" and "h" under /src/server
2011-09-25Core/Spells: spell effect handling improvementsQAston
* Call spell effect handlers in 4 modes: - SPELL_EFFECT_HANDLE_LAUNCH - called when spell is launched (cast just finished) - SPELL_EFFECT_HANDLE_LAUNCH_TARGET - called when spell is launched for each target in spell target map - SPELL_EFFECT_HANDLE_HIT - called when spell hits its destination - SPELL_EFFECT_HANDLE_HIT_TARGET - called when spell hits it's target from spell target map *Correctly implement SPELL_EFFECT_TRIGGER_SPELL, SPELL_EFFECT_TRIGGER_SPELL_WITH_VALUE, SPELL_EFFECT_TRIGGER_MISSILE_SPELL_WITH_VALUE, SPELL_EFFECT_TRIGGER_MISSILE_SPELL *Remove spell system hacks which became obsolete with this commit Core/SpellScripts: add OnEffectLaunch, OnEffectLaunchTarget, OnEffectHit, OnEffectHitTarget hooks for new effect handle modes and remove OnEffect hook. A generic rule of thumb how to update your scripts (will work for nearly all cases) for spell system noobs: if your spell script used GetHitXXXX function, you need to use OnEffectHitTarget, otherwise use OnEffectHit
2011-09-15[Cosmetic] Apply codestyle "XXX * " and "XXX *" changed to "XXX* " (with ↵Spp
some exceptions)
2011-07-26Core: Use new SpellInfo class in core. Sadly, this commit is not compatibile ↵QAston
with some of the custom code. To make your code work again you may need to change: *SpellEntry is now SpellInfo *GetSpellProto is now GetSpellInfo *SpellEntry::Effect*[effIndex] is now avalible under SpellInfo.Effects[effIndex].* *sSpellStore.LookupEntry is no longer valid, use sSpellMgr->GetSpellInfo() *SpellFunctions from SpellMgr.h like DoSpellStuff(spellId) are now: spellInfo->DoStuff() *SpellMgr::CalculateEffectValue and similar functions are now avalible in SpellEffectInfo class. *GET_SPELL macro is removed, code which used it is moved to SpellMgr::LoadDbcDataCorrections *code which affected dbc data in SpellMgr::LoadSpellCustomAttr is now moved to LoadDbcDataCorrections
2011-07-03Core: Cleaning up hungarian notation - Phase8: pSummon -> summon (also did ↵click
related hits)
2011-07-02Core: Cleaning up hungarian notation - Phase5: pKiller -> killerclick
2011-07-02Core: Cleaning up hungarian notation - Phase5: pWho -> whoclick
2011-07-02Core: Cleaning up hungarian notation - Phase2: pPlayer -> playerclick
2011-07-02Core: Start cleaning up hungarian notation - Phase1: pCreature -> creatureclick
2011-06-30Scripts: Reorder file names in Commands/CMakeList file and cosmetic changes ↵Spp-
in all scripts
2011-06-11Core: Codestyle cleanupclick
2011-05-31Changes missing from last commit.QAston
2011-05-31Core/AuraScript: Add DoCheckAreaTarget hook to allow explicit area aura ↵QAston
target selection.
2011-05-30Core/Defines: Update enum TextEmotes, values and names from client. (These ↵kaelima
emotes comes in CMSG_TEXT_EMOTE).
2011-05-29Core/Auras: Use existing aura object on aura reapply/stack increase instead ↵QAston
of creating a new one. You can hook on reapply/stack event by checking for AURA_EFFECT_HANDLE_REAPPLY aura handler mode, AURA_EFFECT_HANDLE_REAL is now not triggered on aura refresh/stack.
2011-05-25Core/AuraScripts: Add AfterEffectRemove and AfterEffectApply hooks, to allow ↵QAston
safe triggering of spellcasts or other actions which may call linked events while OnEffectApply and OnEffectRemove are still there for overriding the way effect is handled on target.
2011-04-29Add spaces after commasleak