Nice talk with excellent tips, congrats and thanks for sharing them
@kansisesi76315 күн бұрын
I still couldn't find a way to handle loading screens with MultiplayerSpawner. Spawning a loading screen instead of full level breaks all MultiplayerSpawner and MultiplayerSynchronizers in the level because of loading time difference.
@pro.giciel90845 күн бұрын
you can't wait everyone has loaded before ?
@kansisesi76315 күн бұрын
@@pro.giciel9084 I can load all levels to memory, or async load with rpcs to do that. First option takes too long on my game. Second option doesn't work when someone joins the game later.
@noid357119 сағат бұрын
It doesn't matter what Godot version you are using or even what game engine you are using. I rebuilt my first game with multiplayer a long time ago, so I can tell you right now that you don't even need new nodes. Sure new nodes are really good, especially the synchronizer, but I find my code to be more readable and I know *exactly* what it does even if I haven't seen it for a long time. 1. only the server can initiate the scene switch, other nodes can only ask it to start switching 2. server notifies all clients to start a transition animation (fade-out for example) and load in new scene/assets when the animation finishes 3. when the client finishes loading it notifies the server 4. server stores the ID of the client that finished and performs a check to see if everyone is ready 5. IF everyone is ready notify all clients to start the second half of the transition animation (ex. fade-in) and enable their controls Why do all this? - everyone stays synced, and the server stays in control - as it should - no player gets the advantage of performing input commands before other players due to faster load time - if someone disconnects you can handle it in multiple ways (wait for reconnect, terminate the lobby, continue the lobby with or without the option for said player to return etc.)
@kansisesi76314 сағат бұрын
@@noid3571 Thanks for suggestions. I had a similar setup in my previous project but it was a lobby game. Now I work on a coop game, I can work much faster with new nodes. I have several nodes that handle multiplayer visibility automatically, so in current setup I just place spawner and synchronizers and it works. Since there is no lobby, clients should be able to disconnect and join any time and host can load multiple levels at same time. When a client goes to another map I cannot block host's input. I need to asynchronously spawn level on host with no loading screen, and show a loading screen on the client. I will probably add asynchronous loading to MultiplayerSpawner instead of rebuilding everything with rpcs, this solves all problems I have.
@surplusking24256 күн бұрын
Cloud is overrated and overpriced. Just use non-cloud server.
@i_dont_know_my_name5 күн бұрын
What's non cloud server?
@marianosuligoy97505 күн бұрын
@@i_dont_know_my_namei believe he means you use a server to share each client's IP address and the you connect using peer to peer fashion
@anonymous-someusr5 күн бұрын
@@marianosuligoy9750 p2p is gonna cause dns leaks, etc... could be solved using proxies which in return is cheaper. additionally, you'd only need to store data temporarily. you don't need to store a history of stuff & text chats server-side. client-side works as well, unless it has been reported. also, make sure rate limits are a thing and it has great data validation. 1 unsecure line and your players pc is infected.
@surplusking24255 күн бұрын
Unfortunately both are wrong....There's a ton of way to without cloud to host a server and most of them are cheaper than cloud service, unless your game's usage is so low that covers free tier from major cloud services like Azure
@i_dont_know_my_name5 күн бұрын
stop answering a question without answering it, people like you or bots on the internet just write empty words. answer me straight or don't answer it.