From 72c438d0a56e1d8fb1864feb8aeeba572b4ad199 Mon Sep 17 00:00:00 2001 From: RD42 <42702181+dashr9230@users.noreply.github.com> Date: Sat, 21 Sep 2024 22:23:09 +0800 Subject: [PATCH] [server] Implement/match ` CGangZonePool::HideForPlayer((...)` --- server/gangzonepool.cpp | 7 +++++++ server/gangzonepool.h | 1 + 2 files changed, 8 insertions(+) diff --git a/server/gangzonepool.cpp b/server/gangzonepool.cpp index a59cffa..8d5978b 100644 --- a/server/gangzonepool.cpp +++ b/server/gangzonepool.cpp @@ -64,3 +64,10 @@ void CGangZonePool::ShowForAll(WORD wZone, DWORD dwColor) pNetGame->BroadcastData(RPC_ScrAddGangZone, &bsParams, INVALID_PLAYER_ID, 2); } +void CGangZonePool::HideForPlayer(PLAYERID playerId, WORD wZone) +{ + RakNet::BitStream bsParams; + bsParams.Write(wZone); + pNetGame->SendToPlayer(RPC_ScrRemoveGangZone, &bsParams, playerId, 2); +} + diff --git a/server/gangzonepool.h b/server/gangzonepool.h index 619d5d9..ae8b522 100644 --- a/server/gangzonepool.h +++ b/server/gangzonepool.h @@ -16,6 +16,7 @@ public: void Delete(WORD wZone); void ShowForPlayer(PLAYERID playerId, WORD wZone, DWORD dwColor); void ShowForAll(WORD wZone, DWORD dwColor); + void HideForPlayer(PLAYERID playerId, WORD wZone); }; //----------------------------------------------------