C9 is a module system that allows streamlined Server-Client connection. No more folders with thousands of RemoteEvents/BindableEvents/RemoteFunctions/BindableFunction (eesh)
Setup:
Import the module into your studio, it should look something like this:
Relocate contents, module in ReplicatedStorage, Script in ServerScriptService like this:
(either of these can be within folders or nested in some way under these services)
Use away!
In-Script Usage:
Reference: local C9 = require(game.ReplicatedStorage.Library.C9):new()
RemoteEvent equivelant: C9:CreateEvent("REMOTE_EVENT_NAME")
example: local Event : RemoteEvent = C9:CreateEvent("BallEvent")
Calling the event: C9:Event("REMOTE_EVENT_NAME", TargetĀ¹, Parameters)
example: C9:EVENT("BallEvent", "All"Ā²)
Remote functions are the same except :CreateFunction() and :Function
Ā¹ - Target is only necessary from server to client
Ā² - āAllā target parameter fires it to all clients
How is this streamlined connection? itās just Like Event Based RPC made on top of Roblox remote events. Streamlined connection is what TCP provides to its above layers, the data goes out and in through a continuous data stream from which you can read to/from a specific amount of bytes.
I find that a lot of existing systems have unnecessary methods of binding the server and clients, itās just a personal opinion and I figured it might be helpful for someone
Iād say āunnecessaryā is an overstatement. Most popular networking libraries only need to be required to ābindā the server & the client. The rest are simple functions like .Event or .Function & .CreateBridge. Each of these libraries also offer a compact amount of optimization in some way or form, I am unsure if this does because I havenāt reviewed the source & thereās no information about it on the post.
This mostly just seems like a wrapper for the native remote events/functions. This is all coming from a constructive standpoint so donāt take it the wrong way.