/engine
#1

what's wrong there?
Код:
if(strcmp(cmd, "/engine", true) == 0)
	{
	new stringddd[50];
    new pNames[18];
	new vehicleid = GetPlayerVehicleID(playerid);
	new engine,lights,alarm,doors,bonnet,boot,objective;
  	GetVehicleParamsEx(vehicleid,engine,lights,alarm,doors,bonnet,boot,objective);
  	if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
	{
		 	if(engine == 1)
		    {
		        SendClientMessage(playerid,COLOR_WHITE,"You're engine is allready started.");
		        return 1;
		    }
		    if(engine == 0 && gGas[vehicleid] > 0)
		    {
		        SetVehicleParamsEx(vehicleid,1,lights,alarm,doors,bonnet,boot,objective);
		        format(stringddd, 128, "* %s has start the engine.", pNames);
   			    ProxDetector(30.0, playerid, stringddd, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
		        return 1;
		    }
		 	if(engine == 0 && gGas[vehicleid] == 0)
			{
			 SendClientMessage(playerid, COLOR_WHITE, "Car doesn't have fuel.");
			 return 1;
		 	}
		else
		{
			SendClientMessage(playerid, COLOR_WHITE, "You need to be the driver of a car!");
		}
	}
	}
Reply


Messages In This Thread
/engine - by Visio - 29.08.2012, 09:23
Re: /engine - by Cjgogo - 29.08.2012, 09:29
Re: /engine - by Visio - 29.08.2012, 09:35
Re: /engine - by clarencecuzz - 29.08.2012, 09:36
Re: /engine - by Visio - 29.08.2012, 09:48
Re: /engine - by clarencecuzz - 29.08.2012, 09:54
Re: /engine - by Visio - 29.08.2012, 09:56
Re: /engine - by romas3110 - 29.08.2012, 10:02
Re: /engine - by Visio - 29.08.2012, 10:03

Forum Jump:


Users browsing this thread: 2 Guest(s)