VerseBuilderDocs

Docs/Core concepts/Devices & @editable

Devices & @editable

A device is a self-contained Verse class on your UEFN island. Every project has at least one. @editable properties are how UEFN designers wire devices together.

Last updated 2026-06-06

What is a device?

In Verse Builder, every file in your project compiles to a single Verse class extending creative_device. That class owns:

  • Rules — the WHEN/IF/DO logic that drives behavior.
  • Game data — variables, configs, phases, messages, inventories declared in the Game Data tab.
  • Helpers — generated functions the rules call (you never see them unless you peek the Verse output).
  • Bindings — references to other devices and UEFN actors, exposed as @editable.

Once compiled, the device shows up in the UEFN editor as a placeable actor under your VerseDevices folder.

@editable properties

@editable is a Verse keyword that tells UEFN: “expose this property in the editor so designers can wire it up.” Verse Builder emits@editable for:

  • Configs — every value you declare in Game Data → Config (e.g. max_enemies, round_time).
  • Device references — every UEFN device your rules depend on (a button, a volume, a teleporter).
  • Provider bindings — in multi-device packs, the link to the Provider device.

💡 Tip

Configs are the cleanest way to expose numbers designers should tweak without touching code. Anything wired to UEFN actors gets emitted as a typed@editable field automatically.

Device lifecycle

Verse Builder generates a standard skeleton for every device:

  • OnBegin<suspends> — runs once when the round starts. Initial subscriptions, default values, and pre-fill happen here.
  • Event subscriptions — every WHEN in your rules becomes a Device.SomethingEvent.Subscribe(...) call.
  • Player join hook — when state is per-player, the device hooks into the player-join event to initialize their slot.

Patterns

Solo device

One file, all your logic. Simplest start. Good up to maybe ~30 rules — past that, consider splitting.

Multi-device split

Split when domains diverge: Economy (variables, currency rules), Shop (purchase UI), HUD (display). Devices communicate through a Provider/Consumer relationship — see Multi-device.

Utility device

A small device dedicated to one job (e.g. “daily login bonus”, “leaderboard”) — easy to drop into multiple maps.

Gotchas

⚠️ Watch out

Device class name = file purpose. Verse Builder derives the class name from your device file name. Rename a device after wiring it in UEFN and you will need to re-wire it in the editor.

⚠️ Watch out

@editable bindings are not optional. A device referenced by a rule but not wired in UEFN will throw at runtime. The Composer emits the binding; the designer has to wire it.

📌 Note

Devices can't talk to each other directly except through bindings. There's no global registry of devices — each one is its own island.

What gets generated?

my_device := class(creative_device):

    @editable MaxEnemies:int = 10
    @editable SpawnButton:button_device = button_device{}

    OnBegin<override>()<suspends>:void=
        SpawnButton.InteractedWithEvent.Subscribe(OnButton)

    OnButton(Agent:agent):void=
        # actions from your DO list
        ...
Skeleton emitted for every device. Configs and bindings come in as @editable.

See also