NetRay - High-Performance Roblox Networking Library

Any updates? I also have the same event constantly fire to all clients (after being fired to the server by a client) as a replication effort for sounds.

1 Like

I believe it’s the queue module, I think I gotta tweak it. Thanks for spotting it!
I also found an issue with batchin,g so I will fix both those issues tmrw once I am awake

sorry for the issues

1 Like

I identified the issue and have fixed it, the patch will be out soon

1 Like

Is there a boolean within NetRay so i can make the client yield until the server is loaded? ex. NetRayServer.Loaded

I am currently using Netty and this boolean makes my life easier (Could you provide a benchmark that also has netty included?)

1 Like

No, the issue is when you try to use GetEvent() before using RegisterEvent() on the server, but if you try without it registered, it will try to create it, and if it fail,s it will warn you

I am not familiar with this module

^ Its fairly easy to use and this also should mean it would be easy to benchmark

1 Like

What if the client loaded faster than the server? Would this also warn?

Netty lets me make sure that the client framework doesnt start until its fully prepared for the client to receive events.

local NettyClient = Netty.Client
NettyClient.Start()

while not NettyClient.Started do
	task.wait(1 / 30)
end

local Framework = require(ReplicatedStorage.Framework)
Framework:Start()
1 Like

To be honest the client shouldn’t really load faster then the server, unless you’re yielding or delaying the registering of remote events but yes it will warn if it doesn’t exist yet

Example usage on the client:

local Netty = require(Shared.Netty)
local NettyClient = Netty.Client

NettyClient.FireServer("Identifier", param)

Example usage on the server:

local Netty = require(Shared.Netty)
local NettyServer = Netty.Server

NettyServer.RegisterEvent("Identifier", function(player: Player, param: any)
	-- do stuff here

	return nil
end)

(It can be used the other way around, send from the server and register on the client)

1 Like

I will add it to the benchmark place and send the results once I have finished v1.1.1

Thankssss looking forward to the benchmarks

1 Like

Do you have a Roblox file for it? because I don’t use wally nor do I see a roblox download for it

does this support remote functions?

Yes give me one sec and ill get it and edit this message with it included

Netty module:
Netty.rbxm (16.2 KB)

1 Like

Yes, it’s called request you can check the documentation for more info

Ok

type or paste code here
1 Like

It failed to do anything when I was trying to test

Benchmark (2).rbxl (256.4 KB)

Check if I have set netty up correctly, and if not can you send me a fixed place

Ok i will check if you implemented it right

1 Like

NetRay v1.1.1

  • Batching is now optional again
  • Batching fires every heartbeat and when it reaches max flush size
  • Fixed Queue system preventing reciving messages on client

Note

If you plan to send large data multiple times a frame and aren’t worried about receiving it instantly and are more concerned with network usage then disable the firing of the events per heartbeat and just when the batch fills up this allows for more complex and large data to be sent in a single event saving a lot of network usage and aren’t worried about small increase in latency

You can also adjust the size of the maxflushbatch inside Dynamic Sender to suit your needs, it will become remote event dependant and a configurable option in the future

Edit Constants Module for more refined tuning etc

GitHub and Roblox have been both updated!

Thank you to
@weakroblox35 - spotting queue issue

1 Like

I have a problem when i try registering a remote event from a client script (not the RegisterRequestEvent)

 17:46:48.062  Players.zak_isla.PlayerGui.controller.Chat.chatscript:10: attempt to call missing method 'RegisterEvent' of table 

i dont know if its my fault for me using it incorrectly or it doesnt support client → server firing at all

1 Like