When Vehicle is Picked Up
Fires when a player takes the vehicle provided by the spawner.
Introduction
When Vehicle is Picked Up is an event in the Vehicle Spawner group of World Events. It fires when a player takes the vehicle provided by the spawner. Like every event, it does nothing by itself. It waits for the right moment, then runs all the actions connected to it. Use it when you want something to happen automatically as soon as a vehicle is picked up. This event belongs to the Vehicle Spawner component. Open the Vehicle Spawner component guide to see everything the component itself can do. Vehicle spawners manage a fleet: a car appears through When Vehicle Refreshes cycles, and this event fires the moment a player claims it - after which the drive itself starts with When Player Gets On . Spawn points and fleet limits are configured in the Vehicle Spawner guide. When Vehicle is Picked Up event in the World Editor Image The When Vehicle is Picked Up event in the Script Editor. caption
Parameters
Player the player who took the vehicle Parameter Description
How to Access
How to Access - Event When Vehicle is Picked Up
How to Use
Select the object, press Propertie (the blue equalizer icon) in the bottom action menu, and scroll to the bottom of the properties panel. Press Add Component and pick the Vehicle Spawner component; its block stacks below the existing properties with the When Vehicle Is Picked Up event inside it. Press the + button below the event to add a script, then press Edit on that script to open the script editor and build the actions that should run when the event fires. Press Play and take the spawned vehicle, then check that the actions run.
Example
When Vehicle is Picked Up: Execute System Environment.3D Bubble show Drive at position, color black when-vehicle-is-picked-up-example.png Shows a 3D bubble with a prompt when a player picks up the spawned vehicle. caption
Common Uses
Start a chase or a delivery objective Play an engine start sound Track how many vehicles players have taken
Tip
Combine with When Vehicle Refreshes to keep a steady supply of vehicles in busy areas.