using { /Fortnite.com/Devices }
# This is our main script file.
# It connects the button to the fire.
MyButton := button_device{}
MyCampfire := campfire_device{}
# We define what happens when the button is pressed.
# This is called an "Event". It waits for action.
OnButtonPressed := func():
# This line runs when the button is clicked.
# It tells the campfire to stop burning.
MyCampfire.Extinguish()
print("Fire is out! Stay safe!")
# We connect the event to the button.
# When the button fires, this event runs.
MyButton.Pressed.Bind(OnButtonPressed)
Verse Library
verse
01 Fragment
Links a button press event to a campfire device to extinguish flames and output a console message.
verse-library/extrude/01-fragment.verse