I don't think you should separate sending the header from the actual payload at 6:00. TCP sockets guarantee integrity of a single send payload but not the order of multiple sends in a parallel environment if multiple commands can be processed at the same time. So I think you should bundle both header and body into a single payload and ship it via a single send to be threadsafe no matter what. PS: I'm more used to raw socket programming so asio might actually facilitate the order in some way I don't know.
On the sender side, we're using single threaded modality and fully synchronous socket operations exclusively, so ordering won't cause us any headaches there. Of course for several other reasons I really don't like performing 2 sends for a single command, and I have a fun way of solving this problem a little later in this series :)
Hey sir, I am a beginner and i am little bit confused from where should i start consuming your content. I basically want to make a game using unreal engine 5 using c++ and blueprint. I want to learn c++ to the level where i can create a multiplayer game like cod, pubg etc. Can you help me and guide me as guru how can i achieve that please 😢
beginner, intermediate, advanced, 3d fundamentals those will get you pretty far, then you should switch over to tutorial materials specifically for ue5. You can also watch the Hardware 3d series after 3d fundamentals if you want to learn a bit about how game engines do their rendering
Merry Christmas, Chili!
Merry chilsmas :]
I don't think you should separate sending the header from the actual payload at 6:00. TCP sockets guarantee integrity of a single send payload but not the order of multiple sends in a parallel environment if multiple commands can be processed at the same time. So I think you should bundle both header and body into a single payload and ship it via a single send to be threadsafe no matter what.
PS: I'm more used to raw socket programming so asio might actually facilitate the order in some way I don't know.
On the sender side, we're using single threaded modality and fully synchronous socket operations exclusively, so ordering won't cause us any headaches there.
Of course for several other reasons I really don't like performing 2 sends for a single command, and I have a fun way of solving this problem a little later in this series :)
Famous last words at 9:31 as you proceed to make the mistake right away and forget to change CommandType to Title 😂
I considered staging some mistakes to illustrate the pains of manual serialization, but that one was 100% organic and the timing was impeccable :)
Hey sir,
I am a beginner and i am little bit confused from where should i start consuming your content.
I basically want to make a game using unreal engine 5 using c++ and blueprint. I want to learn c++ to the level where i can create a multiplayer game like cod, pubg etc.
Can you help me and guide me as guru how can i achieve that please 😢
beginner, intermediate, advanced, 3d fundamentals
those will get you pretty far, then you should switch over to tutorial materials specifically for ue5. You can also watch the Hardware 3d series after 3d fundamentals if you want to learn a bit about how game engines do their rendering