Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for i, v in pairs(game:GetService("ReplicatedStorage")._NETWORK:GetChildren()) do
- -- Check if the name contains the character '{'
- if v.Name:find("{") then
- local args = {
- [1] = "Titan"
- }
- -- Check if v is a RemoteEvent and can FireServer
- if v:IsA("RemoteEvent") then
- v:FireServer(unpack(args))
- elseif v:IsA("RemoteFunction") then
- -- If it's a RemoteFunction, use InvokeServer
- local result = v:InvokeServer(unpack(args))
- print("Result from InvokeServer:", result) -- Optional: Print the result
- else
- print("v is neither a RemoteEvent nor a RemoteFunction.")
- end
- end
- end
Add Comment
Please, Sign In to add comment