Reference Devices compiles

vehicle_spawner_big_rig_device: Spawn a Mudflap Semi on Cue

Need a hulking Mudflap semi truck to roll into your map at the right moment — a getaway rig, a boss-fight target, a delivery vehicle that respawns when destroyed? The vehicle_spawner_big_rig_device gives you the truck, and Verse lets you spawn it, assign its driver, destroy it, and react when players climb in or out.

Updated Examples verified on the live UEFN compiler
Watch the Knotvehicle_spawner_big_rig_device in ~90 seconds.

Overview

The vehicle_spawner_big_rig_device is a specialized vehicle_spawner_device that spawns a Mudflap semi truck (the big rig). You place one in your level, point a Verse @editable field at it, and from code you can Enable/Disable the spawner, RespawnVehicle to drop a fresh truck (destroying any previous one), AssignDriver to seat a specific agent behind the wheel, and DestroyVehicle to blow it up.

Reach for this device when you want dynamic vehicle gameplay: a heist rig that only appears once a vault opens, a demolition-derby target that respawns each round, or a delivery truck whose driver is chosen by your match logic. Because it inherits everything from vehicle_spawner_device, the same API (and these same examples) work for the sedan, quadcrasher, taxi, and other vehicle spawners — just swap the field type.

The device also raises events: SpawnedEvent (hands you the spawned fort_vehicle), DestroyedEvent, and AgentEntersVehicleEvent / AgentExitsVehicleEvent (hand you the agent). These let you score players for stealing the rig, lock objectives behind "truck is alive", or trigger cinematics.

API Reference

vehicle_spawner_big_rig_device

Specialized vehicle_spawner_device that allows a Mudflap semi truck to be configured and spawned.

Full public surface, resolved verbatim from the live Epic digest (Fortnite.digest.verse). Inherited members are merged from vehicle_spawner_device.

vehicle_spawner_big_rig_device<public> := class<concrete><final>(vehicle_spawner_device):

Events (subscribe a handler to react):

Event Signature Description
AgentEntersVehicleEvent AgentEntersVehicleEvent<public>:listenable(agent) Signaled when an agent enters the vehicle. Sends the agent that entered the vehicle.
AgentExitsVehicleEvent AgentExitsVehicleEvent<public>:listenable(agent) Signaled when an agent exits the vehicle. Sends the agent that exited the vehicle.
SpawnedEvent SpawnedEvent<public>:listenable(fort_vehicle) Signaled when a vehicle is spawned or respawned by this device. Sends the fort_vehicle who was spawned.
VehicleSpawnedEvent VehicleSpawnedEvent<public>:listenable(tuple()) Signaled when a vehicle is spawned or respawned by this device. Deprecated, use SpawnedEvent instead.
VehicleDestroyedEvent VehicleDestroyedEvent<public>:listenable(tuple()) Signaled when a vehicle is destroyed. Deprecated, use DestroyedEvent instead.
DestroyedEvent DestroyedEvent<public>:listenable(tuple()) Signaled when a vehicle is destroyed.

Methods (call these to make the device act):

Method Signature Description
Enable Enable<public>():void Enables this device.
Disable Disable<public>():void Disables this device.
AssignDriver AssignDriver<public>(Agent:agent):void Sets agent as the vehicle's driver.
DestroyVehicle DestroyVehicle<public>():void Destroys the vehicle if it exists.
RespawnVehicle RespawnVehicle<public>():void Spawns a new vehicle. The previous vehicle will be destroyed before a new vehicle spawns.

vehicle_spawner_device

Base class for various specialized vehicle spawners which allow specific vehicle types to be spawned and configured with specialized options.

Full public surface, resolved verbatim from the live Epic digest (Fortnite.digest.verse).

vehicle_spawner_device<public> := class<abstract><epic_internal>(creative_device_base):

Events (subscribe a handler to react):

Event Signature Description
AgentEntersVehicleEvent AgentEntersVehicleEvent<public>:listenable(agent) Signaled when an agent enters the vehicle. Sends the agent that entered the vehicle.
AgentExitsVehicleEvent AgentExitsVehicleEvent<public>:listenable(agent) Signaled when an agent exits the vehicle. Sends the agent that exited the vehicle.
SpawnedEvent SpawnedEvent<public>:listenable(fort_vehicle) Signaled when a vehicle is spawned or respawned by this device. Sends the fort_vehicle who was spawned.
VehicleSpawnedEvent VehicleSpawnedEvent<public>:listenable(tuple()) Signaled when a vehicle is spawned or respawned by this device. Deprecated, use SpawnedEvent instead.
VehicleDestroyedEvent VehicleDestroyedEvent<public>:listenable(tuple()) Signaled when a vehicle is destroyed. Deprecated, use DestroyedEvent instead.
DestroyedEvent DestroyedEvent<public>:listenable(tuple()) Signaled when a vehicle is destroyed.

Methods (call these to make the device act):

Method Signature Description
Enable Enable<public>():void Enables this device.
Disable Disable<public>():void Disables this device.
AssignDriver AssignDriver<public>(Agent:agent):void Sets agent as the vehicle's driver.
DestroyVehicle DestroyVehicle<public>():void Destroys the vehicle if it exists.
RespawnVehicle RespawnVehicle<public>():void Spawns a new vehicle. The previous vehicle will be destroyed before a new vehicle spawns.

Walkthrough

Let's build a "Big Rig Heist" scenario. The spawner starts disabled. When the round begins we enable it and spawn the truck. We track how many players board it, announce arrivals and departures, and if the truck is destroyed we respawn a fresh one after a short delay so the heist can continue.

using { /Fortnite.com/Devices }
using { /Fortnite.com/Vehicles }
using { /Fortnite.com/Characters }
using { /Verse.org/Simulation }
using { /UnrealEngine.com/Temporary/Diagnostics }

big_rig_heist := class(creative_device):

    # Drag your Vehicle Spawner (Big Rig) device here in the Details panel.
    @editable
    RigSpawner : vehicle_spawner_big_rig_device = vehicle_spawner_big_rig_device{}

    # Localized text helper — message params need a localized value, not a raw string.
    HeistText<localizes>(S:string):message = "{S}"

    OnBegin<override>()<suspends>:void =
        # React to the truck appearing.
        RigSpawner.SpawnedEvent.Subscribe(OnRigSpawned)
        # React to the truck being destroyed.
        RigSpawner.DestroyedEvent.Subscribe(OnRigDestroyed)
        # React to players getting in and out.
        RigSpawner.AgentEntersVehicleEvent.Subscribe(OnAgentEnters)
        RigSpawner.AgentExitsVehicleEvent.Subscribe(OnAgentExits)

        # Turn the spawner on and drop the first truck.
        RigSpawner.Enable()
        RigSpawner.RespawnVehicle()

    # SpawnedEvent hands us the actual fort_vehicle that appeared.
    OnRigSpawned(Vehicle:fort_vehicle):void =
        Print("Big rig has arrived on the map!")

    # DestroyedEvent has no payload — respawn a fresh rig after a beat.
    OnRigDestroyed():void =
        Print("Big rig destroyed — sending a replacement.")
        spawn { RespawnAfterDelay() }

    RespawnAfterDelay()<suspends>:void =
        Sleep(5.0)
        RigSpawner.RespawnVehicle()

    # AgentEntersVehicleEvent hands us the agent who boarded.
    OnAgentEnters(Agent:agent):void =
        if (Player := player[Agent]):
            Print("A player boarded the big rig!")

    OnAgentExits(Agent:agent):void =
        Print("A player left the big rig.")

Line by line:

  • @editable RigSpawner : vehicle_spawner_big_rig_device — a placed device MUST be an @editable field; a bare RigSpawner.RespawnVehicle() on an undeclared name fails with Unknown identifier. After compiling, drag your real spawner onto this field in the Details panel.
  • HeistText<localizes>(...) — the pattern for turning a string into a message if you later feed text to a UI/HUD device. There is no StringToMessage.
  • In OnBegin, we Subscribe each event to a handler method declared at class scope. Handlers can't be local functions.
  • Enable() makes sure the device is active, then RespawnVehicle() spawns the first truck (it also clears any previous one).
  • OnRigSpawned(Vehicle:fort_vehicle)SpawnedEvent is a listenable(fort_vehicle), so the handler receives the spawned vehicle directly (no unwrap needed).
  • OnRigDestroyed()DestroyedEvent is a listenable(tuple()), so its handler takes no parameter. We spawn a suspends function so the 5-second Sleep doesn't block.
  • OnAgentEnters(Agent:agent) — the enter/exit events deliver an agent. We narrow it to a player with if (Player := player[Agent]) before treating it as a player.

Common patterns

Assign a specific driver when a player triggers a button

Use AssignDriver to seat the interacting player in the rig automatically — handy for a "valet" or forced-getaway moment.

using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }

rig_valet := class(creative_device):

    @editable
    RigSpawner : vehicle_spawner_big_rig_device = vehicle_spawner_big_rig_device{}

    @editable
    CallButton : button_device = button_device{}

    OnBegin<override>()<suspends>:void =
        RigSpawner.Enable()
        RigSpawner.RespawnVehicle()
        CallButton.InteractedWithEvent.Subscribe(OnButtonPressed)

    OnButtonPressed(Agent:agent):void =
        # Put whoever pressed the button straight into the driver's seat.
        RigSpawner.AssignDriver(Agent)

Destroy the rig when an objective is reached

Call DestroyVehicle to remove the truck — e.g. a self-destruct objective or to deny escape.

using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }

rig_demolition := class(creative_device):

    @editable
    RigSpawner : vehicle_spawner_big_rig_device = vehicle_spawner_big_rig_device{}

    @editable
    DemolitionTrigger : trigger_device = trigger_device{}

    OnBegin<override>()<suspends>:void =
        RigSpawner.Enable()
        RigSpawner.RespawnVehicle()
        DemolitionTrigger.TriggeredEvent.Subscribe(OnTriggered)

    OnTriggered(MaybeAgent:?agent):void =
        # Blow up the current rig.
        RigSpawner.DestroyVehicle()

Disable the spawner after the round and stop respawns

Call Disable so the device stops producing/responding — useful at end-of-round cleanup.

using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }

rig_round_control := class(creative_device):

    @editable
    RigSpawner : vehicle_spawner_big_rig_device = vehicle_spawner_big_rig_device{}

    @editable
    EndRoundTrigger : trigger_device = trigger_device{}

    OnBegin<override>()<suspends>:void =
        RigSpawner.Enable()
        RigSpawner.RespawnVehicle()
        EndRoundTrigger.TriggeredEvent.Subscribe(OnRoundEnd)

    OnRoundEnd(MaybeAgent:?agent):void =
        # Remove the rig and stop the spawner from doing anything else.
        RigSpawner.DestroyVehicle()
        RigSpawner.Disable()

Gotchas

  • DestroyedEvent / VehicleDestroyedEvent / VehicleSpawnedEvent are listenable(tuple()). Their handlers take no parameter — write OnRigDestroyed():void, not OnRigDestroyed(X:tuple()):void mistakes. Only SpawnedEvent (a fort_vehicle) and the enter/exit events (an agent) carry a payload.
  • VehicleSpawnedEvent and VehicleDestroyedEvent are deprecated. Use SpawnedEvent and DestroyedEvent instead — SpawnedEvent even hands you the spawned fort_vehicle.
  • Placed devices must be @editable fields. A bare vehicle_spawner_big_rig_device{}.RespawnVehicle() won't reference the real placed truck. Declare the field, then assign it in the Details panel.
  • AssignDriver takes a plain agent, not a player. If you have a player, it already is an agent. If you have a ?agent from a trigger, unwrap it first with if (A := MaybeAgent?): RigSpawner.AssignDriver(A).
  • RespawnVehicle destroys the previous truck first. Don't call DestroyVehicle then RespawnVehicle expecting two separate steps — RespawnVehicle already clears the old one.
  • Sleep and other <suspends> calls can't run directly in a non-suspends event handler. Wrap them in spawn { ... } calling a <suspends> helper, as the walkthrough's respawn-delay does.
  • Enter/exit events deliver an agent, not necessarily a player. Narrow with if (Player := player[Agent]): before using player-only APIs.

Device Settings & Options

The vehicle_spawner_big_rig_device User Options panel in the UEFN editor — every setting you can tune.

Vehicle Spawner Big Rig Device settings and options panel in the UEFN editor — Boost Regen, Radio, Color And Style
Vehicle Spawner Big Rig Device — User Options in the UEFN editor: Boost Regen, Radio, Color And Style
⚙️ Settings on this device (3)

Setting names read from the panel above — may be partial; the screenshots are the source of truth.

Boost Regen
Radio
Color And Style

Build your own lesson with vehicle_spawner_big_rig_device

Generate a personalized, step-by-step lesson plan built around this object — grounded in this exact reference and our compile-verified knowledge base.

Build a lesson →