you can check time between deaths with "GetTickCount()"
but for more accuracy:
if i kill someone, i have to give damage to him/her !
so make a variable and check player has received any damage or no
i'll give you a simple example (explained in code with comments)
Код:
new bool:PlayerShotedPlayer[MAX_PLAYERS][MAX_PLAYERS]; //> (PlayerShotedPlayer[killer][player])
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
{
if(issuerid != INVALID_PLAYER_ID && playerid != INVALID_PLAYER_ID)
{
PlayerShotedPlayer[issuerid][playerid] = true; //>issuerid gave damage to player id, so set variable true
}
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
if(killerid != INVALID_PLAYER_ID)
{
if(PlayerShotedPlayer[killerid][playerid] == false)
{
//Kick or ban playerid (cheater) Here
}
}
//if playerid wasn't cheater so .. let's reset damage variable
for(new i = 0; i < MAX_PLAYERS; i++)
{
PlayerShotedPlayer[i][playerid] = false;
}
return 1;
}
i wrote code completely, you can copy&paste it into your gamemode (add kick or ban code)
but please read code and learn
Down With Cheaters
Good Luck