Babylon.js + Colyseus, New Tutorial on Multiplayer

Dear BabylonJS team,

First of all, thank you for the Babylon.js, the most awesome 3D engine. We(Colyseus team) have created a tutorial, a step by step guidance for multiplayer networking using Colyseus. And also have opened a pull request on the documentation here, Please let us know your thoughts.
We appreciate your feedback and welcome any change.

Thank you and hope to hear from you soon! :smiley:


Just getting started with Colyseus so this is very timely and welcomed, thanks !

I am so glad there is some stuff starting to come out for BJS. But unfortunately this does not help AT ALL.

You CANT just apply a LERP with a constant 0.05 smooth amount to your movement. This kind of SMOOTHING leads to floaty movement with all the easing. There is no way you can make a game with real game player movement like this.

I am really looking for how you make a Real Multiplayer Game…All the way thru. I see that you wire up to the onChange and then move your entity from there. But that is nothing.

You really need to be buffering network updates

You really need to be playing about 100+ milliseconds behind server

You really need to be interpolating all the times in between server updates

And finally, you really need to be SMOOTHLY moving from current position to the interpolated position, taking into account the velocity of the original client entity movement.

I was really hoping the guys who made the API (Colyseus) would have examples of making a real world game with their api.

I have to really try to tear apart the unity example and try to what i can (something you just cant do that way in javascript as they are doing in C#… No Threading… No Separate Ping Pong check for latency)

Just really need a BJS example showing the things above


Hey @MackeyK24, you’re spot-on on your observations for a fast-paced real-time game. This first tutorial we’ve prepared is more targeted for beginners, we do plan on having more tutorials for in-depth client-side techniques considering input + prediction + interpolation in the future.


Welcome @endel

Nice to see you again… Thanks for the input on the Colyseus forums as well

Can’t wait to see your more advanced tutorials

Especially buffering and smooth interpolation

I am having slight playback issues I can’t seem to find the cause of. But if you guys make an advanced example on use your Network Entity Room State example and the entityUpdate

I can see how are smoothly moving around synced transforms


Very useful tutorial!

Currently the glitch example doesn’t displayed in the Docs, PG examples cannot connect to the server.

1 Like

Hi Labris,

Thank you so much. Will fix this ASAP.

Best regards.

1 Like