Tbh these 2 tutorials are really great. I hope you will do a part 3 where we have some BEANS movin' ya know nothing too crazy. As for some general YT tips, I would recommend not having background music while talking, the silent part where you just code are really hum disorienting (I checked like 2 times if I had my headphones plugged in lol) and explain a bit the bigger picture of what you are doing. As for code advice, I would suggest leaving more comments so if we need to look back at this code we understand what we did AND refactor... this code reaaallly needs some refactoring. Subbed and waiting for part 3 : )
Hey, thanks for the video. Question, How can you join a hosted game? I dont think there is a section where you show us how your friend joined the game? Just for testing purposes can you hard code the steam ID into the code and have the join button always try to connect to a certain ID?
หลายเดือนก่อน
I'm pretty late to this, but I'll leave this here just in case someone still wonders. Normally, you connect with steam (invite/join) features, just like any other steam game. And yes, you can hard code it, but I don't get why would you do that.
Great tutorial, would you be able to continue this into future such as starting the lobby with the player and using server authorative movement? Covering topics like client side prediction would be very useful, even videos like browsing lobbies that are public when pressing join
I have a few projects currently that I'm trying to wrap up, but yes I do plan on doing content based on the client netcode for gameobjects feature as well as what client prediction would look like on a server authorative model.
I’m having troubles with CurrentLobby?.Leave not initiating the callbacks when a player leaves / disconnects the lobby. They causes the PlayerCard to not be deleted. Have you seen this error?
Hey, did you find a solution? What the tutorial didn't show was that you need to connect to the steam lobby through stream aswell, so in OnGameLobbyJoinRequested you have to do a await CurrentLobby.Value.Join(); I was stuck on this for around 2 days wondering what's not working but it was simply just that you weren't connected to the Steam lobby.
Hey bro I actually found a bug, if the host readys up before a client joins, when the client joins the client doesnt see that the host has readied up already
yeah I see what you mean. I think the easiest fix would be to throw a bool in the updateclient rpc's depending on how you want your lobbies to work. You could also reset everyone's ready status when a new player joins too.
hey, add this method to NetworkTransmission, [ClientRpc] public void LoadNextSceneClientRpc(int sceneIndex) { SceneManager.LoadScene(sceneIndex); } and this method to GameManager, public void StartButton() { if (NetworkManager.Singleton.IsHost) { int sceneIndex = 2; NetworkTransmission.instance.LoadNextSceneClientRpc(sceneIndex); } }
Thanks for the guide m8 really helping me so far. I only have 1 issue atm with the clientid. For some reason it's always 0 no matter who connects or how many. Do you have any idea what this could be. There is barely if any documentation on this :S.
The documentation for that would be on unity's end not facepunch. Make sure your host is dishing out clientids properly. You can also use the built in start host button on the network manager object. Hopefully that points you in the right direction.
hey man really appreciate the tutorial but I have gone through it a couple times and I cant find the method that you apply to the onclick function for the join lobby button? I might just be an idiot and missing it. any help would be greatly appreciated
That's because it doesn't exist. There is an option through facepunch to manually enter a lobby id and join but I never did anything with it. Its easier to join through steams overlay and maybe in the future I will do something with it but its a pretty outdated way of connecting these days that its not a priority for me to implement right now.
@@Matt-hb4yx You must have steam open and then you can just use your friends list and join on a friend. If its an outside client and your having troubles make sure that you add the build as a non-steam game and you can use the overlay to join on a friend.
When you create a steam lobby it would be searchable if you had a unique steam id for the game. Doing so requires you to submit the game on steam and go through their process for publishing.
You helped me a lot!
Would love to see a part 3 on how to implement kicking, joining lobby through a lobby list...
Tbh these 2 tutorials are really great. I hope you will do a part 3 where we have some BEANS movin' ya know nothing too crazy. As for some general YT tips, I would recommend not having background music while talking, the silent part where you just code are really hum disorienting (I checked like 2 times if I had my headphones plugged in lol) and explain a bit the bigger picture of what you are doing. As for code advice, I would suggest leaving more comments so if we need to look back at this code we understand what we did AND refactor... this code reaaallly needs some refactoring. Subbed and waiting for part 3 : )
Excellent tutorial! It was easy to follow, and I learned a LOT! Thank you
Thanks for covering this topic. It's really useful to see an example implementation.
I am a bit late to comment but this video was just what i was looking for ty so much. I learnd alot from this :)
Bro, this is perfect. Thank you 🙏
Hey, thanks for the video.
Question, How can you join a hosted game? I dont think there is a section where you show us how your friend joined the game? Just for testing purposes can you hard code the steam ID into the code and have the join button always try to connect to a certain ID?
I'm pretty late to this, but I'll leave this here just in case someone still wonders.
Normally, you connect with steam (invite/join) features, just like any other steam game. And yes, you can hard code it, but I don't get why would you do that.
Incredibly helpfull.
Thank you :)
Part 3 ETA?
no rush, just found it really helpful :)
Great tutorial, would you be able to continue this into future such as starting the lobby with the player and using server authorative movement? Covering topics like client side prediction would be very useful, even videos like browsing lobbies that are public when pressing join
I have a few projects currently that I'm trying to wrap up, but yes I do plan on doing content based on the client netcode for gameobjects feature as well as what client prediction would look like on a server authorative model.
I’m having troubles with CurrentLobby?.Leave not initiating the callbacks when a player leaves / disconnects the lobby. They causes the PlayerCard to not be deleted. Have you seen this error?
Hey, did you find a solution? What the tutorial didn't show was that you need to connect to the steam lobby through stream aswell, so in OnGameLobbyJoinRequested you have to do a await CurrentLobby.Value.Join();
I was stuck on this for around 2 days wondering what's not working but it was simply just that you weren't connected to the Steam lobby.
Such a great video!
Could you also explain in another video how to do Matchmaking instead of joining or hosting own lobbies?
What are some good ressources for Facepunch with Netcode? Great Video
Hello, is it possible to create a Screen with a list of created lobbies and choose one to join?
great,have next video for play game
Hey bro I actually found a bug, if the host readys up before a client joins, when the client joins the client doesnt see that the host has readied up already
yeah I see what you mean. I think the easiest fix would be to throw a bool in the updateclient rpc's depending on how you want your lobbies to work. You could also reset everyone's ready status when a new player joins too.
Bro was that a train honking in the background at 4:30? :D
Okay so how would we then load the next scene with the start button once all players are there?
hey,
add this method to NetworkTransmission,
[ClientRpc]
public void LoadNextSceneClientRpc(int sceneIndex)
{
SceneManager.LoadScene(sceneIndex);
}
and this method to GameManager,
public void StartButton()
{
if (NetworkManager.Singleton.IsHost)
{
int sceneIndex = 2;
NetworkTransmission.instance.LoadNextSceneClientRpc(sceneIndex);
}
}
How could it worked in remote ? Mine does not working :c
Thanks for the guide m8 really helping me so far. I only have 1 issue atm with the clientid. For some reason it's always 0 no matter who connects or how many. Do you have any idea what this could be. There is barely if any documentation on this :S.
The documentation for that would be on unity's end not facepunch. Make sure your host is dishing out clientids properly. You can also use the built in start host button on the network manager object. Hopefully that points you in the right direction.
@@pixelfizz1718 It does tyvm :^)
hey man really appreciate the tutorial but I have gone through it a couple times and I cant find the method that you apply to the onclick function for the join lobby button? I might just be an idiot and missing it. any help would be greatly appreciated
That's because it doesn't exist. There is an option through facepunch to manually enter a lobby id and join but I never did anything with it. Its easier to join through steams overlay and maybe in the future I will do something with it but its a pretty outdated way of connecting these days that its not a priority for me to implement right now.
@@pixelfizz1718 We can't really test any of this to see if it works without a join lobby button.
@@Matt-hb4yx You must have steam open and then you can just use your friends list and join on a friend. If its an outside client and your having troubles make sure that you add the build as a non-steam game and you can use the overlay to join on a friend.
@Pixel Fizz Yea, I was hoping to be able to use Parallelsync, but this works too. Can you point me towards the documentation for using the lobby id?
Is this tutorial only working for Steam friends ? Or anyone can join us through a server browser
When you create a steam lobby it would be searchable if you had a unique steam id for the game. Doing so requires you to submit the game on steam and go through their process for publishing.
Great!
'Promo SM'