16.09.2017, 12:47
Quote:
|
Am I missing something in Pawn or this condition is useless?
Code:
const AIM_SYNC = 203;
IPacket:AIM_SYNC(playerid, BitStream:bs)
{
new aimData[PR_AimSync];
BS_IgnoreBits(bs, 8);
BS_ReadAimSync(bs, aimData);
if (aimData[PR_aimZ] != aimData[PR_aimZ]) // is NaN <-
{
aimData[PR_aimZ] = 0.0;
BS_SetWriteOffset(bs, 8);
BS_WriteAimSync(bs, aimData);
}
return 1;
}
https://github.com/urShadow/Pawn.Rak...tiVehicleSpawn |
Code:
public OnVehicleRequestDeath(vehicleid, killerid)
{
new Float:X, Float:Y, Float:Z, Float:health;
GetVehiclePos(vehicleid,X,Y,Z);
MapAndreas_FindZ_For2DCoord(X,Y,Z);
GetVehicleHealth(vehicleid, health);
if(health > 300.0 && Z != 0.0) // If car above the water MapAndreas return a height 0.0
{
return 0;
}
return 1;
}


