21.10.2011, 01:02
pawn Код:
#include <YSI\y_timers>
new Float:oldPos[MAX_PLAYERS][3];
Timer:AFKUpdate[120000]() {
new Float:tempPos[3];
foreach(Player, playerid) {
GetPlayerPos(playerid, tempPos[0], tempPos[1], tempPos[2]);
if(tempPos[0] == oldPos[playerid][0] && tempPos[1] == oldPos[playerid][1] && tempPos[2] == oldPos[playerid][2]) {
// AFK code
}
GetPlayerPos(playerid, oldPos[playerid][0], oldPos[playerid][1], oldPos[playerid][2]);
}
}