Add a few opcodes

Add onlevelmessage encode
This commit is contained in:
KimLS
2024-12-24 14:29:51 -08:00
parent d9132e84ab
commit 45db09303f
3 changed files with 37 additions and 10 deletions
+26
View File
@@ -3269,6 +3269,32 @@ namespace Laurion
FINISH_ENCODE();
}
ENCODE(OP_OnLevelMessage)
{
EQApplicationPacket* in = *p;
*p = nullptr;
OnLevelMessage_Struct* emu = (OnLevelMessage_Struct*)in->pBuffer;
SerializeBuffer buffer;
buffer.WriteLengthString(emu->Title);
buffer.WriteLengthString(emu->Text);
buffer.WriteLengthString(emu->ButtonName0);
buffer.WriteLengthString(emu->ButtonName1);
buffer.WriteUInt8(emu->Buttons);
buffer.WriteUInt8(emu->SoundControls);
buffer.WriteUInt32(emu->Duration);
buffer.WriteUInt32(emu->PopupID);
buffer.WriteUInt32(emu->NegativeID);
buffer.WriteUInt32(0); //seen -1 & 0
buffer.WriteUInt32(0); //seen 0
auto outapp = new EQApplicationPacket(OP_OnLevelMessage, buffer.size());
outapp->WriteData(buffer.buffer(), buffer.size());
dest->FastQueuePacket(&outapp, ack_req);
delete in;
}
// DECODE methods
DECODE(OP_EnterWorld)
+1
View File
@@ -49,6 +49,7 @@ E(OP_RemoveBlockedBuffs)
E(OP_ZonePlayerToBind)
E(OP_Illusion)
E(OP_MoneyOnCorpse)
E(OP_OnLevelMessage)
//list of packets we need to decode on the way in:
D(OP_EnterWorld)
D(OP_ZoneEntry)