[Help]Respawn Cars
#5

Quote:
Originally Posted by Ballu Miaa
Посмотреть сообщение
Okay give me the command /motor from your game mode. I will fix it.

Код:
	if(!strcmp(cmd, "/Motor", true))
	{
	    if(IsPlayerConnected(playerid))
	    {
   			if(!IsPlayerInAnyVehicle(playerid))
			{
		          SendClientMessage(playerid, COLOR_GREY, "Debes Estar en Un Coche para Usar el Comando");
		          return 1;
	        	}
	    		if(!engineOn[GetPlayerVehicleID(playerid)])
	    		{
	        		if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
					{
						return 1;
					}
					if(IsAnOwnableCar(idcar))
					{
						if(PlayerInfo[playerid][pPcarkey] == idcar) { }
						else if(PlayerInfo[playerid][pPcarkey2] == idcar) { }
						else { return 1; }
					}
					if(pveh == 510 || pveh == 462 || pveh == 481 || pveh == 509)
					{
						return 1;
					}
					if(idcar == 59 || idcar == 60)
					{
						return 1;
					}
					if(idcar >= 135 && idcar <= 154)
					{
					    if(HireCar[playerid] != idcar)
					    {
							return 1;
						}
					}
					if(IsAPlane(idcar))
					{
					    return 1;
					}
					if(IsAHarvest(idcar))
					{
					    return 1;
					}
					if(IsADrugHarvest(idcar))
					{
					    return 1;
					}
					if(IsASweeper(idcar))
					{
					    return 1;
					}
					if(IsASweeper(idcar))
					{
					    return 1;
					}
					if(gEngine[playerid] == 1) { return 1; }

					new playerveh = GetPlayerVehicleID(playerid);
					PutPlayerInVehicle(playerid, playerveh, 0);
					GetPlayerName(playerid, sendername, sizeof(sendername));
					format(string, sizeof(string), "* %s pone las llaves en el rotor e intenta encender el vehнculo", sendername);
					ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
					SetTimerEx("StartingTheVehicle",3500,0,"i",playerid);
					GameTextForPlayer(playerid, "~b~Encendiendo Vehiculo...",3500,3);
					gEngine[playerid] = 1;
					return 1;
				}
				if(engineOn[GetPlayerVehicleID(playerid)])
	    		{
	        		if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
					{
						return 1;
					}
					if(IsAnOwnableCar(idcar))
					{
					    if(PlayerInfo[playerid][pPcarkey] == idcar) { }
					    else if(PlayerInfo[playerid][pPcarkey2] == idcar) { }
						else { return 1; }
					}
					if(pveh == 510 || pveh == 462 || pveh == 481 || pveh == 509)
					{
						return 1;
					}
					if(idcar == 59 || idcar == 60)
					{
						return 1;
					}
					if(idcar >= 135 && idcar <= 154)
					{
					    if(HireCar[playerid] != idcar)
					    {
							return 1;
						}
					}
					if(IsAHarvest(idcar))
					{
					    return 1;
					}
					if(IsADrugHarvest(idcar))
					{
					    return 1;
					}
					if(IsAPlane(idcar))
					{
					    return 1;
					}
					if(IsASweeper(idcar))
					{
					    return 1;
					}
					engineOn[GetPlayerVehicleID(playerid)] = false;
					TogglePlayerControllable(playerid, 0);
					GetPlayerName(playerid, sendername, sizeof(sendername));
					format(string, sizeof(string), "* %s apaga el motor del vehнculo", sendername);
					ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
					gEngine[playerid] = 0;
					return 1;
				}

	    }
	    return 1;
	}
PD: also I have another system that is on Dialog and that if he walks
Reply


Messages In This Thread
[Help]Respawn Cars - by IvanDrago - 09.05.2012, 01:34
Re: [Help]Respawn Cars - by Ballu Miaa - 09.05.2012, 01:42
Respuesta: [Help]Respawn Cars - by IvanDrago - 09.05.2012, 01:48
Re: [Help]Respawn Cars - by Ballu Miaa - 09.05.2012, 01:52
Respuesta: Re: [Help]Respawn Cars - by IvanDrago - 09.05.2012, 01:55
Re: [Help]Respawn Cars - by Ballu Miaa - 09.05.2012, 02:59

Forum Jump:


Users browsing this thread: 2 Guest(s)