magnopus-opensource / connected-spaces-platform

"An interoperable communication library for the spatial internet."
https://www.magnopus.com/csp
Apache License 2.0
89 stars 12 forks source link

[OF-1437] refac: Introduce a new Event Bus for SignalR Multiplayer events #533

Open MAG-OR opened 1 week ago

MAG-OR commented 1 week ago

The current event handling in MultiplayerConnection is being replaced by a more intuitive and extensible EventBus implementation. A new EventBus class is introduced, which manages the event handling in place of MultiplayerConnection. The SystemBase class is extended to handle default event registration, deregistration and default deserialisation. Each system can override these functions as needed. Clients are still able to register using callbacks, as before, the only difference being that the EventBus is now handling it.