Commit Graph

474 Commits

Author SHA1 Message Date
antony
4a48e18d5b Playerbot fixes and functionnality to talk in channels 2024-07-26 11:34:32 +02:00
Yunfan Li
5276676a11 Merge branch 'master' into Playerbot 2024-07-24 20:57:52 +08:00
Kitzunu
3fbded8f6b refactor(Core/Chat): PSendSysMessage to fmt (#19449)
* refactor(Core/Chat): PSendSysMessage to `fmt`
2024-07-23 23:48:46 +02:00
Yunfan Li
1f54cb14fa Merge branch 'master' into Playerbot 2024-07-07 13:33:14 +08:00
Kitzunu
3c50b1a135 fix(Core/Player): Vertical Message distance (#19302)
* cherry-pick commit (297541e9c9)

* Get rid of unused param

* Merge SendMessageToSetInRange_OwnTeam into SendMessageToSetInRange

Co-authored-by: Badgersson <83663557+dekz120@users.noreply.github.com>
2024-07-06 10:05:34 -03:00
Kitzunu
385d7fd515 chore(Core/DBC): define unused unknown dbc fields (#19262)
* chore(Core/DBC): define unused unknown dbc fields

* Name unused unknown dbc fields using WDBX and wowdev.wiki

* rename SpellShapeshiftEntry to SpellShapeshiftFormEntry to properly match the DBC used

* rename sSpellShapeshiftStore to sSpellShapeshiftFormStore to properly match the DBC used

* Comment out unused field for GlyphPropertiesEntry

* Comment out unused field for MapEntry

* forgot one

* SpellShapeshiftfmt to SpellShapeshiftFormfmt

* SpellShapeshiftFormEntryfmt
2024-07-04 14:23:25 -03:00
Yunfan Li
cc5adebbe4 Merge branch 'master' into Playerbot 2024-07-03 16:04:51 +08:00
Kitzunu
f96d4c8670 Revert "Add (core\db): Support for Homebind Orientation (#13389)" (#19257)
* Revert "Add (core\db): Support for Homebind Orientation (#13389)"

This reverts commit 2e6f6e26da.

 Changes to be committed:
	modified:   src/server/database/Database/Implementation/CharacterDatabase.cpp
	modified:   src/server/game/DungeonFinding/LFGScripts.cpp
	modified:   src/server/game/Entities/Player/Player.cpp
	modified:   src/server/game/Entities/Player/Player.h
	modified:   src/server/game/Entities/Player/PlayerStorage.cpp
	modified:   src/server/game/Entities/Player/PlayerUpdates.cpp
	modified:   src/server/game/Handlers/CharacterHandler.cpp
	modified:   src/server/game/Handlers/MiscHandler.cpp
	modified:   src/server/game/Handlers/MovementHandler.cpp
	modified:   src/server/game/Maps/Map.cpp
	modified:   src/server/game/Spells/Spell.cpp
	modified:   src/server/scripts/Commands/cs_misc.cpp
	modified:   src/server/scripts/Commands/cs_tele.cpp
	modified:   src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp

 Untracked files:
	data/sql/updates/pending_db_world/rev_1719945200692175000.sql

* Revert "Add (core\db): Support for Homebind Orientation (#13389)"

* whoops
2024-07-02 22:02:15 +02:00
Yunfan Li
72634b2829 Merge branch 'master' into Playerbot 2024-06-07 22:28:03 +08:00
Kitzunu
744067b389 fix(Core/Player): Delete by group (#19015)
* fix(Core/Player): Delete by group

* closes https://github.com/azerothcore/azerothcore-wotlk/issues/19014

Co-Authored-By: trickerer <onlysuffering@gmail.com>

* Update Player.cpp

* fix build

---------

Co-authored-by: trickerer <onlysuffering@gmail.com>
2024-06-06 20:58:43 +02:00
Yunfan Li
971b2f8316 Merge branch 'master' into Playerbot 2024-06-03 23:16:28 +08:00
Andrew
2a1d23e520 fix(Scripts/Hyjal): Implement Eternal Silence spell when going into t… (#18960)
fix(Scripts/Hyjal): Implement Eternal Silence spell when going into the Well of Eternity
2024-05-28 01:24:10 +02:00
Yunfan Li
1e22c4dc94 Merge branch 'master' into Playerbot 2024-05-26 23:00:39 +08:00
silviu20092
3988e9581d feat(core): add hooks for applying item mods (#18760) 2024-05-18 10:02:57 +02:00
Yunfan Li
f0be01a5d7 Merge branch 'master' into Playerbot 2024-04-07 21:49:34 +08:00
Anton Popovichenko
f7f1952f4b fix(Core/Player): Fix memory leak. (#18671) 2024-04-05 07:04:55 -03:00
Anton Popovichenko
1f640c9872 feat(Core/Optimization): Optimize build of units update object by leveraging cache (#18637)
* feat(Core/Optimization): Optimize build of units update object by leveraging cache.

* Remove whitespaces.

* Add alternative hooks to handle transmog and other similar things.

* Fix build on some compilers.

* Fix codestyle

* Fix build again.

* Take into account updateType.
2024-04-05 08:03:11 +02:00
Anton Popovichenko
47f9d66874 feat(Core/Optimization): Create index for sSkillLineAbilityStore to speedup search by skillLine. (#18622)
* feat(Core/Optimization): Create index for sSkillLineAbilityStore to speedup search by skillLine.

* Remove whitespace.
2024-04-01 05:50:12 -03:00
Yunfan Li
97604fab77 Merge branch 'master' into Playerbot 2024-03-22 20:41:43 +08:00
Mykhailo Redko
33f951d742 fix(Core/Spells): Fixed work of sobering spells and other improvements for drunk system (#18390)
* fix(Core/Spells): Fix sobering spells and possible uint8 overflow/underflow in SPELL_EFFECT_INEBRIATE handler.

* fix(Core/Spells): Improvements for SPELL_AURA_MOD_FAKE_INEBRIATE handling
2024-03-20 01:45:01 -03:00
Yunfan Li
5699c97d8c Merge branch 'master' into Playerbot 2024-02-11 23:45:22 +08:00
Nathan Handley
df33a57b78 feat(Core/Unit): New helper IsClass and script hook OnPlayerIsClass (#18243)
* Class Comparison Logic Encapsulation - Parity

* Add Context to IsClass

* Add Unit IsClass script hook

* Replace additional getClass with IsClass

* Update CanUseItem to replace getClass with IsClass

* Add separate context for pet vs ability

* Change Create to Init since not all referenced contexts are creation

* Align spacing in ClassContext

* Drop context on LFGManager max power

* Update IsClass context that wraps around Missle Barrage

* Rename context for swapping weapons

* Be more specific than CLASS_CONTEXT_TALENT

* Remove duplicate context

* Moved IsClass Hook to Player

* Removed unused parameter in virtual base function

* Added maybe_unused to IsClass virtual in order to compile

To match the override signature, the virtual base needs to include the parameter in question, so using [maybe_unused] to signal to the compiler to allow it

* Remove extra blank line

* Add ABILITY_REACTIVE context

* Add context for PET_CHARM

* Remove explicit nullopt check per review

* Code Readability - Change if to if else in pet

Due to the return pattern, this doesn't change functionality in any way

* Add OnPlayer to disambiguate

---------

Co-authored-by: NathanHandley <nathanhandley@protonmail.com>
2024-02-10 12:25:00 -03:00
Nathan Handley
425a490a7b feat(Core/Unit): New helper HasActivePowerType and script hook OnPlayerHasActivePowerType (#18293)
* Create HasActivePower for script intercept

* Replace relevant player-related getPowerType() comparators with HasActivePowerType

* Change OnPlayerHasActivePowerType to regular bool instead of optional

---------

Co-authored-by: NathanHandley <nathanhandley@protonmail.com>
2024-02-09 06:27:02 -03:00
Yunfan Li
9e172c9113 Merge branch 'master' into Playerbot 2024-01-15 21:00:38 +08:00
sudlud
1785df7117 fix(Core/Player): Fix Player not starting at full health (#18136)
* fix(Core/Player): Fix Player not starting at full health

* remove first call to UpdateMaxHealth() and SetFullHealth()
2024-01-14 11:07:52 -03:00
Yunfan Li
600b0873e7 Merge branch 'master' into Playerbot 2024-01-08 23:30:50 +08:00
Kitzunu
bceb6173c2 fix(Core/Player): Sometimes Player whisper is sent as boss whisper (#18128)
* fix(Core/Player): Sometimes Player emot is sent as boss whisper

* actually change it to whisper as it is boss whisper

* Update Player.cpp
2024-01-07 12:14:20 -03:00
Yunfan Li
ccf92f481d Merge branch 'master' into Playerbot 2024-01-04 19:22:20 +08:00
Kitzunu
6202835cff fix(Core/LFG): Hide XP from max players (#18103)
* Cherry-pick Player::IsMaxLevel from TrinityCore
* Correctly hide XP reward for max level players in LFG
* Closes #18101
2024-01-03 19:47:26 +01:00
Andrew
f9f71fff36 fix(Core/Player): Check if the player can summon the warlock pet on B… (#18064)
fix(Core/Player): Check if the player can summon the warlock pet on BG ress
2024-01-01 14:56:32 +01:00
Yunfan Li
7915f79d04 Merge branch 'master' into Playerbot 2023-12-12 20:52:42 +08:00
IntelligentQuantum
9f1abf1214 chore(Core/Entities): remove useless includes (#17994) 2023-12-12 01:36:35 -03:00
avarishd
f476c8a6c9 feat(Core/Hooks): Add OnPlayerJustDied hook (#17973)
feat(Core/Hooks): Add OnPlayerJustDied
2023-12-10 19:06:23 -03:00
Tristan 'Natrist' Cormier
ac676f87ab chore(Core/Player): remove unused AnticheatSetSkipOnePacketForASH() function (#17947) 2023-12-09 01:09:52 +01:00
Tristan 'Natrist' Cormier
4c94f62144 chore(Core/Account): move AccountMgr::IsGMAccount() to class WorldSession (#17845) 2023-11-28 21:44:48 +01:00
Kitzunu
f440a7479f fix(Core/Groups): Create the group at first invite (#17869)
* cherry-pick commit (132538db1d)
* cherry-pick commit (250e8d998b)
* part https://github.com/azerothcore/azerothcore-wotlk/issues/11070

Co-authored-by: Treeston <14020072+Treeston@users.noreply.github.com>
2023-11-26 20:34:45 +01:00
Winfidonarleyan
e90d7a2f92 chore(Core/Misc): sort includes (#17776)
* chore(Cleanup): sort includes

* fix build

* fix build again
2023-11-18 17:51:26 +01:00
Kitzunu
bbadc32bea Revert Visibility Notifier changes (#17682)
* Revert "fix(Core/Grid): Implement missing GridUnload setting (#17569)"

This reverts commit 79b39f9655.

* Revert "fix(Core/Grid): Address bugs and performance issues introduced by visibility notifier implementation (#17480)"

This reverts commit 60e27511c5.

* Revert "fix(Core): GridCleanUpDelay Log (#17436)"

This reverts commit 90b16ca065.

* Revert "feat(Core/Grids): Implement visibility notifier (#15919)"

This reverts commit 2779833768.
2023-11-12 00:48:49 +01:00
KJack
f417a166bc feat(Core/Scripts): added OnAfterSpecSlotChanged hook (#17637) 2023-11-07 23:46:08 +07:00
Kitzunu
f757e93da5 refactor(Core/Misc): Make DeathState enum class (#17607) 2023-10-28 10:54:03 +02:00
Yunfan Li
d879fc9258 Merge branch 'master' into Playerbot 2023-10-27 20:12:09 +08:00
AG
60e27511c5 fix(Core/Grid): Address bugs and performance issues introduced by visibility notifier implementation (#17480)
* Bug fixes

- Corrected std::chrono from seconds to milliseconds
- Got rid of leftover code that caused objects to not show up on time

* Removed logic to set gameobject as active

- More alignement with TC.
- Reduces CPU usage drastically

* Revert back to using time_t instead of std chrono

* Invoke SetNoCreate() method to reduce CPU usage drastically

* Remove setActive from static and motion transports

* Fix performance issues

* Added SetFarVisible to WG and some dungeon scripts

- Also removed setActive(true) from creatures in Wintergrasp. As for gameobjects they are set to active upon being damaged/destroyed and removed from active on rebuild (reset)

* Removed comments related to VISIBILITY_COMPENSATION

* Fix log

* Deleted unused files + corrected a check

* Added missing header

* Removed unused parameter

* Removed another unsued parameter

* Changed vector to set for i_visibleNow

- Changed vector to set for i_visibleNow in VisibleNotifer
- Adjusted HaveAtClient to accept Object*
- Adjusted SendUpdateToPlayer to send createobject packet only if not known to client
2023-10-23 05:37:11 -03:00
Yunfan Li
57e0c7a09f Merge branch 'master' of github.com:azerothcore/azerothcore-wotlk into Playerbot 2023-10-22 19:52:23 +08:00
Hasn
5bf64a164a fix(Core/Player) Stop small durability loss from still occuring when DurabilityLoss options in worldserver.conf are set to 0 (#17407)
Fix durability loss even when "DurabilityLoss"-settings in
worldserver.conf are zeroed
2023-10-21 08:10:34 -03:00
Kitzunu
a4e4d6ddb2 feat(Core/Player): Implement commentator tag (#17449)
* feat(Core/Player): Implement commentator tag

* remove redundant session check
2023-10-08 09:07:17 +02:00
Yunfan Li
2dd1490c18 Merge branch 'master' of github.com:azerothcore/azerothcore-wotlk into Playerbot 2023-09-23 22:44:15 +08:00
Ludwig
f633eb8592 fix(Core/Achivement): Implement ACHIEVEMENT_FLAG_AVERAGE (#17263) 2023-09-21 18:56:28 +02:00
Tralenor
0796df57ac feat(Core/Player): Addition of a Hook in CanFlyInZone check (#16590)
---------

Co-authored-by: tmoos <tmoos@meteomatics.com>
Co-authored-by: Winfidonarleyan <dowlandtop@yandex.com>
Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>
2023-09-20 22:40:08 +02:00
Ludwig
8ba8f0fe9e fix(Core/Achievement): Implement ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK (#17180)
* fix(Core): Implement ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK

* fix(Core): LoadAchievementCriteriaData(): Add ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK

- fixes minor oversight of ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK implementation
- this enables DB achievement_criteria_data check for ACHIEVEMENT_CRITERIA_TYPE_OWN_RANK
2023-09-14 22:27:39 +02:00
Skjalf
8d08a861aa feat(Core/Scripting): Implement OnAllowedToLootContainerCheck() hook (#17209)
* chore(Core/Loot): Move OnAllowedForPlayerLootCheck() hook call up

* Revert "chore(Core/Loot): Move OnAllowedForPlayerLootCheck() hook call up"

This reverts commit f841ef9da313976179fb788d9573ff8ced05ecb9.

* feat(Core/Scripting): Implement OnAllowedToLootContainerCheck() hook

* Update GlobalScript.cpp
2023-09-08 01:52:02 -03:00