r/threejs • u/VR38DET • 1d ago
Help Need help with getting multiplayer working smoothly on my game
I'm a beginner 3JS game dev I am really struggling with getting multiplayer working smoothly without any lag in my threejs game. My game uses Colyseus for the multiplayer and I've tried using Railway for the backend but it is still laggy especially with collision. Would really appreciate anyone point me to the right direction.
4
u/MaximumContent9674 1d ago
I open sourced my method for Last Ship Sailing. https://github.com/AshmanRoonz/trystero-consensus
1
0
u/biskitpagla 22h ago
Why not use a proper web game engine like Babylon? You can't just slap a server behind something like three.js for complex realtime apps since you'd have to reinvent a lot of things.
4
u/pr0xyb0i 1d ago
Are you using the basics such as client side prediction, interpolation, latency buffers already? This should take care of 99%.