03.01.2015, 23:55
pawn Код:
forward JiHad(playerid);
public JiHad(playerid)
{
SetVehicleHealth(vehicleid, 0)
SendClientMessage("You have successfully Jihaded!")
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/Jihad", cmdtext, true, 10) == 0)
{
new vehicleid;
if(!sscanf(cmdtext, "d", vehicleid) return SendClientMessage(playerid, -1, "/Jihad<vehicleid>");
PutPlayerInVehicle(playerid, vehicleid, 0);
SetTimerEx("Jihad", 60000, false, "d", playerid);
SendClientMessage("In 60 seconds your vehicle will explode! (If you want to abort do /StopJihad");
return 1;
}
if (strcmp("/StopJihad", cmdtext, true, 10) == 0)
{
new vehicleid = GetPlayerVehicleID(playerid);
DestroyVehicle(vehicleid);
return 1;
}
return 1;
}