13.10.2009, 18:35
Okay, here's the code
pawn Код:
if(strcmp(cmd,"/fix",true)==0)
{
if(IsPlayerAdmin(playerid)) // Player must be RCON admin to use this command
{
if(IsPlayerInAnyVehicle(playerid)) // Player must be in vehicle to use this command
{
new veh = GetPlayerVehicleID(playerid);
SetVehicleHealth(veh,1000); // I don't know if this is going to work, sorry (veh = vehicle id, 1000 = health)
SendClientMessage(playerid,COLOR_CODE_HERE,"Your vehicle is fixed!");
}
else
{
SendClientMessage(playerid,COLOR_CODE_HERE,"You're not in vehicle!");
}
}
return 1;
}