[HELP] Please help cp
#1

pawn Код:
if(carid >= Nafta[3] && carid <= Nafta[6] && carid >= NaftaCisterna[0] && carid <= NaftaCisterna[3] && CP[playerid] == 2107)
    {
        CP[playerid] = 2108; TogglePlayerControllable(playerid,0); GorivoPrijevoz[playerid] = 1; GameTextForPlayer(playerid,"~w~utovar goriva",5000,1);TogglePlayerControllable(playerid,0); SetTimerEx("GorivoUkrcaj",13000,false,"i",playerid); PlayerPlaySound(playerid,1138,0,0,0); DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2149.7993,-2147.8916,13.5469,6.0);
    }
hello I just add there carid == NaftaCisterna[0] && carid <= NaftaCisterna[3] so this is if I have attached on trunk then I get should pass on cp but I enter in the cp and nothing happens?Why? Thanks
Reply
#2

Use OnPlayerEnterCheckpoint
Reply
#3

when I move naftacisterna from the code everything works fine but I need that I want if player does not this attached to trunk then he not pass on cp
Reply
#4

anyone? Thanks
Reply
#5

Use this to check if a trailer is attached to the vehicle.
Reply
#6

I have 2 kind of trailer for that job one trailer is for fuel and another is for delivering meat
Reply
#7

PHP код:
if(IsTrailerAttachedToVehicle(vehicleid)) 
Replace vehicleid with the ID of the fuel and the another trailer.
Reply
#8

it doesn'twork I go to cp with that trailer for fuel and nothing happens.


edit: And also I try just trailer id which si 584 and I go to cp with that trailer and nothing happens


pawn Код:
if(IsTrailerAttachedToVehicle(carid >= NaftaCisterna[0] && carid <= NaftaCisterna[3]))
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)