You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Dat Nardo edited this page Jan 10, 2024
·
1 revision
RPCs (Networked Events)
Sending Data
To send a modded RPC, use:
SendModRPC(string sender, ModRPC rpc)
in your script:
Sender should be set to socketviewid, or the owner of another SocketView.
socketviewid is a variable that is able to be accessed when inheriting from CustomMod
ModRPC has the format of:
string modrpctype; //Unique RPC identifier
string parameters; //Custom data (recommended in JSON format)
string target; //Who will receives the RPC
Targets
"All": Sends to all SocketViews
"Other": Sends to all SocketViews that is not the current owner
"MasterClient": Only make the request be able to be received by the hosting player