Unity networking service feedback
Consider this as feedback of people that really loyal to Unity and new Netcode for GameObjects and Unity multiplayer services. I am not alone with thoughts that will be explained next with this posts.
So story goes that a few people decide to make multiplayer game. Before that we created only single player…
The main trouble was that in our game main gameplay with physics
Two flying players hitting each others with stones, bricks and so on. We try to use photon “PUN2”. It is good to sent “coordinates” by network, but not physics. All that we get - really bad lags.
Second try Photon Fusion - it were better. It have lag compestation sistem, network rigidbody but… still we got lags and this did not fit. We ask at forum, watch at youtube, whole people says that physics is really hard to create, nomatter that you use Tick-based Simulation, or physics prediction or their “Full Physics Prediction” still we got lags from any hard “add.force”.
But photon have really easy"creating rooms" tool, and “quick match” and so on.
Next that we found was mirror. But trouble with Physics was same.
So we were VERRY HAPPY when found unity Netcode for GameObjects!! That a great product. We try to make all on our own server machine ( sort of dedicated server) and every thing was great! No lags, all physics are best! unity best!
And to all that we need matchmaking, lobbies, room creating and so on.
Next we decide to have dedicated server on PlayFab because they have matchmaking and again we have lost because from march on 2022 they changed their price for matchmaking and not its - Matchmaking Requests - $0.0000099 per request. sure this is not much, but as developers we knew that we will have about 100-200 request a day on different machines after this we found that we can join beta on Unity Multiplayer Services! That was happiest day in whole year.
We downloaded boss room (from 2021) that was great and we found familiar photon there
btw we got start to develop with unity multiplayer at February 2022.
Still we were missing lobbies and matchmaking in our game. This is same - player download game to phone - open it - click “play” - game searching for any free lobby room (if not - he create one automatically) - then two players have fun.
(Photon can easily make this!)
Then we start to play with Netcode for GameObjects documentation is really messi. Example
-
We decided to use dedicated server ok. We got application that have NGO - press start server ok. Come clients may press “start client” - they will connect good its cool and simple BUT the main trouble is
-
when server will “start game” - load next scene game will move on ok. BUT when another clients somewhere in world press “start client” they cannon connect because is game already running, so we need another game instance on server - why this did not describe in documentation? or maybe not another instance but use another port forwarding on server so that it will be another application.
-
We knew that we need lobbies for this task. This will solve problem of different instances ok. Unity Multiplayer Services are the best. ok -
We saw youtube tutorial “dapper dino” or “Dilmer Valecillos” they are really great for prototyping. But not for production. Same question - dapper dino - we create lobby. 4 players connect ok. game started, 5th player can not launch another game instance.
same as other youtube creators. they all creates “local server with 1 game instance”. ok so we look at unity documentation and find “Game Lobby Sample” great thing but… its writed with Observer pattern that does break typical unity code following via references. and its really hard to understand. -
Game Lobby Sample - something observe something that been observed by something that been observed…
Cmon unity we want to know how to create lobbie, how to connect and how to launch game, but not searching many dependencies in lobby sample. (photon and mirror really have more simplest examples, please unity do more and you will get new users of engine) -
“Lobby Hello World sample” really good and simple lobby sample which we manage to understand how it works. then we go to documentation - how create, how to connect, how to join and so on.
but documentation missing MAIN think why this tool is used → -
We created lobby - great, we connected players - great. and what next? how to exactly start game? how to connect people peer2peer or dedicated server? how to load new game scene?
this questions was new to us as unity developers.
We looked again Game Lobby Sample with its kung fu observers and saw that is uses relay connection ok -
- we opened documentation about relay, how to start relay, how to connect, how to set password ok. HOW TO START GAME? again. only think that we wave left is Dilmer Valecillos tutorial with relay set up and play game, but again its is only 1 server instance. and he uses his own Singelton with his tutorial.
So I asking please for all unity new developers who love this engine and wants to create with it →
-
Finlay get a nice documentation (some pages “not found”, some pages have old “unet is deprecated” some pages cant get difference of MLAPI and UGO )
-
Show us with simple examples (like mirror or photon do )
- how to create rooms/lobibes/relay
- how to launch different server instances
- ho to actually start the game after all that “connection done”
- Write manual or tutorial about all above, because all this journey that we have - many other people have also. I watch this forum and see people asking same questions as I with this long thread -
person asking how to integrate lobby with relay -
How to integrate Relay and Lobby
another person says that Game Lobby Sample is hard to understand because of its unlimited observers
another topic of golden path relay and lobbie
“1) How to create the relay and it’s lobby.
2) How to join the lobby and go from the lobby to the relay.
3) How to migrate hosts”
so I may say - people did not understand how to use unity network tools! Help them please!
As for my game we still did not figure out how to actually connect relay and lobby or how make dedicated server + manny lobbies on it
or how to actually start the game. Sorry for such long thread