firesignal

Calls a signal's connected callbacks.

Syntax

Signature
firesignal(Signal: table, ...: any) -> ()

Aliases

This function has no aliases.

Parameters

ParameterTypeDescription
SignaltableSignal supported by getconnections.
......anyArguments passed to each callback.

Returns

TypeDescription
()None.

Notes

Calls run synchronously on the calling coroutine. A callback error stops the operation and propagates to the caller.

Example

Luau
local Event = Instance.new("BindableEvent")
local Connection = Event.Event:Connect(function(Message, Count)
    print(Message, Count)
end)

firesignal(Event.Event, "Hello", 42)
Connection:Disconnect()
Event:Destroy()