Commit Graph

110 Commits

Author SHA1 Message Date
Nay
d0e4e20265 Merge pull request #8825 from joschiwald/vmapspelligno
Core/VMaps: drop "vmap.ignoreSpellIds" in config
this is not longer necessary since we use SPELL_ATTR2_CAN_TARGET_NOT_IN_LOS
2013-01-07 07:36:40 -08:00
Nay
a509aea659 Core/Misc: Fix a couple of warnings, some of them performance related
Errors were found using Cppcheck, open-source static analysis tool
2013-01-04 23:14:14 +00:00
Vincent_Michael
cc65aba789 Update copyright note for 2013.
Happy new year.
2013-01-01 00:41:01 +01:00
Shauren
f1170ba0fb Core: Fixed some level 4 warnings (msvc) 2012-12-31 20:43:14 +01:00
joschiwald
22896bd7a4 Core/VMaps: drop "vmap.ignoreSpellIds" in config, this is not longer necessary since we use SPELL_ATTR2_CAN_TARGET_NOT_IN_LOS 2012-12-30 18:52:32 +01:00
Subv
f6f3680995 Core/BuildSystem: Added some more headers to the collisions project PCH 2012-12-24 10:34:36 -05:00
Spp
2251d1bfae Core/Misc: Set mode 0644 for files 2012-11-27 13:03:12 +01:00
Spp
7bef4ce401 Core/Misc: Reduce header dependencies - Step III 2012-11-20 15:03:56 +01:00
Spp
6bd90626ea Core/Build: Fix compile using mysqllite included with core
Closes #8283
2012-11-10 14:49:28 +01: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
Nay
91fd408446 Merge pull request #7842 from Elron103/pull-requests2
Core/GameObject: Implement method GetDisplayId, use it for GameObjectModels
2012-09-23 07:49:18 -07:00
Elron103
d45a768810 Core/GameObject: Implement method GetDisplayId, use it for GameObjectModels 2012-09-22 18:01:51 +02:00
Spp
358c6a26d6 Core: Warning fixes (Also some -pedantic under game folder) 2012-09-10 13:04:31 +02:00
Kandera
26af8ac65a Core/Gameobject: another attempt at fixing collision. chest gameobject initial collision provided by vincent-michael 2012-09-04 12:08:12 -04:00
Nay
5f1977cb1d Core: Fix many "errors"/warnings and coding style (1)
Extractors, worldserver, authserver, shared and collision affected

Errors were found using Cppcheck, open-source static analysis tool
2012-08-30 19:07:59 +01:00
Chaplain
fb1ac16b0c Core/Misc: Some fixes here and there
Closes #7277
2012-08-20 11:05:50 +02:00
Spp
8a1e7dd070 Core/Loading: Re-enable Server loading log 2012-08-16 00:23:44 +02:00
Nay
d1b10082a2 Whitespace is the root of all evil (version 2) 2012-08-03 22:55:18 +01: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
Shauren
6eadc63ade Core/VMaps: Use fabs instead of abs for float type. On some platforms abs has only int overload exists. 2012-07-01 01:42:58 +02:00
Shauren
c8d20004a5 Core: Minor code style corrections 2012-06-30 16:07:09 +02:00
Chaplain
716e2db0e1 Core/Misc: Code-style + some const methods. 2012-06-21 21:05:45 +03:00
Shauren
a1a7a2d7c0 Core/Players
* Add liquid special aura only if player is in it (not when above)
* Use CastSpell instead of AddAura - checks all dbc conditions on spell
2012-03-07 18:57:47 +01:00
Shauren
e5d23103f3 Core/Maps
* Corrected liquid type extraction in maps - MCLQ chunk must be parsed together with MH2O (they stack)
* Fixed liquid detection in WMO objects
* Implemented LiquidType.dbc use, players will now get proper auras in special liquids
* Turned off slime damage by default (Naxxramas uses periodic damage aura for this purpose)
* Implemented liquid type overrides basing on area/zone
* Renamed final temp_gameobject_models to GameObjectModels.dtree (the temporary one produced by vmap extractor remains unaffected)

Note: Map and Vmap re-extraction is required
2012-03-07 13:09:35 +01:00
Subv
4029c23547 Core/Collisions: Reverted a commit about M2 models.
closes #5312 and probably others
2012-03-04 08:23:19 -05:00
Spp
3e622ee7ac Core: Minor cleanup in ObjectMgr and warning fixes 2012-02-27 11:08:34 +01:00
Shauren
8ae3037307 Compile fix for gcc 4.5 and higher 2012-02-23 16:14:50 +01:00
Shauren
adc115dc41 Core/Vmaps: Fixed errors during loading gameobject models and improved error output (will now write to logs) 2012-02-23 15:56:53 +01:00
click
dce3bc01ac Core: Fix non-PCH building 2012-02-19 16:57:07 +01:00
click
5411e1ce52 Core: Clean up whitespace and tabs in the base sourcetree 2012-02-18 16:52:08 +01:00
Spp
03c34ee507 Fix a lot of warnings 2012-02-16 13:56:28 +01:00
leak
bfc657defe Core/VMaps: Logic fail in path cleanup 2012-02-15 16:42:40 +01:00
Subv
c53d722aa2 Core/Collision: Models with flag MOD_M2 (mostly trees, among some other objects) should not be taken into account for LoS checks, this check does not apply to gameobjects (yet)
closes #3495

Signed-off-by: Subv <s.v.h21@hotmail.com>
2012-02-14 18:19:40 -05:00
Subv
ff9830c18d Core/Spells: Blink wont be able to trespass solid objects anymore (walls/doors)
Refactored some code

Signed-off-by: Subv <s.v.h21@hotmail.com>
2012-02-11 19:23:18 -05:00
Subv2112
93d199f043 Core/Collision: Ported dynamic line of sight patch by Silverice from MaNGOS and
added lots of improvements
Please re-extract vmaps
2012-02-09 13:58:22 -05:00
kiper
8299627ed9 Update headers for 2012. HAPPY NEW YEAR!!! 2012-01-01 00:32:13 +01:00
mns
8f8d45fdaf Fix vmapassembler
Signed-off-by: mns <pgameserver@gmail.com>
2011-12-01 04:19:38 +03:30
Machiavelli
4c3c418511 Core/Misc: Make VMapManager2::acquireModelInstance and releaseModelInstance thread safe
Closes #4086
2011-11-26 19:11:58 +01:00
Shauren
44693cfa99 Core: Fixed a few warnings and silly typos in scripts 2011-11-23 16:57:08 +01:00
Spp
e3f8588a22 Minor changes here and there:
- Cosmetic changes
- 'Engrish fix'
- Initialization of some vars
- Remove some not needed includes
2011-10-18 14:59:23 +02:00
unknown
8acf07dbab Random minor code cleanup 2011-09-29 22:35:00 +04:00
Spp
b16d2245bb Cosmetic: Multiple cosmetic changes
- 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-29 12:43:05 +02:00
Spp
af05915b9e [Cosmetic] Apply codestyle "XXX * " and "XXX *" changed to "XXX* " (with some exceptions) 2011-09-15 14:12:57 +02:00
Spp-
45af1238cf Conditions/DisableMgr: converted from singleton to namespace with free functions. 2011-09-09 14:27:23 +02:00
Spp-
e47b96af3e Core: Append single character to stream as character, not as a string 2011-07-29 14:18:28 +02:00
click
7fe3f55b5e Core: Fix non-PCH build + clean up some sporadic warnings 2011-07-18 14:49:08 +02:00
Lopin
e35e4d6e23 Core/Disables: Allow to disable certain vMaps through Disables system. Wiki will be updated soon 2011-07-11 16:14:26 +02:00
Spp-
bb921ae78c Core: Do not use STL container size method to check if container is empty 2011-07-01 14:58:44 +02:00
Shauren
2fd70ed49d Core/Collision: Fixed possible memory leaks 2011-05-11 14:11:20 +02:00
leak
1003f30448 Add spaces after commas 2011-04-29 20:47:02 +02:00