This command isnt doing what its suppose to be doing
#1

pawn Код:
CMD:trunk(playerid,params[])
{
    new vid;
    vid = GetPlayerVehicleID(playerid);
    new engine,lights,alarm,doors,bonnet,boot,objective;
    GetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,boot,objective);
   
    if(boot)
    {
        GetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,boot,objective);
        SetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,true,objective);
        SCM(playerid,COLOR_LIGHTRED,"You Have Poped The Trunk!");
    }
    else
    {
        GetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,boot,objective);
        SetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,false,objective);
        SCM(playerid,COLOR_LIGHTRED,"You Have Closed The Trunk!");
    }
    return 1;
}
What is wrong with that command? its suppose to open trunk if the trunk is closed. and close trunk if trunk is open. All it does is open it
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)