Refactor client cross zone message helpers

Remove extra cross zone message server opcode and struct. Existing
function already exists for normal messages

Group CZClientMessageString struct with other CZ structs
This commit is contained in:
hg committed 2020-12-30 18:47:09 -05:00
1 parent e99528fe73
commit 184ea679f2
9 files changed
+54 -75

No files matched your search

+1 -10
View File
@@ -2881,18 +2881,9 @@ void WorldServer::HandleMessage(uint16 opcode, const EQ::Net::Packet &p)
}
break;
}
case ServerOP_CZClientMessage:
{
auto buf = reinterpret_cast<ServerCZClientMessage_Struct*>(pack->pBuffer);
Client* client = entity_list.GetClientByName(buf->character_name);
if (client) {
client->Message(buf->chat_type, buf->message);
}
break;
}
case ServerOP_CZClientMessageString:
{
auto buf = reinterpret_cast<ServerCZClientMessageString_Struct*>(pack->pBuffer);
auto buf = reinterpret_cast<CZClientMessageString_Struct*>(pack->pBuffer);
Client* client = entity_list.GetClientByName(buf->character_name);
if (client) {
client->MessageString(buf);