Enum help
#1

i thought of a cmd with enum but is this kind of enum valid??
pawn Код:
enum vInfo
{
    ModelId,
    MaxSpeedWithNitro,
    MaxSpeedWithoutNitro,
    EngineWeight,
    SpeedRank
};

new VehicleInfo [MAX_VEHICLES] [vInfo] = {
{400,bla}
{401,bla}
{402,bla}
.
.
.
{611,bla}
};
If its right how to add this to this when a player typed a cmd??
pawn Код:
CMD:vi(playerid, params[])
if(!IsPlayerInVehicle) return SCM(playerid, color, "You Need To Be In A Vehicle");
// whats the code to check whether he is driver?
GetPlayerVehicleModel(GetPlayerVehicleId)
if(GetPlayerVehicleModel(GetPlayerVehicleId) == VehicleInfo [] [ModelId]) Return // and what to do
I know im a nub ;(
Reply


Messages In This Thread
Enum help - by newbie scripter - 31.10.2013, 11:10
Re: Enum help - by iJumbo - 31.10.2013, 11:12
Re: Enum help - by newbie scripter - 31.10.2013, 11:16
Re: Enum help - by iJumbo - 31.10.2013, 11:21
Re: Enum help - by newbie scripter - 31.10.2013, 11:30
Re: Enum help - by iJumbo - 31.10.2013, 11:31
Re: Enum help - by newbie scripter - 31.10.2013, 11:34
Re: Enum help - by Konstantinos - 31.10.2013, 11:35
Re: Enum help - by iJumbo - 31.10.2013, 11:41
Re: Enum help - by newbie scripter - 03.11.2013, 11:42

Forum Jump:


Users browsing this thread: 1 Guest(s)