cansignalreplicate
Checks if a signal can be replicated to the server.
Syntax
cansignalreplicate(signal: RBXScriptSignal) -> booleanParameters
| Parameter | Type | Description |
|---|---|---|
signal | RBXScriptSignal | The signal to check |
Returns
| Type | Description |
|---|---|
boolean | True if the signal can replicate |
Description
cansignalreplicate returns whether the signal supports replication.
Example
local detector = workspace:FindFirstChildWhichIsA("ClickDetector", true)
assert(detector, "This example requires a server-created ClickDetector")
local signal = detector.MouseActionReplicated
if cansignalreplicate(signal) then
replicatesignal(signal, game.Players.LocalPlayer, 0)
else
print("This signal cannot be replicated")
endRelated Functions
replicatesignal- Fire with replicationfiresignal- Fire locally