Привет, Гость!
  • Страница 1 из 1
  • 1
[Античит] Anti OnFoot Crasher
AdminДата: Воскресенье, 06.01.2019, 01:38 | Сообщение # 1
Генерал-майор
Группа: Администраторы
Сообщений: 272
Репутация: 0
Статус: Offline
Код
new AntiOnFootCrash[MAX_PLAYERS char];

public OnPlayerConnect(playerid)
{
    AntiOnFootCrash{playerid} = 0;
    return 1;
}

public OnPlayerUpdate(playerid)
{
    new Float:x, Float:y, Float:z;
    GetPlayerCameraFrontVector(playerid, x, y, z);
    if(floatcmp(x, -1.0) == -1 || floatcmp(x, 1.0) == 1
    || floatcmp(y, -1.0) == -1 || floatcmp(y, 1.0) == 1
    || floatcmp(z, -1.0) == -1 || floatcmp(z, 1.0) == 1)
    {
        if(AntiOnFootCrash{playerid})
            Kick(playerid);
        else
            AntiOnFootCrash{playerid}=1; //ложный вызов из-за старых данных.
        return 0;
    }
    return 1;
}  


Работает, я тестил на крмп 3е
 
  • Страница 1 из 1
  • 1
Поиск: