feat: proper gminvs with ghosting (#1920)

* feat: proper gminvis ghosting

* address feedback

---------

Co-authored-by: David Markowitz <39972741+EmosewaMC@users.noreply.github.com>
This commit is contained in:
Aaron Kimbrell
2025-11-15 18:43:33 -06:00
committed by GitHub
parent 2fb16420f3
commit 11d44ffb98
9 changed files with 116 additions and 49 deletions

View File

@@ -1847,18 +1847,6 @@ void GameMessages::SendNotifyClientFailedPrecondition(LWOOBJID objectId, const S
SEND_PACKET;
}
void GameMessages::SendToggleGMInvis(LWOOBJID objectId, bool enabled, const SystemAddress& sysAddr) {
CBITSTREAM;
CMSGHEADER;
bitStream.Write(objectId);
bitStream.Write(MessageType::Game::TOGGLE_GM_INVIS);
bitStream.Write(enabled); // does not matter?
if (sysAddr == UNASSIGNED_SYSTEM_ADDRESS) SEND_PACKET_BROADCAST;
SEND_PACKET;
}
void GameMessages::SendSetName(LWOOBJID objectID, std::u16string name, const SystemAddress& sysAddr) {
CBITSTREAM;
CMSGHEADER;
@@ -6449,4 +6437,8 @@ namespace GameMessages {
stream.Write(lootID);
stream.Write(lootOwnerID);
}
void ToggleGMInvis::Serialize(RakNet::BitStream& stream) const {
stream.Write(bStateOut);
}
}