mirror of
https://github.com/dashr9230/SA-MP.git
synced 2026-10-10 19:53:04 +08:00
[saco] Match Unk3A; it deletes a 3D text label, bailing early when the pool is absent
This commit is contained in:
@@ -9,7 +9,7 @@ typedef struct _LABEL
|
||||
|
||||
class CLabelPool
|
||||
{
|
||||
private:
|
||||
public:
|
||||
LABEL m_Labels[MAX_LABELS];
|
||||
BOOL m_bLabelSlotState[MAX_LABELS];
|
||||
public:
|
||||
|
||||
+2
-2
@@ -24,8 +24,8 @@ struct struc_41
|
||||
int field_23;
|
||||
float field_27;
|
||||
char _gap2B;
|
||||
char field_2C;
|
||||
char field_2D;
|
||||
BYTE field_2C;
|
||||
BYTE field_2D;
|
||||
char field_2E;
|
||||
char field_2F;
|
||||
char _gap30[10];
|
||||
|
||||
+17
-1
@@ -7,7 +7,23 @@ extern CGame * pGame;
|
||||
// TODO: these RPCs
|
||||
void Unk22(RPCParameters *rpcParams) {}
|
||||
void Unk24(RPCParameters *rpcParams) {}
|
||||
void Unk3A(RPCParameters *rpcParams) {}
|
||||
void Unk3A(RPCParameters *rpcParams)
|
||||
{
|
||||
PCHAR Data = reinterpret_cast<PCHAR>(rpcParams->input);
|
||||
int iBitLength = rpcParams->numberOfBitsOfData;
|
||||
|
||||
WORD wLabelID;
|
||||
|
||||
RakNet::BitStream bsData(Data,(iBitLength/8)+1,false);
|
||||
|
||||
CLabelPool *pLabelPool = pNetGame->GetLabelPool();
|
||||
if(!pLabelPool) return;
|
||||
|
||||
bsData.Read(wLabelID);
|
||||
|
||||
if(wLabelID < MAX_LABELS && pLabelPool->m_bLabelSlotState[wLabelID])
|
||||
pLabelPool->Delete(wLabelID);
|
||||
}
|
||||
void Unk3B(RPCParameters *rpcParams) {}
|
||||
void Unk3D(RPCParameters *rpcParams) {}
|
||||
void SetCheckpoint(RPCParameters *rpcParams) {}
|
||||
|
||||
Reference in New Issue
Block a user