getconnections
Returns the connections of the specified signal.
function getconnections(signal: RBXScriptSignal): {Connection} | nil
Parameters
signal
- The signal whose connections you want to retrieve.
Examples
local DummyFolder = Instance.new("Folder")
DummyFolder.ChildAdded:Connect(function() return "Triggered" end)
local connection = getconnections(DummyFolder.ChildAdded)[1] -- First connection in the returned table
print(`{connection.Function()}, {type(connection.Thread)}`) -- Output: Triggered, thread
local CConnection = getconnections(game.Players.LocalPlayer.Idled)[1]
print(`{CConnection.Function}, {CConnection.Thread}`) -- Output: nil, nil
Last updated