Verse Library verse

01 Fragment

Links a player entry event directly to a wall prop activation function, enabling immediate device interaction.

verse-library/direct-event-binding/01-fragment.verse

# This is a simple script to show the link
# We are creating a variable for our devices
my_crash_pad := CrashPad()
my_wall := PropMover()

# This function runs when the player enters the pad
OnPlayerEnter := func(player: Player) -> void:
    # This is the direct link!
    # We call the Activate function on the wall
    my_wall.Activate()

Comments

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