refactor(Core/World): Move SendGMText to ChatHandler and allow fmt (#19490)

* refactor(Core/World): Move SendGMText to WorldSession and allow `fmt`

- Move SendGMText from World to WorldSession

- Make SendGMText use fmt

- Make SendGMText parse acore_string entries

* Update cs_message.cpp

* tokenize the string only once

* Move to chathandler

* Update WorldSession.cpp

* make sure we have a session
This commit is contained in:
Kitzunu
2024-08-09 01:12:33 +02:00
committed by GitHub
parent fdd8ff6e04
commit bb7765d91e
9 changed files with 53 additions and 35 deletions

View File

@@ -72,7 +72,6 @@ public:
MOCK_METHOD(uint16, GetConfigMaxSkillValue, (), (const));
MOCK_METHOD(void, SetInitialWorldSettings, ());
MOCK_METHOD(void, LoadConfigSettings, (bool reload), ());
void SendGMText(uint32 string_id, ...) override {}
MOCK_METHOD(void, SendGlobalMessage, (WorldPacket const* packet, WorldSession* self, TeamId teamId), ());
MOCK_METHOD(void, SendGlobalGMMessage, (WorldPacket const* packet, WorldSession* self, TeamId teamId), ());
MOCK_METHOD(bool, SendZoneMessage, (uint32 zone, WorldPacket const* packet, WorldSession* self, TeamId teamId), ());