0 votes
by
Hi, loving this asset. Is it possible to disable the push to start function? As in to have the car permanently running upon game start? I have found and disabled the stall feature but struggled to find anything about this.

Thanks

1 Answer

0 votes
by

You have several methods available.

Method 1:
Disable the possibility of stalling the engine

  • Disable Can Stall in the Engine section of VP Vehicle Controller.
  • Set External Ignition to "Acc On" in VP Standard Input.

Engine will be always on, without possibility of stall. The engine will switch off only if the ignition key is moved to the "Off" position with Ctrl-K (or via the Data Bus from a script).

If you leave External Ignition in "Off" then the user must start the engine by pressing K once, but then it won't stall.

Method 2:
Use the option "Start Engine On Enable" of VPVehicleToolkit

Add the VPVehicleToolkit component anywhere in the hierarchy of the vehicle, then enable the option Start Engine On Enable

This ensures the engine to start as soon as this component is enabled. Using this method Can Stall may be enabled so the user may stall the engine if the conditions require so.

The entire source code of VPVehicleToolkit is available here for reference.

Method 3:
Use an script to start the engine via the Data Bus

This is essentially the same as using VPVehicleToolkit (method 2), but you may reproduce it yourself for more control.

  • Keep sending the value "1" to the Key value in the Input channel until the value EngineStalled in the Vehicle channel returns "0". 
  • Once EngineStalled is "0" send a "0" to Key.

This method actually moves the ignition key to the Start position. Once started (vehicle is no longer stalled) the key is moved back to the Acc-On position. Using this method Can Stall may be enabled so the user may stall the engine if the conditions require so.

...