new string[128];
new tuVariable[MAX_PLAYER_NAME];GetPlayerName(playerid, tuVariable, sizeof tuVariable);
format(string, sizeof string, "El jugador %s fue baneado por el anticheat. Rason: speedhack",tuVariable);
SendClientMessageToAll(0xFF0000FF, string);
?? http://forum.sa-mp.com/showthread.ph...63#post3343363 A lo ultimo sale un post mio me ayudas porfa
|
oe me podrias ayudar
?? http://forum.sa-mp.com/showthread.ph...63#post3343363 A lo ultimo sale un post mio me ayudas porfa |
SetTimerEx("Velocidad", 100, true, "i", playerid);
forward BuscarHacks(playerid);
public OnPlayerConnect(playerid){
SetTimerEx("BuscarHacks", 100, true, "i", playerid);
}
forward BuscarHacks(playerid);
public BuscarHacks(playerid){
if(GetVehicleSpeed(GetPlayerVehicleID(playerid)) > 230){ //"230" es el limite de la velocidad
new string[128];
format(string, sizeof(string), "El jugador {FF0000}%s(ID: %d) {FFFFFF} fue baneado por el Anticheat, {FFFFFF}Razуn: {FF0000}SpeedHack{FFFFFF}.", GetPlayerName(giveplayerid), playerid);
SendClientMessageToAllEx(COLOR_WHITE, string);
Ban(playerid);
}
}
stock GetVehicleSpeed(vehicleid)
{
new Float:xPos[3];
GetVehicleVelocity(vehicleid, xPos[0], xPos[1], xPos[2]);
return floatround(floatsqroot(xPos[0] * xPos[0] + xPos[1] * xPos[1] + xPos[2] * xPos[2]) * 170.00);
}
stock GetPlayerName(playerid)
{
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, MAX_PLAYER_NAME);
return name;
}