SA-MP Forums Archive
Engine Help ! - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Engine Help ! (/showthread.php?tid=300432)



Engine Help ! - dorperez - 30.11.2011

Hey Guys,

I want to do rent area,I have all the scripts that I need but there is a problem.When I enter the rent car I turn on the engine like a normal car and I dont have to pay ...

Here is the engine code:

pawn Код:
if(dialogid == VEHICLE_CONTROL_DIALOG+1)
    {
        if(response)
        {
   TogglePlayerControllable(playerid, 1);
            SendClientMessage(playerid, COLOUR_INFORMATION, "You have started your engine.");
            GetVehicleParamsEx(GetPlayerVehicleID(playerid), engine, lights, alarm, doors, bonnet, boot, objective);
            SetVehicleParamsEx(GetPlayerVehicleID(playerid), ON, lights, alarm, doors, bonnet, boot, objective);
        }
  if(!response)
        {
            SendClientMessage(playerid, COLOUR_INFORMATION, "You have stopped your engine.");
            GetVehicleParamsEx(GetPlayerVehicleID(playerid), engine, lights, alarm, doors, bonnet, boot, objective);
            SetVehicleParamsEx(GetPlayerVehicleID(playerid), OFF, lights, alarm, doors, bonnet, boot, objective);
        }
        #if defined AUTO_REOPEN_DIALOG
        ShowVehicleControlDialog(playerid);
        #endif
        return 1;
    }
Tnx !


Re: Engine Help ! - dorperez - 30.11.2011

Help guys ...


Re: Engine Help ! - ElkaBlazer - 30.11.2011

I dont see here where you checked if the vehicle is a rentable vehicle ....-_-