Yuari
Documentation

Once

Subscribes for a single fire.

Syntax

:Once(fn: function) -> table

Parameters

ParameterTypeDescription
fnfunctionThe function or callback to use.

Returns

TypeDescription
tableThe returned collection or table.

Description

Once is part of the Signals library. Signals in the VM share the RBXScriptSignal API and are pumped from the external tick loop.

The callback is registered immediately and remains subscribed until the returned connection is disconnected.

Example

workspace.ChildAdded:Once(function(child)
    print("first child:", child.Name)
end)

Notes

  • Signals share the RBXScriptSignal API across the VM.