Etwas
public text v1 · immutableif(strcmp(cmdtext, "/command", true) == 0)
{
new timestamp = GetTickCount();
if(IsPlayerConnected(playerid))
{
if(timestamp - LastHW[playerid] < 5000)
{
SendClientMessage(playerid, COLOR_WHITE, "SERVER: You are already hotwiering the vehicle.");
}
else if(random(100)<30)
{
SetTimerEx("HotwireSucces", 5000, 0, "i", playerid);
@@ LastHW[playerid] = timestamp;
}
else
{
SetTimerEx("HotwireFail", 5000, 0, "i", playerid);
@@ LastHW[playerid] = timestamp;
}
}
return 1;
}