Script Networking Utility

Recently I created a utility for scripters called the Script Networking Utility. This utility enables script-to-script communication without the person using the utility to create any of their own remote/bindable events or functions.

Scripts can send data to specific addresses, and other scripts can receive data sent to an address, handle the received data with a function, and even specify from what origin they want to receive data, such as the server, a specific client, any clients, or any source at all.

Example

Let's say we have a server script located in ServerScriptService. It's set up so that it'll receive and handle data to the address "myaddress" sent from any client
sn = require(script.Parent.SNModule)

sn.receive({
    address="MyAddress",
    origin=".CLIENTS",
    callback=function(data)
        print(data)
    end
})

Now let’s have a local script interact with that address by sending data to it. This will be sent from a client controlled by the player Shedletsky

sn = require(script.Parent:WaitForChild("SNModuleLocal"))

sn.send({
    address="MyAddress",
    origin=".SERVER",
    data="Hello World!"
})

The result of this interaction will be the server script printing out:

table { origin=“Shedletsky”, player=Shedletsky, data=“Hello World!” }

Security

This utility was built with security in mind. Clients can be restricted so that they cannot impersonate other origins (other clients, or the server) when sending data. In addition to that, clients can also be restricted so that they cannot receive data from any origin except the server.

Try it for yourself

This utility is available for free on the Roblox Creator Marketplace. Try it out for yourself and please consider providing feedback. I would like to know how useful this would be for other scripters, and if there are any improvements to be made.
2 Likes