Verse Library verse

01 Device

Declares a custom device with an editable timer and prints a startup message.

verse-library/verse-devices-reading-and-using/01-device.verse

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

arena_controller := class(creative_device):

    @editable
    RoundTimer : timer_device = timer_device{}

    # OnBegin runs once, automatically, when the island starts.
    OnBegin<override>()<suspends> : void =
        Print("The arena is open!")

Comments

    Sign in to vote, comment, or suggest an edit. Sign in