aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Events/GameEventMgr.cpp
AgeCommit message (Collapse)Author
5 daysCore/GameEvents: Added holiday/event world state field (#31284)Meji
Closes #30622
2025-09-08Core/Events: Replace remaining packed time calculations with WowTime classShauren
2025-07-13Core/Misc: Move large functions out of header filesShauren
2023-11-26Core/Creatures: Don't require `creature`.`modelid` to be one of linked ↵Shauren
`creature_template` models
2023-08-26Core/Battlegrounds: Rework queues (#29200)Jeremy
* No more copies of Battleground classes * FreesSlotQueues now have as key the MapId instead of queue id * Random queues can now popup already busy specific battelgrounds (queues are NOT merged) * Removed Holiday handling, this should already be handled in BattlegroundMgr::IsBGWeekend
2023-03-30Core/Creatures: Compute CombatReach and BoundingRadius using DisplayScale ↵Meji
(#28863)
2023-01-08Core/Logging: Switch from fmt::sprintf to fmt::format (c++20 standard ↵Shauren
compatible api)
2022-07-24Core/Maps: Removed MapInstanced - no longer neccessary for grid data ↵Shauren
reference counting (moved to TerrainInfo)
2022-07-11Core/WorldStates: Migrate battleground HolidayWorldState to new systemShauren
2022-07-03Core/Quests: Reset seasonal quests based on saved completion time and ↵Shauren
intended holiday start time
2022-07-03Revert "Core/Event: prevent seasonal quests from resetting at server restart ↵Shauren
(#17455)" This reverts commit 6a8ca9b0bf6f7cd355e1994723d6be6a5003d4d4.
2022-06-11Core/Pools: Implemented pooling for instancesShauren
2022-06-09Core/GameEventMgr: Spawn creatures and gameobjects in all active instances ↵Shauren
when event starts
2022-03-26Core/Misc: Rename SetXXXFlags updatefield functions to ReplaceAllXXXFlagsShauren
2022-02-04Core/Common: Tokenizer -> Trinity::Tokenize (PR: #25327)Treeston
(cherry picked from commit 534a2388b7c662c8796aabb1ec8cb424879799b6)
2022-01-21Core/Events: refactored battleground holiday assignments.Ovahlord
Instead of going with shitty bitmasks we now accept plain battleground ids instead (cherry picked from commit 8a82403400ef49415e14530f4b55d55ef38bc74e)
2022-01-01Core/Pools: Fix crash on startupjackpoz
(cherry picked from commit 9cde3ffd1404e784406f385061f4df0f6b429b61)
2021-12-28Core/Phasing: Implemented db spawns in personal phases (#26345)Matan Shukry
Co-authored-by: Shauren <shauren.trinity@gmail.com>
2021-12-21Core/Misc: Some refactoring, #23603 prep: (#23676)Treeston
- Split SpawnMetadata off from SpawnData - No longer allocate Creature/Gameobject objects in ObjectGridLoader just to check their typeid and delete them afterwards Co-authored-by: Giacomo Pozzoni <giacomopoz@gmail.com> (cherry picked from commit 9304e496cbf6ab6c028671fb8526c732ae5d799f)
2021-12-18Core/Pooling: Quest pooling rewrite: (PR#23627)Treeston
- Split quest pooling from PoolMgr (into QuestPoolMgr) - Proper saving/restoring on server restart - No more hacking into sObjectMgr to insert/remove available quests (cherry picked from commit a5e73e41c0e813e674bb0a644e0052052435494e)
2021-12-17Core/GameEvent: Fix OnGameEvent() hook not being called on ↵jackpoz
Creature/GameObject spawned by the event itself Hook broken since it was added in 1b2c413933f19aec82371a5b55cba9c3b3ded43a (cherry picked from commit d9ae19d974a8026b0fd4eb8b1d11fa59c758f5d1)
2021-12-113.3.5 game event respawn (#23391)Giacomo Pozzoni
* Core/GameEvent: Remove respawn times of Creature and GameObjects when starting/stopping an event * Add checks for pool * Remove the check for pools (cherry picked from commit 678f3dd687432b4229d903a8acfb882c2336e168)
2021-11-26Core/GameEventMgr: Log error if loading GO/Creature into event that is part ↵r00ty-tc
of pool - Only warn, still load the GO/Creature - These should be added to game_event_pool by pool ID instead (cherry picked from commit 8bb88657f823b3e5446e250a48a2846abb10f023)
2021-10-22Core/AI: Clean up charm AI handling, we now have two unique_ptr instead of a ↵Treeston
crapton of booleans (cherry picked from commit 042f5515e4f3e52b0d2e23d9b9e147041849ce12)
2021-06-22Core/Events: update holiday code and remove misleading log (event date is ↵ariel-
the one from game_event) - add siign to DBC struct member CalendarFilterType as it was being used as such - kill localtime usage as it's deprecated Closes #18542 (cherry picked from commit 5b4287e6832da32539a49e68f6a5ab0ee55854b3)
2021-04-15Core/Misc: Replace time(NULL) with GameTime::GetGameTime()jackpoz
(cherry picked from commit 12701cb0c6c45eb105ad449eb9a56e76d84d691e) Conflicts: src/server/game/Achievements/AchievementMgr.cpp src/server/game/AuctionHouse/AuctionHouseMgr.cpp src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp src/server/game/AuctionHouseBot/AuctionHouseBotSeller.cpp src/server/game/Battlefield/Battlefield.cpp src/server/game/Battlefield/Zones/BattlefieldWG.cpp src/server/game/Battlegrounds/BattlegroundMgr.cpp src/server/game/Calendar/CalendarMgr.h src/server/game/DungeonFinding/LFGQueue.cpp src/server/game/Entities/Corpse/Corpse.cpp src/server/game/Entities/Creature/Creature.cpp src/server/game/Entities/Item/Item.cpp src/server/game/Entities/Pet/Pet.cpp src/server/game/Entities/Player/Player.cpp src/server/game/Entities/Unit/Unit.cpp src/server/game/Globals/ObjectMgr.cpp src/server/game/Grids/ObjectGridLoader.cpp src/server/game/Guilds/Guild.cpp src/server/game/Handlers/AuctionHouseHandler.cpp src/server/game/Handlers/BattlefieldHandler.cpp src/server/game/Handlers/CalendarHandler.cpp src/server/game/Handlers/CharacterHandler.cpp src/server/game/Handlers/ChatHandler.cpp src/server/game/Handlers/LFGHandler.cpp src/server/game/Handlers/MailHandler.cpp src/server/game/Handlers/MiscHandler.cpp src/server/game/Handlers/MovementHandler.cpp src/server/game/Handlers/PetHandler.cpp src/server/game/Handlers/QueryHandler.cpp src/server/game/Handlers/TicketHandler.cpp src/server/game/Instances/InstanceSaveMgr.cpp src/server/game/Server/WorldSession.cpp src/server/game/Server/WorldSocket.cpp src/server/game/Spells/Auras/SpellAuras.cpp src/server/game/Tickets/TicketMgr.cpp src/server/game/Tickets/TicketMgr.h src/server/game/World/World.cpp src/server/scripts/Commands/cs_gobject.cpp src/server/scripts/Commands/cs_instance.cpp src/server/scripts/Commands/cs_list.cpp src/server/scripts/Northrend/zone_wintergrasp.cpp src/server/scripts/Spells/spell_item.cpp
2021-04-15Core/Globals: validate creature_template mingold and maxgold fieldsariel-
(cherry picked from commit 5798fda0a027c1199ea4ddd50f5567cf24c74c5b)
2021-04-05Core/Misc: Change all unix time columns in character database to bigint (signed)Shauren
2021-03-15Core/Misc: minor typo and codestyle fixesariel-
- Replace NULL uses in new code with nullptr - Fix wrong (accumulated) load time log when loading calendar invites - Make Creature::CanRegenerateHealth const as its just a getter - Mark OnlyOnceAreaTriggerScript::OnTrigger as final in case someone wants to override that (you are supposed to use protected _OnTrigger hook) (cherry picked from commit 78a1c687a25d91dd6b13251f28d03ec6a0a49b8a)
2021-02-25Core/Misc: Fix static analysis issuesjackpoz
Fix static analysis issues reported by 3rd party tools (cherry picked from commit 24e82fe83d384e3a4cf17719e728760053516607)
2021-02-25Core/Misc: Fix static analysis issuesjackpoz
Fix coverity id 1382860 (cherry picked from commit 19e99478a70515660615fa8c9d27c7b9581d3098)
2021-01-21Core/Logs: Fix more logsAokromes
the others have exit,so they continue to be error because they are critical (cherry picked from commit b68484cfb0c371dc8de24acf533a20cb5277d2fd)
2021-01-21Calendar/GameEvents: Store + send holiday data (#20117)Gerhood
Close: #16845 (cherry picked from commit 951fa46fe9b14a9e275ac9306b2346959e40e3e5)
2020-09-04Core/Misc: Port all the refactors sneaked in master to 3.3.5 include cleanup ↵Shauren
port
2020-08-22Dynamic Creature/Go spawning:r00ty-tc
- True blizzlike creature spawn/respawn behavior - new creature = new object - Toggleable spawn groups (with C++/SAI/command options to use them) - Custom feature: dynamic spawn rate scaling. Accelerates respawn rate based on players in the zone. - Backward compatibility mode (set via group and for summons) to support creatures/gos that currently don't work well with this (this should be removed once the exceptions are fixed) Fixes and closes #2858 Tags #8661 as fixable. Fixes and closes #13787 Fixes #15222. (cherry picked from commit 59db2eeea0a35028779fd76372ae06cc98c8086f)
2020-08-14Core/Misc: Replace NULL with nullptrShauren
2020-07-18Core/Maps: Use FindMap instead of CreateBaseMap in places where the intent ↵Shauren
was to check for a existing map (and a loaded grid on that map)
2020-05-03Core/Scripts: unified scripted gossip/quest apiariel-
- Changed self-accessor on GameObjectAI to "me", like UnitAI - Moved all related functions to AI, now Unit and GameObject have the same function names with identical behaviour - Remove "OnUpdate" from CreatureScript/GameObjectScript, was never used and we already have AI Update method - Quest methods no longer return a bool, the return value was used to call the AI version if the ScriptMgr one returned false - Implemented GameObjectAI::Destroyed hook (was never called), implemented Damaged method - Rename OnStateChanged to OnLootStateChanged to reflect when it's really called, and created a new hook OnStateChanged that only gets called on GOState change - Since the functions are now only getting called from AI, made GetAI methods full virtual. (CanSpawn method is anyways going to be used on creatures with AI) (cherry picked from commit f913f3bb8977c127d200d5d4a608ab434b21bbcd)
2020-01-02New YearAokromes
2019-07-27Core/DBLayer: Prevent committing transactions started on a different databaseShauren
2019-07-27Core/DBLayer: Prevent using prepared statements on wrong databaseShauren
2019-07-21Few small optimizations here and there (#18684)xinef1
Changes list: - Added CharacterGuidByNameContainer which contains name -> guid unordered map (updated along CharacterInfo) - Extended CharacterInfo structure with GuildId - Extended CharacterInfo structure with ArenaTeamId[3], for all possible teams (2v2, 3v3, 5v5) - Removed CHAR_SEL_GUID_BY_NAME and CHAR_SEL_CHAR_GUID_BY_NAME synchronous queries, name -> guid can be now retrieved in World::GetCharacterGuidByName - Removed CHAR_SEL_GUID_RACE_ACC_BY_NAME synchronous query, guid can be retrieved by name and rest of the data can be retrieved by guid - Removed CHAR_SEL_CHAR_LEVEL synchronous query, level can be retrieved by guid - Changed CHAR_SEL_CHARACTER_ACTIONS_SPEC to asynchronous query, action bars are now loaded asynchronously - Removed CHAR_SEL_CHARACTER_NAME_CLASS synchronous query, guid can be retrieved by name and rest of the data can be retrieved by guid - Removed CHAR_SEL_PLAYER_ARENA_TEAMS and CHAR_SEL_ARENA_TEAM_ID_BY_PLAYER_GUID synchronous queries, arena teams are now stored in CharacterInfo - Replaced synchronous db calls with CharacterInfo lookups - Removed ObjectMgr::GetPlayerGUIDByName, as it used db query - Replaced some unnecessary UpdateObjectVisibility() calls because they were either duplicated (called few lines above in other function) or it is enough to call DestroyForNearbyPlayers because object is being removed or should be invisible and DestroyForNearbyPlayers is faster - Corrected typo in Player::DestroyForPlayer, only items in slots 0 to EQUIPMENT_SLOT_END are sent to other players - Renamed Player::GetGuildIdFromDB to Player::GetGuildIdFromCharacterInfo and changed the function to use CharacterInfo structure - Renamed Player::GetArenaTeamIdFromDB to Player::GetArenaTeamIdFromCharacterInfo and changed the function to use CharacterInfo structure - Renamed Player::GetLevelFromDB to Player::GetLevelFromCharacterInfo and changed the function to use CharacterInfo structure - Removed GameEventMgr::_questToEventLinks and associated functions, eventId is now stored in Quest class under _eventIdForQuest variable - Changed some functions checking quest status to use other functions for quest status check instead of duplicating code - Removed callback from add friend, because we can get the guid from appropriate storage, no need to make db query - Removed callback from add ignore, because we can get the guid from appropriate storage, no need to make db query - Added callback to unwrap wrapped items asynchronously - Removed synchronous select in tutorials to check if we have any entries in db, if any entry exists in db, m_TutorialsChanged variable will have TUTORIALS_FLAG_LOADED_FROM_DB flag added and it is no longer necessary to query database (cherrypicked from b955456008191e60b6bda1f22e3486a3792b08db)
2019-06-08Core/PacketIO: Rewrite updatefield handlingShauren
2019-01-01Update copyright note for 2019vincent-michael
auto happy = new year(2019);
2018-01-27Core/Entities: Created factory methods to create new areatriggers, creatures ↵joschiwald
and gameobjects
2018-01-01Update copyright note for 2018vincent-michael
auto happy = new year(2018);
2017-10-09Core/Creature: Refactor and improve vendor items (#20328)Roc13x
* Implement item bonuses in vendors. * Implement the PlayerConditionID and IgnoreFiltering DB columns. * Fix loading referenced vendor items * Allow adding bonuses in .npc add item command
2017-06-04Core/Game: Include cleanup part 5Shauren
* ObjectMgr.h * Player.h * Unit.h * G3D should no longer propagate everywhere from Spline/MotionMaster
2017-05-18Core/Game: Include cleanupShauren
* Mostly aimed at removing Log/DatabaseEnv includes from other headers * Fix most packet headers including other packet headers - moved common structures such as ItemInstance to their own files * Moved SAI function definitions to source files (massive or requiring many different dependencies)
2017-02-18Core/Event: prevent seasonal quests from resetting at server restart (#17455)SnapperRy
Closes #16015. Closes #16413. (cherry picked from commit fb6d4dd98f66ec67f7c5ddf698b3e6a0b44925b4)