Whats wrong with this /exit CMD?
#1

Код:
if(strcmp(cmdtext, "/exit", true, 3) == 0)
if(VehicleID == Myygiauto1)
if(VehicleID == Myygiauto2)
if(VehicleID == Myygiauto3)
{
RemovePlayerFromVehicle(playerid);
return 1;
}
It doesnt work, whats wrong
and yes i am in the car "Myygiauto1"
Reply
#2

pawn Код:
if(strcmp(cmdtext, "/exit", true) == 0)
{
    switch(VehicleID)
    {
        case Myygiauto1, Myygiauto2, Myygiauto3:
        {
            RemovePlayerFromVehicle(playerid);
            return 1;
        }
    }
}
Reply
#3

Switch can only be used for constant values (how obvious), so you will need to use if.
Reply
#4

Quote:
Originally Posted by $ЂЯĢ
Switch can only be used for constant values (how obvious), so you will need to use if.
Don't say if you don't know.

EDIT: and lol, why would I need to check constant values ?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)