Can I add MULTIPLAYER to my Open World Game in 4 HOURS?

แชร์
ฝัง
  • เผยแพร่เมื่อ 31 ธ.ค. 2024

ความคิดเห็น •

  • @NachitenRemix
    @NachitenRemix ปีที่แล้ว +66

    Dude it's actually unbelievable how much content and variety you can put out on your channel. It's all very high quality too. I hope you can also get some rest so to not suffer burnout ❤

    • @killereks
      @killereks ปีที่แล้ว +6

      lmao u gifted £0.55

    • @jpmallick367
      @jpmallick367 ปีที่แล้ว +20

      ​@@killerekswhat did u gift?
      Try to appreciate people who give rather than whine and criticise

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +22

      Thanks for the super thanks!
      heh don't worry, I do work a bit too much but not enough to burnout, I definitely plan to keep doing this for a very very long time!

    • @Blinkers2007GameDev
      @Blinkers2007GameDev ปีที่แล้ว +5

      @@killereksHe did give him something which counts for something. You, on the other hand...

    • @NachitenRemix
      @NachitenRemix ปีที่แล้ว +2

      @@Blinkers2007GameDev Yea, it's easy to criticize without doing their part xD

  • @upsidegaming7134
    @upsidegaming7134 ปีที่แล้ว +49

    Yes. Yes you can.

  • @Banaaani
    @Banaaani ปีที่แล้ว +10

    I remember learning to create multiplayer in school few years ago. It was quite difficult. Really glad to see that its this easy now! I will be adding multiplayer to my own game too, when it is closer to being done.

  • @ov3roger
    @ov3roger ปีที่แล้ว +3

    Man you really are amazing, I hope you never loose this philosophy of sharing and teaching without almost any cost, this is really respectable

  • @chuckdude514
    @chuckdude514 ปีที่แล้ว +37

    That's just impressive, gamedev tools really have evolved a lot throughout the years, now haven't they?
    Sometimes I feel a bit guilty for skipping so many complex problems that took many years and teams to be solved, but at the same time, we *must* use these if they are available, as it saves literally years of development time lol

    • @Blinkers2007GameDev
      @Blinkers2007GameDev ปีที่แล้ว +13

      Yeah why not. If they help me make games and in the future create a game dev company or atleast a big name for myself, why wouldn’t I use these? Games like super Mario galaxy would never be created in the 1940s because they didn’t have enough tools. But we do, so why not use them to create even better games? We make childhoods and, at the same time, we make money. Win win

    • @AlexGorskov
      @AlexGorskov ปีที่แล้ว +2

      ​@@Blinkers2007GameDevwell said, I agree

    • @Blinkers2007GameDev
      @Blinkers2007GameDev ปีที่แล้ว +2

      @@AlexGorskov thanks!

    • @JohnDoe-bo5yk
      @JohnDoe-bo5yk ปีที่แล้ว +1

      Depends on your goals, my main focus is programming, I wanna learn how to make it

    • @BoltRM
      @BoltRM ปีที่แล้ว +3

      @@JohnDoe-bo5yk How old are you? I'm in my 60s so time is precious & limited. =:P

  • @alec_almartson
    @alec_almartson ปีที่แล้ว +6

    This is a very nice summary on how to quickly add Multiplayer to our Videogames. 💯👍🏻
    Thank you.

  • @calvinms7503
    @calvinms7503 ปีที่แล้ว +4

    this is a good summary from you previous 6 hours lecture :D I love it

  • @systematic_god6849
    @systematic_god6849 ปีที่แล้ว +1

    truly impressive what netcode for gameobjects is able to do, but just as impressive is the depth of knowledge you have behind it to be able to implement multiplayer in just 1 day. Great videos keep it up!

  • @YoussefGamerYT
    @YoussefGamerYT ปีที่แล้ว +2

    0:44 timelapse its just him doing pen tricks

  • @Director414
    @Director414 ปีที่แล้ว +1

    Wow so awesome! As always, great video!
    If possible, make more videos on this topic! I would watch everything!! :)
    I thought multiplayer was basically impossible for an indie dev like me!

  • @rid6233
    @rid6233 ปีที่แล้ว +3

    NOW THIS IS INTERESTING

  • @AndersBergh
    @AndersBergh ปีที่แล้ว +1

    [Stands up and applauds] .... Very well done!

  • @PatrickEn
    @PatrickEn ปีที่แล้ว +2

    After 6 Months of learning Unity my next project will be a multiplayer game. This video gives me hope :D

  • @learnsmtheveryday01
    @learnsmtheveryday01 ปีที่แล้ว

    Love the thumbnail, Dani style, thank you for content

  • @GlassVaultStudio
    @GlassVaultStudio ปีที่แล้ว +3

    This is a good summary for a basic multiplayer foundation. I would not call this multiplayer until you can connect to friends via steam or googlePlay and play a multiplayer game. Still great content, thank you!

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +3

      Sure I could work on it for 30 minutes more and implement the Lobby and Relay that I've used previously, just with that it would be fully online
      unitycodemonkey.com/video.php?v=-KDlEBfCBiU
      unitycodemonkey.com/video.php?v=msPNJ2cxWfw
      If you want dedicated servers look into Game Server Hosting unitycodemonkey.com/video.php?v=IvCVFywNXMc

    • @GlassVaultStudio
      @GlassVaultStudio ปีที่แล้ว

      @@CodeMonkeyUnity true!

  • @MiDnYTe25
    @MiDnYTe25 ปีที่แล้ว +1

    I love how the characters have 3 feet wide shoulders lol

  • @ekzac
    @ekzac ปีที่แล้ว +1

    Question about safety: with the owner authoritative mode (ClientNetworkTransform) I would be able to modify the assembly of the build and send the character to any position I want, that's right? In this case, what could we do? Would Steam, for example, assure the checksum of the files in a safe way? Should we put some code to check player positions, or change to server authoritative mode and control it there?
    It would be interesting to see which common problems multiplayer games face, but I don't thing it's an easy thing to do.

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      Yes this has no cheat protection at all, the client can indeed be modified so that a player could move 10x faster. Using client auth is great for co-op games where you don't care about cheating. If cheating is a concern then the general rule is you should never trust the client

  • @frogmasto
    @frogmasto ปีที่แล้ว +3

    I always comment it but its true, another code monkey w :D
    also I love the newer style of talking over the video while on screen, looks good!

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Thanks for the kind words, I'm glad you like it!

  • @Btmodz
    @Btmodz ปีที่แล้ว

    I really like your new style with green screen and microphone.

  • @SMORIGINALS
    @SMORIGINALS ปีที่แล้ว +3

    Dinky Guardian has a bug,when you build something your player inside that object. You have to fix this you know who could be make house by sitting on Bricks.

  • @makra42069
    @makra42069 ปีที่แล้ว +1

    Like these new devlog style videos!!

  • @SwatHound
    @SwatHound ปีที่แล้ว +6

    Anyone have any opinions on Network for game objects vs Fishnet vs Mirror?
    Seeing what you did here makes me want to lean towards network for game objects, assuming Unity isn't going to drop this later...
    I'm a bit hesitant on diving into one of these networking tools and later realizing I "picked the wrong one".

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +5

      I haven't tried those myself so cannot comment but I've heard great things about all of them so I don't think there's any wrong answer

  • @RM-lh7on
    @RM-lh7on ปีที่แล้ว +1

    Please make a video about Unity Urp optimization/improving performance. Thanks!

  • @Huyuimu
    @Huyuimu ปีที่แล้ว +2

    we need more of this!

  • @MarushiaDark316
    @MarushiaDark316 ปีที่แล้ว +8

    Anyone else curious what the FloatingPointFix script does?

    • @TrentSterling
      @TrentSterling ปีที่แล้ว

      Yeah I feel like that was for the single player open world demo and this multiplayer demo didn't cover an actual big world with multiple players 😮

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +3

      It's from the Gaia asset that I used to make the world, it helps avoid floating point issues on huge worlds

  • @-OmShinde
    @-OmShinde ปีที่แล้ว +1

    Really like these type of videos.
    Please make a car game tutorial.(Pick up/drop game,race,)😄🙏

  • @LegendaryCombatForce
    @LegendaryCombatForce ปีที่แล้ว +1

    Please tell that how can we make a functional search bar on which if we search then it will show the list of online multiplayers
    And if we click on any player it will show option "add friend" if we click on add friend it will be added to our friends list

  • @MangoPulver
    @MangoPulver ปีที่แล้ว

    Absolute legend 😤😤

  • @PeterSedesse
    @PeterSedesse ปีที่แล้ว +1

    We are getting close to the mythical ' convert to mmorpg' button.

  • @georgedowell7747
    @georgedowell7747 ปีที่แล้ว +2

    I want to be like Code Monkey, when I grow up, except I m already a grown up 😂😂😂😂😂😂

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      heh it's never too late to start learning!

  • @Viski982
    @Viski982 ปีที่แล้ว

    We love you man love you so much ❤❤❤

  • @justliketherecord3912
    @justliketherecord3912 ปีที่แล้ว +1

    Will you make a video on syncing projectiles? Looking at the Galaxy Kittens example, you can see that projectiles do not have perfectly synced positions and they don’t hit enemies at the same time and it all looks off. Is that the case with these projectiles or are they actually “perfectly” in sync? This along with client-side prediction is the main blocker for my multiplayer project

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Yes exactly that's client side prediction, without it the projectiles will look out of sync since the client will always have some delay
      That is indeed a topic I'd like to research, basically you need to create a separate dummy visual on the player and spawn it right away then keep track of the state on the server and interpolate the dummy visual

  • @Chobi01
    @Chobi01 ปีที่แล้ว

    Best channel in the world ❤❤

  • @Damian_DH
    @Damian_DH ปีที่แล้ว +2

    Sup Code im copy pasting this comment from other video(asking for ideas). Me and some friends are working on a game that character is related to fire control. One question how would u tackle a grappling hook that looks like a Fire Hand going to the desired position and grabs the area to get hooked. At first i thought i can animate an arm with a morpher that stretches with a fire shader on the mesh but i realize this way the distance of the hook would always be fixed to the morpher/deformation distance. Another option is using LineRenderer with some kind of woodoo with a renderTrail but the thing is how i can get the initial position of the line renderer to add the hand(mesh) doing the animation. And another is using path creator that trace from point A to B a particle but im not sure whats the correct approach. Any idea?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      Yeah it sounds like the LineRenderer is the best approach, move the fire hand to the target position and use the LineRenderer to visually connect it to the shoulder
      You can access the LineRenderer through code to set the points, I did that in the minimap path video unitycodemonkey.com/video.php?v=Foztn0kDM7I

    • @Damian_DH
      @Damian_DH ปีที่แล้ว

      @@CodeMonkeyUnity god bless you man im gonna go check it out.

  • @MrOmega-cz9yo
    @MrOmega-cz9yo ปีที่แล้ว

    I agree with other commenters, CM is awesome! 👍👍

  • @АлександрКаминский-м7п
    @АлександрКаминский-м7п ปีที่แล้ว +1

    Me: I tried to add multiplayer 2 times already and it didn't work out.
    Code Monkey: how easy it is to add multiplayer now

  • @marveII0us
    @marveII0us ปีที่แล้ว +2

    Interesting title

  • @ZahoorAhmad-tc8ev
    @ZahoorAhmad-tc8ev ปีที่แล้ว +1

    I have idea for a game jame where the main foucs is to write clean code and you can inspect the code and rate that 😊

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      I have thought about doing something like that but it would be really tricky to organize and manage, maybe one day!

  • @1MrHam
    @1MrHam ปีที่แล้ว

    Wow That's awesome! One question, it works with a dedicated server or is local multiplayer? Keep the good work!

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      It can work with either, in this case for this simple demo I just made it local but I could have added Relay to make it online
      unitycodemonkey.com/video.php?v=msPNJ2cxWfw
      Or Game Server Hosting for dedicated servers
      unitycodemonkey.com/video.php?v=IvCVFywNXMc
      The NGO logic is all the same

    • @1MrHam
      @1MrHam ปีที่แล้ว

      @@CodeMonkeyUnity Thank you so much for the responses!

  • @MrMattyMoses
    @MrMattyMoses ปีที่แล้ว

    That was impressive!

  • @rapidstress2008
    @rapidstress2008 ปีที่แล้ว +2

    Hey, I have a weird want....
    My want is that can I take this Idea & build upon it?? I will add more features of course (not as fast as you though XD)
    I really want to build upon this game with my team members.... And release it!
    I totally understand if you don't agree, You spend time on this game!
    Anyways, Love from India ❤❤

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Sure! Feel free to use all the tools I mentioned in the previous video to make something similar

  • @skillmastersgames
    @skillmastersgames ปีที่แล้ว +1

    Nice video! Got a question, what is your microphone? I do devlogs with an English IA voice, thinking about start doing it with my real voice, but in spanish because I'm spanish 😅

    • @Blinkers2007GameDev
      @Blinkers2007GameDev ปีที่แล้ว

      Then do spanish English voice. Can fit in to certain games. Or just adapt your voice

    • @skillmastersgames
      @skillmastersgames ปีที่แล้ว

      @@Blinkers2007GameDev Not about games, just for the videos showing progress of games

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      I've got a Blue Yeti, it's the same one I've used since the very first video on this channel and still works great!

    • @skillmastersgames
      @skillmastersgames ปีที่แล้ว

      @@CodeMonkeyUnity thank you! And thanks for your content too, inspired and helped me a lot in this travel

  • @Arab_GameDev
    @Arab_GameDev ปีที่แล้ว

    at the same time which this video uploaded am implementing Multiplayer on my game using your netcode video as a reference a Big thanks for you

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Nice! Best of luck with that project!
      For my game Dinky Guardians I am indeed using Unity's Lobby and Relay

  • @Stefan-fg4tt
    @Stefan-fg4tt ปีที่แล้ว +1

    Can you host with netcode over steam? So that you don't need a server and there are no costs?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      Yes you can replace the Unity Transport for the Steam Transport

    • @Stefan-fg4tt
      @Stefan-fg4tt ปีที่แล้ว

      @@CodeMonkeyUnity great.. Thx

  • @XAyaDubX
    @XAyaDubX ปีที่แล้ว

    Hi Code Monkey, are you going to release an updated DOTS tutorial video? Like ECS or Job system. Thanks! :)

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Yeah I definitely want to, just need to find the time, I'm hoping to cover it this month

    • @XAyaDubX
      @XAyaDubX ปีที่แล้ว

      That would be so awesome. Thank you so much! Take your time. You produce amazing content. @@CodeMonkeyUnity

  • @DaElfer
    @DaElfer ปีที่แล้ว

    Ive been using Pun for my multiplayer setup and when i get the time i need to delve into unitys multiplayer system. It took me a while but i figured out how to do an RPG game with multiple scenes in multiplayer so player 1 leaves the village scene and goes to the forest scene leaving player 2 in the village. Then player 2 can join him. Usually in multiplayer it is 1 big map and all the players are on it. I had to fudge it to get it to work but does unity have a solution to this?

  • @canerkaska8355
    @canerkaska8355 ปีที่แล้ว

    Hey, great content as always! I'm currently working on a simple MMORPG, I haven't done anything about multiplayer and am considering using Fishnet. What would you suggest I do? And is joining players openly in the same server the same as just partying them up and having them join the game? Can every registered player join the game with the same setup?
    Thanks for your time in advance,
    Have a great day!

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      I've only ever used Netcode for Game Objects so no idea how it compares with Fishnet although from what I heard it is indeed good. In NGO yes you can join in the beginning or in the middle of a game.

  • @iiropeltonen
    @iiropeltonen ปีที่แล้ว

    Idea: 500 thousand sub special: Finally a tutorial on pen spinning 😊

  • @lgent2435
    @lgent2435 ปีที่แล้ว

    Will you make tutorial about FishNet? I really need it

  • @NeleN_Games
    @NeleN_Games ปีที่แล้ว

    an intersting question in my mind is for a server what specfic needed? I tried make my first multiplayer game with your tutorial about netcode. I had delay for client in my friend`s pc while we were concted with lan. the game was very simple 2 capsul moving around and shoot each other but for client, position of host was different ( about 2 point difference) .why could have delay with netcode while we were lan? ( client transform network used)

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      The NetworkTransform component has interpolation by default, so even on 0 ping it will look like it has a delay
      If you do a RPC or sync a NetworkVariable you will notice how the delay matches the ping perfectly.
      You can either use a dedicated server or something like Relay
      unitycodemonkey.com/video.php?v=msPNJ2cxWfw
      unitycodemonkey.com/video.php?v=IvCVFywNXMc

  • @thanhtruongcong9175
    @thanhtruongcong9175 ปีที่แล้ว

    That was amazing video. But can I ask you how can I remove delay when using relay Unity pls ?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      You can't remove delay, it takes time for the bytes to physically go from your PC to the other player's
      What you can do is implement Client side prediction to make the lag as invisible as possible

  • @zrizzy6958
    @zrizzy6958 ปีที่แล้ว +1

    greate video, but the green screen has some stuff to improve

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Yeah I think it's the camera which is just a basic webcam, need to upgrade to something better

  • @MaxDolotboy
    @MaxDolotboy ปีที่แล้ว

    I am currently working on an asset to put on the Unity Store. The thing is I would like it to work with multiplayer and without multiplayer. I made it works perfectly with multiplayer (Thanks to you haha). But now it doesn't work without the integration of Unity Netcode and if someone wants to create a solo game, it absolutly require him to "host" a server even tho nobody can join. How would you do it ? I am lost. I was thinking of creating a new namespace for multiplayer function and call them only if the gameObject has a component of Network Transform, but i'm not really sure how I could pull it off. Should I simply manage it as a second asset, or you think it would be possible to achieve what I want to achieve ?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Hmm for the users it might be better to make it as two separate assets, or include two separate packages, just like many assets include packages for URP and HDRP
      Or leave it like that and just tell the user to StartHost(); it does not require a multiplayer connection to work, the game that I'm working on shares the same code in SP and MP, it just doesn't open any public ports

    • @MaxDolotboy
      @MaxDolotboy ปีที่แล้ว

      @@CodeMonkeyUnity I understand, doesnt it requiere to StartHost, Have à NetworkManager to spawn the Player and etc ?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Yes but that can all work locally, it does not require an internet connection, you can watch my multiplayer course on the Lecture 24 Singleplayer to see how I implemented it unitycodemonkey.com/kitchenchaosmultiplayercourse.php

    • @MaxDolotboy
      @MaxDolotboy ปีที่แล้ว

      @@CodeMonkeyUnity Ok, big thanks for the help !

  • @Injabsful
    @Injabsful ปีที่แล้ว

    damn i need to start to learn multyplayer

  • @rickyfreddy6963
    @rickyfreddy6963 ปีที่แล้ว

    Can you make a tutorial on making a multiplayer turn based game? I can only find good ones for realtime games like this and don't know where to start. 😅

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      That is indeed something I'd like to cover, it should be pretty simple, turn based games would mostly be just RPCs

    • @rickyfreddy6963
      @rickyfreddy6963 ปีที่แล้ว

      @@CodeMonkeyUnity for me pretty simple is OK, a better starting point to learn multiplayer then immiately going Far Cry 6 on it haha

  • @-Bill-Clinton-
    @-Bill-Clinton- ปีที่แล้ว

    Hi I've got a question. Is it possible to instantiate an object on the client and then spawn that object on the server that way there is no delay for the client when shooting a projectile?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Yup that's exactly what you'd do to make it lag free, that's called Client Side Prediction, you spawn a local dummy object instantly so it's visible but you still trust the server to tell you if it hit something

    • @-Bill-Clinton-
      @-Bill-Clinton- ปีที่แล้ว

      I do actually have one more question though. Do you know if it's possible to have a network transform that can be affected by multiple clients at the same time because currently I only have a server network transform and an owner network transform and they can only be affected by the server/owner even with colliders and rigidbodies.

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Do you mean like a Ball in a Football game? Yes the host will own the ball and clients need to tell the host to move the ball, you cannot have everyone have ownership over the ball with a NetworkTransform
      But you could make a NetworkVariable that anyone can write to and use that

    • @-Bill-Clinton-
      @-Bill-Clinton- ปีที่แล้ว

      Ok, thanks for the help!

  • @jpmallick367
    @jpmallick367 ปีที่แล้ว

    Can u make a 3d(maybe not open world) game with only free assets

  • @DMIyce
    @DMIyce ปีที่แล้ว

    For multiplayer games im now mostly interested in how to sync to different servers i.e. chat servers account servers game servers etc. Do you have anything on this topic?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Hmm that's a tricky topic, I guess the best way is to use some cloud solution like Azure
      unitycodemonkey.com/video.php?v=qdE01Xg3y2A
      unitycodemonkey.com/video.php?v=EEQfSmK1nXA
      That way you can store the persistent data for the entire world and not just per server

  • @andersmalmgren6528
    @andersmalmgren6528 5 หลายเดือนก่อน

    So, how about single precision floats? If you take the players out a way from origin. How do you solve that?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  5 หลายเดือนก่อน

      Gaia has a component to solve exactly that, it teleports objects

    • @andersmalmgren6528
      @andersmalmgren6528 5 หลายเดือนก่อน

      @@CodeMonkeyUnity only on the clients

    • @andersmalmgren6528
      @andersmalmgren6528 5 หลายเดือนก่อน

      @@CodeMonkeyUnity For single player games Yes. But it doesnt work for multiplayer on the server

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  5 หลายเดือนก่อน

      Usually you don't allow players to get too far away from the host.
      If you want to enable that, then you need some complex logic where you basically have two worlds in one scene that are split apart

    • @andersmalmgren6528
      @andersmalmgren6528 5 หลายเดือนก่อน

      @@CodeMonkeyUnity the host handles all players and they can be on completely different parts of the map. It might work for p2p but no serious shooter uses that because of cheating reasons

  • @JrBrown-zo4fx
    @JrBrown-zo4fx 7 หลายเดือนก่อน

    I want to add multiplayer to Universal truck simulation can you help me out on that

  • @0darkwings0
    @0darkwings0 ปีที่แล้ว

    Hi, I am doing a mini version of Hearthstone as a university project, and I need to build the backend for the multiplayer with .Net Core, do you have any course on how to make a multiplayer with .Net Core? or any suggestions for good tutorials for that?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Hmm I experimented with some C# backend when I researched Azure, but didn't go too deep
      unitycodemonkey.com/video.php?v=qdE01Xg3y2A
      unitycodemonkey.com/video.php?v=bVqSLLvao78

    • @0darkwings0
      @0darkwings0 ปีที่แล้ว

      @@CodeMonkeyUnity Thank you for the links, but unfortunately it not helping :(

  • @iiropeltonen
    @iiropeltonen ปีที่แล้ว

    Actual question: If projectiles are spawned only on the server, does every client have input lag from firing to actually seeing the projectiles?

    • @DMIyce
      @DMIyce ปีที่แล้ว

      Smoke and mirrors. You spawn dummies on the clients.

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +3

      Yup correct just like this there is indeed input lag, that's where client side prediction comes in

    • @iiropeltonen
      @iiropeltonen ปีที่แล้ว +1

      @@CodeMonkeyUnity Did I hear: "Multiplayer Smoke and Mirrors - Tutorial"?

  • @yusefwilson
    @yusefwilson ปีที่แล้ว +1

    It is slightly unfair to say you have actually added multiplayer to your game without going into detail about hosting solutions and multiplayer game architecture (peer-to-peer vs dedicated server, etc.) I agree that NGO is a great tool but to truly make and release a multiplayer game it’s not as easy as it seems in this video.
    Did you decide on a hosting solution for this game? If so, which one?
    Great video either way but I thought those points were worthy of clarification.

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Sure I could work on it for 30 minutes more and implement the Lobby and Relay that I've used previously, just with that it would be fully online
      unitycodemonkey.com/video.php?v=-KDlEBfCBiU
      unitycodemonkey.com/video.php?v=msPNJ2cxWfw
      If you want dedicated servers look into Game Server Hosting unitycodemonkey.com/video.php?v=IvCVFywNXMc

  • @suicune2001
    @suicune2001 ปีที่แล้ว

    Oh wow! With these tools, do you have to worry about hackers/cheaters?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      Yeah, this simple implementation is client authoritative. Works great for co-op games, but if you're making a competitive game you should never trust the client

  • @Anvelir
    @Anvelir ปีที่แล้ว

    Why do you use A*, not built-in NavMesh in your project?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      I don't believe NavMesh supports creating multiple NavMeshes, so with that one I'd need one huge NavMesh for the entire world, whereas with A* I can make a map for the area around each castle

    • @Anvelir
      @Anvelir ปีที่แล้ว

      @@CodeMonkeyUnity thank you for the answer!

  • @MaxDolotboy
    @MaxDolotboy ปีที่แล้ว

    Can someone explain me why in the NPC script the part where if its not host then return has been added ?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      In multiplayer games you want only one source of truth, so you only want the EnemyAI to run on the server which then is replicated on the clients. If the clients are also running the AI then you will get out of sync quickly because the AI on the server will be doing different things than the AI on client1 and client2, etc

    • @MaxDolotboy
      @MaxDolotboy ปีที่แล้ว

      @@CodeMonkeyUnityBut if for example, the host leave the game and the game continues, then there is nobody left to run everything has a host. Is there something I am missing there ?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      If the Host quits the server quits, there needs to always be a Host or Server connected

    • @MaxDolotboy
      @MaxDolotboy ปีที่แล้ว

      @@CodeMonkeyUnity Thx for your answers, really usefull, keep doing what you are doing, you're the Best !

  • @GameDevGarage
    @GameDevGarage ปีที่แล้ว

    Can we create game on one of the clients? Without a dedicated server?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      Yes, you can make one player be the Host and the others Clients

    • @GameDevGarage
      @GameDevGarage ปีที่แล้ว

      @@CodeMonkeyUnity That's really cool 👍 I'll try it asap 🥳

  • @TheCoolestCrocodileEver
    @TheCoolestCrocodileEver ปีที่แล้ว +1

    Can you add an inventory in a week?

    • @cottxw
      @cottxw ปีที่แล้ว

      he can do that in less than a day

    • @TheCoolestCrocodileEver
      @TheCoolestCrocodileEver ปีที่แล้ว

      @@cottxw yeah but what about the items making the inventory is a thing creating the thing an id for every item it’s not gonna take him just an hour I’m pretty sure

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      I've actually been meaning to remake my old Inventory tutorial in a better way, but yup it can definitely be done unitycodemonkey.com/video.php?v=2WnAOV7nHW0
      NGO automatically handles creating unique id's for any object

    • @TheCoolestCrocodileEver
      @TheCoolestCrocodileEver ปีที่แล้ว

      @@CodeMonkeyUnity omg I should’ve expected that a tool could make the trick

  • @EnderElohim
    @EnderElohim ปีที่แล้ว

    so is this unity's solution vs mirror?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Yes NGO is a networking toolset just like Mirror, Fishnet, Photon, etc

  • @jaredcone
    @jaredcone ปีที่แล้ว +1

    But does it play well at 100+ ms ping?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      Just like this, no, this is the basics, on top of this you would add client side prediction to make it feel lag free

  • @NickPBond
    @NickPBond ปีที่แล้ว

    How many players would you use Netcode for? Will it cope with 4v4, 8v8, 12v12 ?

    • @tobias9790
      @tobias9790 ปีที่แล้ว

      Depends on what kind of game too...

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      There's no hard limit, depends on how much data you're synchronizing. If you have a 100 network objects you can support fewer players than if you have just 10 network objects

    • @NickPBond
      @NickPBond ปีที่แล้ว

      @@CodeMonkeyUnity understood. Thanks for the reply.
      I appreciate it's tricky with all the possible variables to give a definitive answer. In the past with old netcode, I wouldn't even consider it for anything more than prototyping. Now it's clear the new netcode can be used for a publishable game. I'm just trying to get an idea of it's threshold.
      I'm wanting to attempt a FPS of the order of 12 v 12 with x6 locational hits on the avatars, but minimal other netobjects.
      And while I'm here ... just want to say Thankyou for this excellent channel. Top job sir!

    • @ekzac
      @ekzac ปีที่แล้ว

      ​@@NickPBond I've not used netcode myself, and I've used UNET in industry for controlled environments (not internet game). But it sucks anyway. Netcode, in other hand, seems much more reliable. Considering old games, I would not say 12v12 is too much if implemented properly, but it depends on the server as well, and there are other things like, if it's internet there are ping, services, plans, etc..

    • @NickPBond
      @NickPBond ปีที่แล้ว

      @@ekzac Thanks, that's useful. :D

  • @flyingjudgement
    @flyingjudgement ปีที่แล้ว

    Hurray for lazzines! It seems pushing other things instead of mulltiplayer paying off ? Amazzing

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Uh? Pushing other things?

    • @flyingjudgement
      @flyingjudgement ปีที่แล้ว

      I wanted to learn Multiplayer Just when Unity Deprecated it. So I been holding off waiting for Unity to release the "new" Mulltiplayer module.
      In the mean time, I learned so many things about: Game Development, Math, Bussines and Managment. Its unreal how much a person can change and grow in 6 years.
      Off topick I realised I watched soo many of your videos ower the last 6 years that I picked up your accent a little...
      Really apreciate all your videos and hard effort. Thanks a lot!
      Good luck with your new release!
      @@CodeMonkeyUnity

  • @HaeriStudios
    @HaeriStudios ปีที่แล้ว

    Well this is fine as long as the game is intended to be played in a private lobbie because in a public lobbies you would instantly have people cheating since the player movement is not server authoritative.

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Which is perfectly fine in co-op games, just not in competitive games

  • @micaiahstevens8840
    @micaiahstevens8840 ปีที่แล้ว

    ... its easy to fool the masses.
    Did anyone else notice that when they cast a spell, the other hand did as well?
    It sounds easy and flashy, but little things like this, make it more difficult.

    • @micaiahstevens8840
      @micaiahstevens8840 ปีที่แล้ว

      Looks like it was fixed, I would guess it was when he added the network animation component.

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      You mean before I implemented the shoot particles? Yes before that I hadn't added the IsOwner check so the input was running on every player

  • @mikhailhumphries
    @mikhailhumphries ปีที่แล้ว

    Do you need to pay monthly for a server?

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Depends on what server solution you use. You can host your own server, or connect the players directly, or use Relay which has a generous free tier unitycodemonkey.com/video.php?v=msPNJ2cxWfw

  • @Etercy
    @Etercy ปีที่แล้ว

    u can !

  • @containedhurricane
    @containedhurricane ปีที่แล้ว

    I think Unity Relay/ Lobby is expensive compared to Epic Online Services and PlayFab

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Is it? The free tiers are extremely generous, unless your game is a mega hit you don't have to pay one cent

    • @containedhurricane
      @containedhurricane ปีที่แล้ว

      @@CodeMonkeyUnity I heard a game monthly API consumption is around three million API calls for 1000 daily active users, but UGS free tier only allows one million API calls per month. Maybe a game developer that has used UGS, EOS and PlayFab can clarify this

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      Not sure what you mean, neither of those tools is paid on API call usage, they're based on Bandwidth and CCU unity.com/solutions/gaming-services/pricing

    • @containedhurricane
      @containedhurricane ปีที่แล้ว

      @@CodeMonkeyUnity Unity mention about API call limits on that pricing page. Cloud Save has monthly 1,000,000 writes and reads limit, Economy has monthly 100,000 writes and 1,000,000 reads limit, Cloud Code has monthly 1,000,000 invocations limit

  • @saimmunir2841
    @saimmunir2841 ปีที่แล้ว

    Are you on discord? I'm looking for communities to expand my connection and learning process. If any of you know any community then please do share

  • @silentwarrior600
    @silentwarrior600 ปีที่แล้ว

    Code monkey I want to buy classes, teach me please 😂

  • @Caphalem
    @Caphalem ปีที่แล้ว

    Wait wait wait. I've seen this before. Let me try something real quick.
    why you dont try make a survival game (or you cant do that)

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      heh I'd love to try that! It's a fun genre, I hope someday I can explore it!

    • @Caphalem
      @Caphalem ปีที่แล้ว

      @@CodeMonkeyUnity Same :P I think this project could even be a good starting point although I'm not sure how it looks like under the hood

  • @a1a3a5
    @a1a3a5 ปีที่แล้ว

    bro is him

  • @ninuji69
    @ninuji69 ปีที่แล้ว +1

    He can

  • @gustavosalmeron2013
    @gustavosalmeron2013 ปีที่แล้ว

    DAMN you're handsome

  • @GameDevGarage
    @GameDevGarage ปีที่แล้ว

    I really love productivity but the "in 4 hours" like unnecessary pressurized things not my way. Sorry bro ♥️

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว

      It was not a time limit, I tried doing it and that's how long it took

    • @GameDevGarage
      @GameDevGarage ปีที่แล้ว

      @@CodeMonkeyUnity Congrats 🤘

  • @Algost_
    @Algost_ ปีที่แล้ว

    Yeah Indeed it work but you're not using à client-server architecture so cheating is rly easy, i don't know if it's à good lesson to teach "Yeah you can make multi easy" when it can be in the wrong way (if your game is competitive, with a ladder and rank system) but for proto can be usefull

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +2

      NGO is primarily meant for co-op games where cheating is not a factor. If you're concerned about that then yes never trust the client

  • @danellboy5757
    @danellboy5757 ปีที่แล้ว

    Nah, he can do it within 7 minutes

  • @kylopootis6489
    @kylopootis6489 ปีที่แล้ว

    MAKE THIS A FULL GAME ( or you cant?)

    • @CodeMonkeyUnity
      @CodeMonkeyUnity  ปีที่แล้ว +1

      heh if I wasn't already busy working on my Steam game maybe I would!

    • @kylopootis6489
      @kylopootis6489 ปีที่แล้ว

      @@CodeMonkeyUnity i really wanted to fly that airplane✈️✈️:( but ill be looking forward to your steam game too! ill wishlist it rn! love your videos thank you!

  • @JarppaGuru
    @JarppaGuru ปีที่แล้ว

    will it take 4 hours? lol

  • @hamsterbyte
    @hamsterbyte ปีที่แล้ว

    first

  • @jud.su.5developer895
    @jud.su.5developer895 ปีที่แล้ว +1

    Yes You can because only legend can do it. 🫡