BeardedManStudios / ForgeNetworkingRemastered

See various forks, also please join the Forge Community fork of Forge Alloy! -> https://github.com/ForgeAlloyCommunity/ForgeAlloy
https://twitter.com/FarrisFaulds
Apache License 2.0
1.49k stars 309 forks source link

RPC permissions change to be more authoritative #319

Closed andreivreja closed 4 years ago

andreivreja commented 5 years ago

By default only the owner will be able to send RPCs to a network object. You can also assign a master networking player that can call RPCs(while not being allowed to set fields) using:

networkObject.AssignMaster(NetworkingPlayer);

If you want to allow anyone to send RPCs(like before the change), you can use:

networkObject.AllowPublicRpcs = true;

AssignMaster and AllowPublicRpcs should be only used on the server.

phalasz commented 4 years ago

Closing as there have been no movement on this PR for a long time. Please address the comments on this and open a new PR with the changes when done.