Commit Graph

63 Commits

Author SHA1 Message Date
Kargatum
52aa0e9966 feat(License): add new headers information about license (#7941)
Co-authored-by: Francesco Borzì <borzifrancesco@gmail.com>
2021-09-30 13:40:52 +07:00
Kitzunu
2f449326e0 refactor(Core): Rename ...Manager to ...Mgr (#6910)
* Rename MapManager.h to MapMgr.h

* Rename BanManager.h to BanMgr.h

* Rename MapManager.cpp to MapMgr.cpp

* Rename BanManager.cpp to BanMgr.cpp

* Rename MapRefManager.h to MapRefMgr.h

* Rename ThreatManager.h to ThreatMgr.h

* Rename GridRefManager.h to GridRefMgr.h

* Rename ThreatManager.cpp to ThreatMgr.cpp

* Rename GroupRefManager.h to GroupRefMgr.h

* Rename HostileRefManager.h to HostileRefMgr.h

* Rename HostileRefManager.cpp to HostileRefMgr.cpp

* Rename MMapManager.h to MMapMgr.h

* Rename FollowerRefManager.h to FollowerRefMgr.h

* Rename VMapManager2.h to VMapMgr2.h

* Rename IVMapManager.h to IVMapMgr.h

* Rename MMapManager.cpp to MMapMgr.cpp

* Rename VMapManager2.cpp to VMapMgr2.cpp

* Rename RefManager.h to RefMgr.h

* Rename WaypointManager.h to WaypointMgr.h

* Rename WaypointManager.cpp to WaypointMgr.cpp

* Rename MPQManager.h to MPQMgr.h

* Rename MPQManager.cpp to MPQMgr.cpp

* Rename IMMAPManager.h to IMMAPMgr.h

* fix build

* Update Main.cpp

* chore(Core/Misc): Remove toxic language

* Revert "chore(Core/Misc): Remove toxic language"

* fix build

* build
2021-09-15 17:50:28 +02:00
lineagedr
ae8a78d90a feat(Core/Gameobject): add a range check for gameobjects (#7521) 2021-08-31 10:34:43 +02:00
UltraNix
a8c0a2cc89 fix(Core/Movement): (#7008)
- Get zone/area IDs from vmap data in the liquid update
- Add new method Map::getFullVMapDataForPosition to get area info and liquid info in a single vmap lookup
- Adjust GetZoneId/GetAreaId on WorldObject to always return these cached fields.
- Clean up liquid state handling on Unit and Player
- Implemented getting area id from gameobject spawns.
- Removed old core related to getting movement flags dependent on environment.
- Movement flags are now processed more precisely and dynamically.

Original source: TrinityCore.

- Closes #5086
- Updates #2208.
2021-08-25 12:41:20 +02:00
UltraNix
1b7d3708a6 fix(Core/Loot): (#7452)
- Players that did not participate in killing dungeon boss are not eligible to get loot.
- Players that are too far away from the looted object are not eligible to get loot.
- Players that released spirit and were outside the dungeon when the loot has been released are eligible to get loot.
- Players that have pending bind are not eligible to get loot.
- Properly get loot recipient for some chests in dungeons.
- All above fixes should work in any loot mode (group loot, master loot, etc.)
- Closes #2104.
2021-08-24 23:48:22 +02:00
UltraNix
1becd73f09 fix(Core/Movement): Rewritten follow movement generator for pets (#7324)
- Closes #7296
2021-08-24 11:08:50 +02:00
UltraNix
e37dba8df6 fix(Core/Spells): Far Sight auras are supposed to extend view distance and allows seeing objects from further distance (#7068)
- Closes #5793.
2021-07-26 10:23:08 +02:00
Francesco Borzì
1c4523415a fix(Core): -Wambiguous-reversed-operator warning (#6864) 2021-07-14 00:35:33 +02:00
Shiroe
f8c8e98a0a feat(Core): port aggro distance from vMaNGOS (#6214)
Read detection_range values from creature_template
2021-07-08 18:01:27 +02:00
Kargatum
5787d00d54 chore(Core/Logging): replace most server loggers (#5726)
* chore(Core/Logging): replace most server loggers

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>
2021-06-21 03:07:12 +02:00
Francesco Borzì
466cdb68d6 refactor(Core): code cleanup (part 2) (#6374) 2021-06-16 20:40:42 +02:00
Bogir[rus]
e3a5727222 chore(Core): typo fixes (#6272)
Co-authored-by: Bogir <m-000@bk.ru>
2021-06-16 11:28:00 +02:00
Kitzunu
7152ddc82c refactor(Core/Grids): Ported cmangos/mangos-wotlk@ea99457 (#6113)
* refactor(Core/Grids): Ported cmangos/mangos-wotlk@ea99457

(cherry picked from commit d6201e5dbb)
Co-Authored-By: Shauren <shauren.trinity@gmail.com>
Co-Authored-By: SilverIce <slifeleaf@gmail.com>

* Update CellImpl.h

* w

* more more brackets

* ew

* fix build
2021-06-03 05:27:51 +02:00
Kitzunu
897a02bb75 refactor(Core/Misc): acore to Acore (#6043) 2021-05-31 14:21:54 +02:00
Patrick Lewis
c3242caf74 fix(Core/Maps): GetCollisionHeight and Z_OFFSET_FIND_HEIGHT (#5778) 2021-05-14 10:10:35 +02:00
UltraNix
f4c226423d feat(Core/Misc): implement ObjectGuid class (port from TC) (#4885) 2021-04-25 22:18:03 +02:00
Kargatum
4af4cbd3d9 feat(Core/Logging): rework logging (#4692)
* feat(Core/Logging): rework logging

* correct level for sql.sql

* del unused config options

* Correct build

* correct after merge

* whitespace

20:29:37 1. 'Player.cpp'. Replace (1)
20:29:37 2. 'ObjectMgr.cpp'. Replace (3)

* 1

* correct logging

* correct affter merge

* 1

* 2

* LOG_LEVEL_WARN

* #include "AppenderDB.h"

* 3

* 4

* 5

* 1. 'WorldSocket.cpp'. Replace (1)

* 6

* 1
2021-04-17 11:20:07 +02:00
Kargatum
2b3d46bd4f feat(Core/Hooks): added collection of hooks to extends AC (#3047)
This collection of hooks comes from the Maelstrom project. It allows to release modules such as :
- 3v3-soloqueue
- 1v1 arena
- pvestats

and many others
2021-04-13 13:26:39 +02:00
UltraNix
ae7b452fdf fix(Core/Objects): LoS calculation (#5084) 2021-04-07 19:33:38 +02:00
UltraNix
6eeb088211 fix(Core/Movement): Corrected calculating ground level in shallow water. (#5114) 2021-04-04 23:22:13 +02:00
UltraNix
1d5cc1fb74 feat(Core/Maps): Use a fixed offset instead of full collision height when retrieving floor Z. (#4909) 2021-03-21 15:20:06 +01:00
Francesco Borzì
f6a17164be fix(Core/License): issue with old files license (#4762) 2021-03-17 09:46:01 -06:00
Kitzunu
28f1dc5c0c refactor(Core): replace NULL with nullptr (#4593) 2021-03-02 01:34:20 +01:00
Kargatum
dbefa17a53 feat(Core/Config): rework config and delete ACE inherited (#4608) 2021-02-28 14:37:03 +01:00
Kargatum
b9e132a941 chore(Misc): correct double includes (#4647) 2021-02-26 17:44:08 +07:00
Kitzunu
dbc0ff6554 refactor(Core): sort #includes alphabetically (#4579) 2021-02-24 22:34:42 +01:00
Yehonal
c8f43d8584 feat(Core/Movement): Improved pathfinding, collisions and movements (#4220)
Npc positioning
Implemented slope check to avoid unwanted climbing for some kind of movements (backwards, repositioning etc.)
Implemented backwards movement
Re-implemented circle repositioning algorithm (smartest than retail, but with the same feeling)
Fixed random position of summoned minions
Improved pet following movement. Also, they attack NPC from behind now. Thanks to @Footman

Swimming creatures
Fixed max_z coordinate for swimming creatures. Now only part of their body is allowed to be out of the water level
Fixed pathfinder for swimming creatures creating shortcuts for specific segments, now they swim underwater to reach the seashore instead of flying above the water level.
Creatures with water InhabitType but no swimming flag now, when not in combat, will walk on water depth instead of swimming. Thanks @jackpoz for the original code
UNIT_FLAG_SWIMMING in UpdateEnvironmentIfNeeded to show the swimming animation correctly when underwater
Implemented HasEnoughWater check to avoid swimming creatures to go where the water level is too low but also to properly enable swimming animation only when a creature has enough water to swim.

Walking creatures
Extended the DetourNavMeshQuery adding area cost based on walkability (slope angle + source height) to find better paths at runtime instead of completely remove them from mmaps
improve Z height in certain conditions (see #4205, #4203, #4247 )

Flying creatures
Rewriting of the hover system
Removed hacks and improved the UpdateEnvironmentIfNeeded. Now creatures can properly switch from flying to walk etc.
Spells
LOS on spell effect must be calculated on CollisionHeight and HitSpherePoint instead of position coords.
Improved position for object/creature spawned via spells
Improved checks for Fleeing movements (fear spells)

Other improvements
Implemented method to calculate the CollisionWidth from dbc (used by repositioning algorithm etc.)
Improved raycast and collision checks

Co-authored-by: Footman <p.alexej@freenet.de>
Co-authored-by: Helias <stefanoborzi32@gmail.com>
Co-authored-by: Francesco Borzì <borzifrancesco@gmail.com>
Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>
2021-02-01 01:34:27 +01:00
Silker
0a8a7ef149 fix(Core): Activate creatures and objects during opening cinematics (#4045)
Co-authored-by: Si1ker <55638679+Sombranator@users.noreply.github.com>
Co-authored-by: Stefano Borzì <stefanoborzi32@gmail.com>
2021-01-22 01:03:30 +01:00
Stefano Borzì
df600f9946 fix(Core/CreatureAI): revert NPC repositioning and path system (temporarily) (#4274) 2021-01-14 19:17:34 +01:00
Kargatum
ea93a5c1a1 feat(CI/Codestyle): added codestyle check (#3668) 2021-01-09 11:59:50 +01:00
Stefano Borzì
b2761626fe feat(Core/CreatureAI): improve npc position during the combat (#3369)
+ tangent equation to find correct angle and distance when moving

+ implemented proper backward

* Improved performance + random angle margin

* chore: add tollerance calculation in instance

* improved LOS checks with movements

* implemented collisions using raycast (imported by TC)

+ improved collision detection for CanReachPositionAndGetCoords

+ improved collision check

+ set correct flags for the backward movement

+ first implementation of slope angle (to improve)

Co-authored-by: Yehonal <yehonal.azeroth@gmail.com>
2021-01-04 20:23:08 +01:00
Kitzunu
d3aff86c32 fix(Core/Object): Fix small error in Position::IsWithinBox (#4050) 2020-12-25 18:44:19 -06:00
Meltie2013
af53598fa2 fix(Core/Game): Rest & Inn Improvements (#3780) 2020-12-11 08:23:09 -06:00
Kargatum
a2b26272d2 refactor(Core/Game): restyle game lib with astyle (#3466) 2020-10-12 10:08:15 +02:00
Petric
29f2c2aeda feat(Core/Script): Playing music from GameObjects and added holiday zones music script (#3307) 2020-09-02 16:32:41 +02:00
Kitzunu
1f89282b22 refactor(Core): NULL -> nullptr (#3275)
* NULL to nullptr

* NULL to nullptr

* NULL to nullptr

* NULL to nullptr

* NULL to nullptr

Co-authored-by: Francesco Borzì <borzifrancesco@gmail.com>
Co-authored-by: Stefano Borzì <stefanoborzi32@gmail.com>
2020-08-31 11:55:09 +02:00
P-Kito
8aa80eef18 feat(Core/SAI): new Actions + Polar Coords System Offset Relocating (#2880) 2020-04-16 11:39:45 +02:00
Stoabrogga
8f5c628836 feat(Core/Hook): New GlobalScript hook (#2665)
This allows you to change the behavior of phase system
2020-02-26 09:44:12 +01:00
Stoabrogga
ed243d6911 feat(Core/Config): Parameter to set all creatures with WP movement active (#2615) 2020-02-23 14:08:42 +01:00
Viste
38e8503d21 fix(Core/Misc): fix some exploits (#2630) 2020-02-18 08:26:12 +01:00
Nefertumm
59234f8f4b fix(CORE): Missing override on various functions (#2602) 2020-01-21 19:03:15 -03:00
Viste
e22d78ecd6 refactor(Core): rename namespaces and macros to acore (#2454) 2019-12-01 13:13:31 +01:00
Stoabrogga
9ea9329285 feat(Core/CreatureAddon): increased visibility for large creatures (#2304) 2019-10-04 15:22:03 +02:00
Viste
854b426978 feat(Core): Added ABORT() macro to prevent the usage of ASSERT(false) as a quick hack to crash the core misusing assert (#2273) 2019-09-26 09:51:33 +02:00
Stoabrogga
eee8e965e7 fix(Core): increase visibility distance of large game objects (#1788) 2019-05-08 08:01:40 +02:00
Stoabrogga
e204ac4043 fix(Core/Eluna): fix compiler warning concerning Eluna (#1671) 2019-04-05 00:26:09 +02:00
Stoabrogga
54b23ce209 fix(DB/Core): play event after quest "Hero of the Mag'har"; extend SAI to play music (#1570) 2019-03-19 09:04:40 +01:00
Nefertumm
c15206fc15 Revert "feat(core): Ensure that all actions are compared to fixed point in time (#1236) (#1458)" (#1471)
This reverts commit 51b8773528.
2019-02-15 15:14:49 -03:00
Viste(Кирилл)
51b8773528 feat(core): Ensure that all actions are compared to fixed point in time (#1236) (#1458)
i.e. world update start
2019-02-14 19:22:17 +01:00
Viste(Кирилл)
cb81f3c17a feat(Core/LOS): restruct LOS functions and add LineOfSight check (#1459) 2019-02-13 22:24:04 +01:00