Commit Graph
585 Commits
Author SHA1 Message Date
Ovahlord 5cf7de6aa7 Core/Units: make health regeneration functions for players and creatures virtual 2020-04-27 14:39:07 +02:00
Ovahlord e7ba484fcf Core/Units: reworked creature power regeneration handling
* players and creatures now share the same power regeneration regeneration function
* UpdatePowerRegeneration is now virtual and handles creature and player specific formulas individually
* handle update field flag UF_FLAG_UNIT_ALL to handle UNIT_FIELD_POWER_REGEN_FLAT_MODIFIER and UNIT_FIELD_POWER_REGEN_INTERRUPTED_FLAT_MODIFIER for creatures as well
2020-04-27 14:20:33 +02:00
Ovahlord b653f2f819 Core/Units: ported power type updates from master branch 2020-04-22 03:13:02 +02:00
Ovahlord d30c811d9e Core/Creatures: reworked tempoary summon creation
* all stats and values will now be set before summons are getting added to map
* cleaned up summon spell effect handler to reduce duplicade code
* summoner guids will no longer be set for every minion and correctly handle assigning creator guids instead. These values will serve as fallback guid if there is no summoner guid
* friendly tempsummons will now inherit the guild data of their player and pass them on to further allied summons. This fixes guild specific visuals for creatures such as Guild Battle Standards and Guild Heralds.

Todo: check for regressions
2020-04-22 00:20:18 +02:00
Ovahlord c537a2658a Core/Units: reworked power regeneration for players
* use a reversed client function to get the power regeneration rate for all types of powers
* unified all player based regeneration updates into a single statsystem helper
* cleaned up unnecessary regeneration timers
* implement power regeneration for alternative powers
* corrected rage gain numbers based on simulationcraft formulas
2020-04-19 22:53:29 +02:00
Shauren 47acc59f49 Core/DBLayer: Prevent committing transactions started on a different database 2020-04-15 21:02:26 +02:00
Shauren d003ebd8e4 Core/DBLayer: Prevent using prepared statements on wrong database 2020-04-15 19:18:58 +02:00
Ovahlord c2a676b774 Core/Movement: rewrite formation movement
* formation members will now draw their speeds from their formation leader and increase them based on how far they are behind their leader
* added sniffed periodic movement interval which additionally helps keeping up with formation leaders
* the formation movement generator will now persist permanently instead of being a one shot type and handles everything on its own once applied
2020-04-01 01:32:24 +02:00
Ovahlord 9bfe43a88a Core/Entities: remove PhaseMask
* database fields and values will remain until they have been converted to their according phase IDs
2020-03-29 04:05:43 +02:00
Ovahlord f1f00c3ec3 Core/Datastores: refactor DBC storage helpers to use a class and fixed no pch build 2020-03-18 15:24:25 +01:00
Ovahlord d9b854ad59 Core/Datastores: backported hotfix system implementation 2020-02-21 23:13:38 +01:00
Ovahlord 1793f39fcc Core/Movement: Allow using run when moving randomly 2020-02-18 06:32:25 +01:00
Ovahlord 1aaf004064 Core/AI: followup fixes 2020-01-31 07:34:12 +01:00
Ovahlord fcb79fee07 Core/Datastores: updated DBC structure names to generated member format 2020-01-25 12:36:32 +01:00
Ovahlord 09ebb0ed45 Core/Creatures: removed a unused argument from CanResetTalents 2020-01-13 14:50:37 +01:00
Ovahlord 0f73f8aeed Core/Creatures: the required level for resetting talents should be 10 2020-01-13 02:40:32 +01:00
Ovahlord 5ce44296d0 Core/Creature: fixed trainers not sending their gossips 2020-01-13 02:35:13 +01:00
Ovahlord 7760d95962 Core/Creatures: backported trainer update and skill initialization 2020-01-12 23:53:35 +01:00
jackpoz 131986d1c2 Core/Misc: Replace time(nullptr) with GameTime::GetGameTime() 2020-01-11 03:30:41 +01:00
Aokromes d6d3f06f06 New year 2020-01-04 18:32:38 +01:00
Giacomo Pozzoni ccb00b971b Fix fleeing speed to 66% run speed 2020-01-03 21:45:40 +01:00
funjoker 6c56916b29 Misc: Update copyright information
Happy new year
2020-01-01 18:47:28 +01:00
Ovahlord 108316ba28 Core/Creatures: added helper to check if a class trainer can train a player and use it in various places to get rid of multiple checks 2019-12-13 17:49:16 +01:00
Ovahlord 15f09fb82b Core/Misc: fixed warnings and building connection patcher with boost versions below 1.61 2019-11-06 00:51:04 +01:00
Ovahlord 1f78a55f20 Core/Creature: ported assert crashfix that fixes a focus related crash that was happening when dismissing a warlock pet while it was casting a spell 2019-09-02 00:36:34 +02:00
Treeston c597a1bcb7 Entities/Creature: Fix a bug that caused map respawn timers to be scheduled for compatibility mode creatures. 2019-08-18 13:11:37 +02:00
Treeston 90540d684b Core/Misc: Various dynspawn cleanup and refactors split off from pooling rewrite:
- Map::RemoveRespawnTime(SpawnObjectType, LowType, doRespawn) split into Map::Respawn and Map::RemoveRespawnTime, without the extra boolean
- Map::RemoveRespawnTime(RespawnInfo*) merged into Map::DeleteRespawnInfo(RespawnInfo*) and is now private
- Map::DeleteRespawnInfo(void) renamed to Map::UnloadAllRespawnInfos to properly describe what it does
- Map::ProcessRespawns now actually saves the delayed respawn time to DB if the respawn was delayed
- Map::AddRespawnInfo now takes const reference, and returns success as a boolean
- Map::AddRespawnInfo no longer offers an unused "replace" parameter
- Map::DeleteRespawnInfo no longer offers a variety of unused private overloads
- Map::SaveRespawnTime no longer offers a tantalizing writeDB parameter. Parameter is now called "startup" to properly describe what it does.
- Map::SaveRespawnInfoDB now takes RespawnInfo reference instead of all the various fields. Still public because compatibility mode. QQ.
- Map::GetWorldObjectBySpawnId sanitized
- Map::GetXRespawnTime methods sanitized to all go through Map::GetRespawnTime

----------

Core/DB: Unify `creature_respawn` and `gameobject_respawn` into a single `respawn` table
2019-08-18 12:47:10 +02:00
Treeston f9184f026b Entities/Unit: Nuke Map::ForceRespawn from orbit, with the following implications:
- .npc respawn no longer causes stupid things to happen (Fixes #23014)
- ::DeleteFromDB methods on Creature and GameObject rewritten to be as sensible as such a colossally stupid method can ever be. They're static now.
- .npc delete and .gobj delete ported to new argument handling, and rewritten as per above. They can no longer crash the server when used in instances, too. Yay for that.
- Adjusted various dusty cobwebbed hacks around the core (why does waypoint visualization use permanent spawns *shudder*) to still work too.
2019-08-18 12:12:09 +02:00
Shauren 0b8ab68eb3 Core/Map: Kill zoneId from RespawnInfo, all it did was significantly slow down startup to make one gm command faster 2019-08-18 11:51:09 +02:00
Ovahlord cbfb41f0ef Core/Creatures: fixed an edge case assert triggered by the new focus handling
(ported commit: 6590a0bfcefe7b8e5f87c82ba5ab4df2c72be418)
2019-08-13 01:28:05 +02:00
Ovahlord 4ba820d5dc Core/Spells:
* fixed releasing spell focus when a creature enters evade mode while focusing a target
* allow the focus handling to accept self cast spells
* fixed an issue that was prevent channeled spells without a cast time being rejected for focusing
* channeled spells will now always have a focus target
* target less casts will now trigger focusing as well
2019-08-11 13:57:55 +02:00
Ovahlord 148291729f Core/Spells: ported focusing rework and fixed an additional issue that was causing channeled spells getting interrupted when being cast within the focus delay release time 2019-08-10 23:43:15 +02:00
Ovahlord 7a297ccd8e Revert "Core/Creatures: updated aggro range calculation with 335 commit data"
This reverts commit 75ae86d062.
2019-07-09 10:33:31 +02:00
Ovahlord c074c3a9c6 Revert "Core/Misc: Replace time(NULL) with GameTime::GetGameTime()"
This reverts commit 5fe3a1f7f9.
2019-07-08 15:56:29 +02:00
Ovahlord 5fe3a1f7f9 Core/Misc: Replace time(NULL) with GameTime::GetGameTime()
(ported commit: 12701cb0c6c45eb105ad449eb9a56e76d84d691e)
2019-07-08 12:19:19 +02:00
Ovahlord ba38f74816 Core/Creature: fixed build 2019-07-08 09:55:18 +02:00
Treeston 83a25ce554 Entities/Creature: Some asserts are now LOG_ERRORs that block spawning. Fix a group spawning bug exposed by the CoS merge. Improve some command output.
# Conflicts:
#	src/server/game/Maps/Map.cpp
#	src/server/scripts/Commands/cs_list.cpp
2019-07-08 09:34:07 +02:00
Ovahlord 75ae86d062 Core/Creatures: updated aggro range calculation with 335 commit data 2019-07-06 15:22:28 +02:00
Wyrserth d0d7c1d51b Core/Loot: fix some other cases where a creature should not be able to set focus. (#23415) 2019-06-17 00:35:39 +02:00
Wyrserth 5bcfe49c7b Core/Creature: prevent dead creatures from setting a focus target, so they won't turn when hit by certain spells. (#23367) 2019-06-15 16:01:32 +02:00
Ovahlord 5501502a03 Core/Movement: ported some movement flag updates from master branch in order to properly fix swim movement for creatures 2019-05-30 13:14:07 +02:00
Ovahlord d8787c0d1b Core/Spells: moved updating channeled orientation for tracking channel spells to creature class 2019-05-18 01:03:28 +02:00
Ovahlord eefa94a5fe Core/Creatures: refactored sparring handling and added all data for 85% health sparring 2019-04-28 23:18:48 +02:00
Ovahlord 3d08987773 Core/Creatures: reduced a difference between 434 and 335 2019-04-27 17:36:41 +02:00
Ovahlord da25314178 Core/Objects: ported changes for the collision height changes when mounting up 2019-03-17 15:22:17 +01:00
Ovahlord 4474655779 Core/Objects: SetZoneScript will now use map zone coordinates instead of using the cached zone id 2019-02-25 00:39:28 +01:00
Ovahlord 0c358c9a0b Core/Objects: use the actual hoverheight value of creatures and players to get more accurate liquid status results 2019-02-24 23:13:50 +01:00
Ovahlord 9ce72fa1d9 Core/Creatures: Reworked setting move types in database (ported commit: 592516ae69d89da3bcb0ede144644a3d2e0186e0)
*merged followup commits
2019-02-18 07:52:25 +01:00
Ovahlord eb15db4522 Core/Movement: first part of porting the new creature hover handling 2019-02-18 01:52:15 +01:00
Ovahlord 50a91bd590 Core/Movement: merged Collision height handling from 335 branch to reduce the probability that creatures are falling under the map 2019-02-17 23:40:24 +01:00