mirror of
https://github.com/dashr9230/SA-MP.git
synced 2026-10-10 11:43:04 +08:00
[saco] Implement/match ScrShowMenu and ScrHideMenu; CNetGame::GetMenuPool is an inline, not an out-of-line call
This commit is contained in:
+1
-1
@@ -105,7 +105,7 @@ public:
|
||||
void SetMapIcon(BYTE byteIndex, float fX, float fY, float fZ, BYTE byteIcon, DWORD dwColor, int iStyle);
|
||||
void DisableMapIcon(BYTE byteIndex);
|
||||
|
||||
CMenuPool * GetMenuPool(); // .text:100084F0
|
||||
CMenuPool * GetMenuPool() { return m_pPools->pMenuPool; }; // .text:100084F0
|
||||
int ToggleNameTagStatus(); // .text:10008E90
|
||||
void sub_1000A540(); // .text:1000A540
|
||||
};
|
||||
|
||||
+30
-2
@@ -350,8 +350,36 @@ void ScrUnkB0(RPCParameters *rpcParams) {}
|
||||
void ScrUnkB2(RPCParameters *rpcParams) {}
|
||||
void ScrUnk30(RPCParameters *rpcParams) {}
|
||||
void ScrInitMenu(RPCParameters *rpcParams) {}
|
||||
void ScrShowMenu(RPCParameters *rpcParams) {}
|
||||
void ScrHideMenu(RPCParameters *rpcParams) {}
|
||||
void ScrShowMenu(RPCParameters *rpcParams)
|
||||
{
|
||||
PCHAR Data = reinterpret_cast<PCHAR>(rpcParams->input);
|
||||
int iBitLength = rpcParams->numberOfBitsOfData;
|
||||
PlayerID sender = rpcParams->sender;
|
||||
|
||||
BYTE byteMenuID;
|
||||
|
||||
RakNet::BitStream bsData(Data,(iBitLength/8)+1,false);
|
||||
|
||||
if(!pNetGame) return;
|
||||
|
||||
bsData.Read(byteMenuID);
|
||||
pNetGame->GetMenuPool()->ShowMenu(byteMenuID);
|
||||
}
|
||||
void ScrHideMenu(RPCParameters *rpcParams)
|
||||
{
|
||||
PCHAR Data = reinterpret_cast<PCHAR>(rpcParams->input);
|
||||
int iBitLength = rpcParams->numberOfBitsOfData;
|
||||
PlayerID sender = rpcParams->sender;
|
||||
|
||||
BYTE byteMenuID;
|
||||
|
||||
RakNet::BitStream bsData(Data,(iBitLength/8)+1,false);
|
||||
|
||||
if(!pNetGame) return;
|
||||
|
||||
bsData.Read(byteMenuID);
|
||||
pNetGame->GetMenuPool()->HideMenu(byteMenuID);
|
||||
}
|
||||
|
||||
//----------------------------------------------------
|
||||
|
||||
|
||||
Reference in New Issue
Block a user