Client-Auth/Self Broadcasts #275
Replies: 2 comments
-
There really is no sense of authority with RPCs or broadcast, other than perhaps ServerRpc w/ RequireOwnership toggled. Sounds like you want the equivalent of RPC RunLocally for broadcast. While I'm not opposed to this idea it does present a design problem. RPCs are generated via codegen while broadcast are not, so I cannot simply inject the local broadcasts. Another problem is that broadcasts are registered to methods and can be registered to multiple methods, each potentially with different logic. Even if I did find a way to inject the logic locally how would I know which to check? In the end you'd still have to somehow specify which method to run, and you could just as easily call that method yourself. |
Beta Was this translation helpful? Give feedback.
-
I explored this more and given the reasons above I don't think a run locally is very viable. It would be much more work to configure/use such a feature than just calling the local method yourself. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Allow the use for clients to send broadcasts to themselves. This would be a cool feature since it acts as a sort of observer pattern.
One use case would be for game chats where typically the server would broadcasts messages to the client to log chats to the chat box, but the client would also send these to itself, receives it, and logs the chat in a similar fashion.
A smart person once said "Since Client-Authoritative Target and ObserversRPSs are in development, then Client-Authoritative broadcasts would make sense too"
Beta Was this translation helpful? Give feedback.
All reactions