Help here a bit
#8

Here you go.

pawn Код:
new CarHotwired[MAX_VEHICLES]; // add at top of script, you know this.

CMD:hotwire(playerid, params[])
{
     new
        string[128],
        giveplayerid,
        vehicleid = GetPlayerVehicleID(playerid);

    if(PlayerInfo[playerid][pToolKit] == 1 && PlayerInfo[playerid][pHotWire] == 0)
    {
        format(string, sizeof(string), "* %s Grabs his/her toolkit and begins to unzip it", GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid));
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        SetTimerEx("Hotwire",1000, 0 , "dd", vehicleid, playerid);
        SetTimerEx("Hotwire1",3000, 0 , "dd", vehicleid, playerid);
        SetTimerEx("Hotwire2",5000, 0 , "dd", vehicleid, playerid);
        SetTimerEx("Hotwire3",7000, 0 , "dd", vehicleid, playerid);
        SetTimerEx("Hotwire4",9000, 0 , "dd", vehicleid, playerid);
        SetTimerEx("SetVehicleEngine",10000, 0, "dd",  vehicleid, playerid);
        GameTextForPlayer(playerid, "~r~Hotwiring.....", 10000,4);
        //CarHotwired[vehicleid] == 1; **ADD THIS WHERE YOU DECIDE IF THE HOTWIRE WAS SUCCESSFUL OR NOT
    }
    if(PlayerInfo[playerid][pToolKit] == 1 && PlayerInfo[playerid][pHotWire] == 1)
        return SendClientMessage(playerid,COLOR_RED,"You are already hotwiring this car.");
    if(PlayerInfo[playerid][pToolKit] == 0)
        return SendClientMessageEx(playerid, COLOR_GREY, "You need a toolkit to hotwire this car");
    if(CarHotwired[vehicleid] == 1)
        return SendClientMessage(playerid, COLOR_RED, "Car has already been hotwired.");
    return 1;
}
Reply


Messages In This Thread
Help here a bit - by PRototype-RP - 24.12.2011, 18:13
Re: Help here a bit - by prisonliferp - 24.12.2011, 18:17
Re: Help here a bit - by PRototype-RP - 24.12.2011, 18:21
Re: Help here a bit - by prisonliferp - 24.12.2011, 18:23
Re: Help here a bit - by PRototype-RP - 24.12.2011, 19:03
Re: Help here a bit - by prisonliferp - 24.12.2011, 19:06
Re: Help here a bit - by PRototype-RP - 24.12.2011, 19:09
Re: Help here a bit - by Steven82 - 24.12.2011, 19:25
Re: Help here a bit - by PRototype-RP - 24.12.2011, 19:40
Re: Help here a bit - by PRototype-RP - 24.12.2011, 22:12

Forum Jump:


Users browsing this thread: 1 Guest(s)