Skip to main content
GameDev.net gamedev.net
🔒 Locked

Libraries for online web game multiplayer?

Started by Caleb Adam Jan 19, 2018 at 4:05 PM 6 replies 5k views
Original Post
Caleb Adam
Caleb Adam

I want to make a html5 canvas / javascript game, similar to agar.io. I know a little node.js, and I think I understand the way online multiplayer works, but now that I do understand I realize it's gonna be a ton of work if I want to do it from the ground up with something like socket.io. My question is: are there libraries that can help with the multiplayer aspects of my game (sending game packets, etc.), and if so, is the performance for that library fast enough to run my game? (has a latency at least as low as agar.io)

Caleb Adam
Caleb Adam

I did find Lance, but the list of games built on it is suspiciously small. I'll look into it, but please post your recommendations!

caymanbruce
caymanbruce

I write my game server from scratch. I don't think socket.io can handle the workload of any serious multiplayer web game, try to use ws or uws library.

Caleb Adam
Caleb Adam

Thanks, by now I’ve decided to learn Unity and release my game for WebGL. (I’m assuming the networking on that is reasonably fast and reliable, Unity is a very widely used game engine) That way I can release for any other play form if I want later. It’s encouraging to hear that someone actually has built their game from scratch with web sockets though!

hplus0603
hplus0603


I don't think socket.io can handle the workload of any serious multiplayer web game, try to use ws or uws library.


I don't think there's a significant difference in what server-side socket library you're using. The main problem is that all websockets use TCP, and that you will need to funnel player counts across multiple threads (hard with Node.js) and multiple servers (hard in general.)


enum Bool { True, False, FileNotFound };

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.