how can i set the tickcount 1 time, and other things multiple times?
#1

hey everyone,

im working in an anticheat system for my server, and now i wanna ban players who teleport players to them with cleo/******

now my beta tester/******, cleo hacker, told me that a player goes 3 times in a vehicle in less then a second to teleport someone to him, meaning that manually with cmds this is almost IMPOSSIBLE.

so now i wanna get the tickcount of when someone goes in a car, and then another array, saying the player went into a vehicle ++. but how can i make it that onplayerstatechange only does the tickcount 1 time, and the array multiple times, untill it has reached 3, and then ill make a check in onplayerupdate to see when he has entered 3 cars, and the tickcount is LESS then a second, then he gets banned.

pawn Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
    if(newstate == PLAYER_STATE_DRIVER)
    {
        PlayerInfo[playerid][TickCount] = GetTickCount(); // i want this one to only call 1 time.
        PlayerInfo[playerid][GoesInVehicle]++; // this one must keep continueing and counting.
    }
    return 1;
}
so is there a way to let the gettickcount do it once, and the goesinvehicle++ just keeps contineuing when he enters a new car.

greets niels
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)