28.06.2013, 09:46
pawn Code:
new ptimer[MAX_PLAYERS];
stock CheckPlayerPos(playerid)
{
if(ptimer[playerid] !-1) KillTimer(ptimer[playerid])//Make sure no timers overstock
new Float:pPos[3];GetPlayerPos(playerid, pPos[0], pPos[1],pPos[2]);
ptimer[playerid] = SetTimerEx("InVeh", 10000, false, "ifff", playerid,pPos[0], pPos[1],pPos[2]);
return 1;
}
forward InVeh(playerid,pPosX, pPosY,pPosZ)
public InVeh(playerid,pPosX, pPosY,pPosZ)
{
new Float:NewpPos[3];GetPlayerPos(playerid, NewpPos[0], NewpPos[1],NewpPos[2]);
if(NewpPos[0]==pPosX && NewpPos[1]==pPosY && NewpPos[2]==pPosZ)
{
//They Didnt Move
}else{
//They Moved
}
}