Commit Graph

42 Commits

Author SHA1 Message Date
Spp
2251d1bfae Core/Misc: Set mode 0644 for files 2012-11-27 13:03:12 +01:00
Subv
10a8a4f8f6 Missing variable in the function call. 2012-11-14 09:42:05 -05:00
Subv
51414967c4 Core/Build: Fixed a little mistake. 2012-11-14 09:35:45 -05:00
vlad852
a8ef3013f0 Core/SAI: Fix SMART_ACTION_SIMPLE_TALK for players. 2012-11-14 09:15:31 -05:00
Spp
333b8e5159 Core/Build: Enable Clang PCH support and OS X specific features
Core: Fix warnings here and there
2012-11-09 13:13:45 +01:00
Spp
013fb1f4d9 Core/Misc: reduced amount of string memory allocations (Step I) 2012-10-24 15:34:48 +02:00
Spp
8a1e7dd070 Core/Loading: Re-enable Server loading log 2012-08-16 00:23:44 +02:00
Spp
634776e0bc Fix compile under windows 2012-08-03 15:54:54 +02:00
Spp
55ce180f28 Core/Logging: Add Asyncronous logging with Loggers ("What to log") and 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-08-03 14:20:18 +02:00
joschiwald
1ddf039de8 Core/CreatureTextMgr: Fix crash in GetLocalizedChatString() 2012-03-10 20:21:27 +01:00
joschiwald
7683297423 Core/CreatureTextMgr: Fix typo in LoadCreatureTextLocales() 2012-03-05 23:23:23 +01:00
Shauren
09f0a2c04f Core/CreatureTextMgr: Added support for creature_text localization 2012-03-01 22:26:05 +01:00
kiper
8299627ed9 Update headers for 2012. HAPPY NEW YEAR!!! 2012-01-01 00:32:13 +01:00
leak
73cf793e56 Core/DBLayer: Refactor prepared statement defines Note:
The new format for the middle section is a 3-letter upper case abbreviation of the sql command being executed (select -> SEL, update -> UPD, etc.)
{DB}_{SEL/INS/UPD/DEL/REP}_{Summary of data changed}
2011-12-31 20:14:38 +01:00
Bootz
f75ec5ba2b Core: Codestyle clean-up
"plr"->player

Note: codestyle methods needs maintained, Player* player.
2011-11-07 11:06:39 -06:00
Spp
af05915b9e [Cosmetic] Apply codestyle "XXX * " and "XXX *" changed to "XXX* " (with some exceptions) 2011-09-15 14:12:57 +02:00
Spp-
b2a84d9f1e Core/ObjectMgr: Remove GetPlayer function (Remove double use of singletons) 2011-07-27 12:14:27 +02:00
click
f16df538ee Core: More codestyle cleanups 2011-06-12 01:47:45 +02:00
Shauren
65cdf604f1 Core/CreatureTextMgr: Fixed creature yell range 2011-05-16 21:19:32 +02:00
Shauren
ecc95a8690 Core/CreatureTextMgr: Converted chat types to use values found in sniff, without any need for conversions 2011-05-13 22:44:01 +02:00
leak
1003f30448 Add spaces after commas 2011-04-29 20:47:02 +02:00
leak
6d1924cee8 Removing SQLStorage class leftovers 2011-04-28 23:03:02 +02:00
Machiavelli
e07e20ffca Core/Log: Implement log masks for debug log level, to allow selective debug output. Update your worldserver.conf. 2011-02-20 20:16:34 +01:00
Machiavelli
deed0d0781 Core/General: Fix some comment style. //* to // *. Fixes certain code display errors on nano. Thanks to Aokromes for pointing out. 2011-01-16 12:23:17 +01:00
Machiavelli
957c69de83 Update copyright note for 2011.
Happy new year.
2011-01-01 15:01:13 +01:00
Shauren
928443d899 Core: Removed more operator workarounds for ACE_Singleton (missed previously because of inconsistent naming)
--HG--
branch : trunk
2010-12-23 23:25:44 +01:00
Shauren
0f3b9019a8 Core: Get rid of dirty operator workaround for ACE_Singleton class implementation
--HG--
branch : trunk
2010-12-22 21:25:23 +01:00
leak
6115b0bd5f Removing ProgressBars as they are performing badly on startup.
[**************************************************] 100%
R.I.P

--HG--
branch : trunk
2010-12-22 00:12:03 +01:00
leak
fd694cd232 Streamlining loading functions for server startup
- Added a couple of timer outputs
- Improved code consistency between loading functions
- Progess bars should look and behave similar on all OS now (sLog.outString() is not needed anymore to replace the progress bar in log files)

--HG--
branch : trunk
2010-12-19 17:06:33 +01:00
Rat
be25e38144 Core/SmartAI: added SMART_ACTION_SIMPLE_TALK, param1: textID, uses the 'Targets' to say the text,
NOTE: textID is relative to the current target's entry OR if target is a player, text is used with source creature's entry

--HG--
branch : trunk
2010-11-05 19:38:43 +01:00
Rat
5cb119e617 Core/AI: implemented SmartScripts System (still beta) not 100% complete
WARNING: Use scripts at own risk. You were warned.
NOTE0: creature, gameobject, areatrigger type scripts should be fully functional
NOTE1: has no effect on any core related stuff if not using any SmartScript
NOTE2: all event/action/etc descriptions can be found in SmartScriptMgr.h

SmartScripts is a reloadable DB-Sript system, with full control for special scripting,
like escorting, following, complex combat handling, pre-stored AI templates(caster, turret, etc) and much more
with a total of 66 events, 78 actions, 22 target types, and can be easily extended

--HG--
branch : trunk
2010-10-27 21:01:47 +02:00
Spp
0b4abbb48e Core: Fix some warnings added in recent commits
--HG--
branch : trunk
2010-10-26 11:40:13 +02:00
Rat
e4c27a2ffa Core/TextMgr: updated with new funtions for future useage
--HG--
branch : trunk
2010-10-25 18:25:21 +02:00
click
f0c4241ea4 Remove the accidental additions of CRLF-crap from the header updates
--HG--
branch : trunk
2010-10-07 15:35:36 +02:00
click
a67d7c9afd Copyright header updates - part 3... (and some whitespace cleanups)
--HG--
branch : trunk
2010-10-07 14:00:52 +02:00
click
df66aee929 Yet more copyright header updates
--HG--
branch : trunk
2010-10-07 13:38:35 +02:00
Rat
af660f80ec Core/CreatureTextMgr: send emote, sound with texts, return duration after chat so scriptsystem can handle timings, cleanup
--HG--
branch : trunk
2010-09-29 23:26:28 +02:00
Spp
e27976102d Core/: Fix warnings
--HG--
branch : trunk
2010-09-28 14:48:17 +02:00
Rat
bbf86641a1 Core/Scripts/SmartAI: removed test code
Core/CreatureTextMgr: added reload command
handle text from DB
handle grouped texts
handle repeatable/single texts based on probability
todo: sound/emote, code cleanup

--HG--
branch : trunk
2010-09-26 20:48:25 +02:00
Rat
9ea9effadd Core/Scripts/SmartAI: add test for TextMgr (temp)
Core/CreatureTextMgr: added basic chat function, you can now experiment with it if bored

--HG--
branch : trunk
2010-09-25 23:52:17 +02:00
click
461590832a Core: Generic cleanup (tab2spaces/whitespace removal)
--HG--
branch : trunk
2010-09-25 22:03:57 +02:00
Rat
28e90bbb60 Core/Scripts/SmartAI: added SmartAI files
Core/DBLayer/Texts: added CreatureTextMgr files
BuildSystem: added cmake for above files
Note: these are still under development and NOT USABLE
should not effect anything now

--HG--
branch : trunk
2010-09-25 18:47:03 +02:00