27.11.2011, 19:36
Ok i got a godcar cmd what works but onlyfor id 0 as i found out when i got my beta testers to test some stuff but im not sure why could you guys have a look, would be great thanks.
Код:
new GodMode[MAX_PLAYERS];
Код:
CMD:godcar(playerid)
{
if(DeathMatch[playerid] != 0) return SendClientMessage(playerid, COLOR_RED, "You can not TP from DM. Use /exitdm to leave.");
GodMode[playerid] = 1;
SendClientMessage(playerid, COLOR_CADETBLUE, "You Have Turned God Car On!!!!");
return 1;
}
CMD:godcaroff(playerid)
{
if(DeathMatch[playerid] != 0) return SendClientMessage(playerid, COLOR_RED, "You can not TP from DM. Use /exitdm to leave.");
GodMode[playerid] = 0;
SendClientMessage(playerid, COLOR_CADETBLUE, "You Have Turned God Car Off Be Carefully!!!!");
return 1;
}
Код:
forward AutoR(playerid);
public AutoR(playerid)
{
if(IsPlayerInAnyVehicle(playerid) && GodMode[playerid] == 1)
{
new vid = GetPlayerVehicleID(playerid);
RepairVehicle(vid);
}
return 1;
}



