Hi,
In my game, I’ve opted to only use a single RemoteEvent, which is used to every time I need to communicate between server and client (including sending relatively large player data tables, strings for notifications, etc)
This works very well for me, because I’m controlling all FireClient/FireServer requests using a module; Module:Send(key, …) is called in a script, the Module calls FireClient if on the client and FireServer if on the server. Then, in my script, I can call Module:Connect(key, function), for function
to be called whenever the RemoteEvent is fired with key
as the first argument.
My main point is – while personally better for organisation, are there any downsides to only using one RemoteEvent in the context of network performance? Is there any tangible benefit for using multiple RemoteEvents (for different key
arguments, in my game), compared to just using one, if the amount of network traffic is the same?
The Module:Connect method works by connecting to the RemoteEvent instance OnClientEvent/OnServerEvent, and then calling all the functions which match the key
argument, which I think is less efficient than connecting to specific RemoteEvents that only serve one function, but I was wondering more in terms of network bottlenecks.
–
I have a feeling this has a simple answer (which I’m assuming is “no”), and if that’s the case, I hope it’s appropriate to ask if there are any benefits to using multiple RemoteEvents that I haven’t thought of.
Also – foresaking initial simplicity – is there any benefit to invoking a RemoteFunction, rather than just firing a RemoteEvent to the server, for example, and the server firing back the requested data / return value / etc?
Thanks