bool CALLBACK outcomingRPC(stRakNetHookParams * params)
{
if (params->packetId == RPCEnumeration::RPC_GiveTakeDamage)
{
bool type;
WORD playerID;
float damage;
int gun, bodyID;
params->bitStream->ResetReadPointer();
params->bitStream->Read(type);
params->bitStream->Read(playerID);
params->bitStream->Read(damage);
params->bitStream->Read(gun);
params->bitStream->Read(bodyID);
if (playerID > SAMP_MAX_PLAYERS) { return true; }
if (gun > 46) { return true; }
if (type) {
//Your code
}
};
return true;
}