Multiplayer replicating the Topdown Template from Unreal Engine 4 | Replication | UE 4.26.1

  Рет қаралды 6,307

Kekdot

Kekdot

3 жыл бұрын

👨‍🏫 My Patreon link:
/ kekdot
Download Project Files | Premium Tutorials | Courses
💦 Get our Game on Steam | Kekdot Center:
store.steampowered.com/app/14...
---
Get this project's code here:
www.unrealengine.com/marketpl...
Checkout a newer and more reliable version of this video here:
• How to reliably replic...
In this easy tutorial I show you how to Multiplayer Replicate the Top down template from Unreal Engine 4.
First I clean up all of the unnecessary code from the template and then show you how to easily replicate the top down gameplay. This example works great for the client-server (peer-to-peer), and dedicated server networking model.
This video was requested by one of our viewers. If you have a suggestion or a video that you'd like me to make in the future then be sure to leave a comment down below or join our Discord server!
#unrealengine4 #replication #multiplayer #tutorial #ue4
---
Welcome to Kekdot!
👨‍🏫 Our Patreon - Download Project Files | Premium Tutorials | Courses:
/ kekdot
🛒 Our Unreal Engine Marketplace Templates:
www.unrealengine.com/marketpl...
👾Join our Discord:
/ discord
📆 We upload videos on a weekly basis
📰 Follow us on:
Instragram: @kekdotyoutube
Twitter: @kekdot
Reddit: @kekdot

Пікірлер: 29
@Kekdot
@Kekdot 7 ай бұрын
Hey guys, 👨‍🏫 My Patreon link: www.patreon.com/kekdot Download Project Files | Premium Tutorials | Courses 💦 Get our Game on Steam | Kekdot Center: store.steampowered.com/app/1487180/Kekdot_Center/
@tmuhlhausen4091
@tmuhlhausen4091 2 жыл бұрын
You Sir.... Are Extremely Intuitive and have found the literal best solution i have been able to find over the last few months... keep at it
@Kekdot
@Kekdot 3 жыл бұрын
Hi everybody, We have uploaded a new version of this video in which we cover two more reliable multiplayer setups for replicating the topdown template! I highly recommend using this new setup for online multiplayer: kzfaq.info/get/bejne/bcqdoryU2LqplIE.html
@danielmoniz394
@danielmoniz394 3 жыл бұрын
What are the drawbacks to the approach here? Your newer setup is reliable, which strikes me as odd given this is happening on every tick. I had assumed after some basic reading that an unreliable approach would actually be better and have fewer issues if (say) one of the clients has high latency. This approach certainly appears to be more elegant.
@Kekdot
@Kekdot 3 жыл бұрын
The drawback of this setup is that the AI character which is locally controlled by the client here will be continuously corrected by the Server upon lag. Resulting in the client Character jittering due to the client version fighting with the delayed corrections it receives from the server. The other videos versions don’t have this jitter effect during lag because example 1 of the other video has client side prediction which makes it smooth, and because example 2 of the other video is not locally controlled and thus never in conflict/fighting with the server. (Note: the lag issue will not appear in Editor testing for the setup shown in this video but only when testing with friends that might have some higher latency) (Also note: during lag the newer version (example two of the second video) responds slower to your input, due to the character only moving as soon as the input has been received by the server, but it does not jitter atleast) It is true that this setup show here is good if it is important that the client side character must always be in the correct place, but then you’d have to accept the possible jittering.
@danielmoniz394
@danielmoniz394 3 жыл бұрын
@@Kekdot Thanks for the reply! You know, after responding to you, I found out that you can simulate latency in UE4. The issues you described are very clear once you do that. Just search "latency" in your project settings. After doing a bunch of reading, I'll be trying your other approach! My game can handle the action delay. Though I'm still a bit surprised this isn't handled better by default with this setup.
@Kekdot
@Kekdot 3 жыл бұрын
@@danielmoniz394 Glad to hear! Yea... UE4 really does not have a better setup for topdown AI multiplayer. I've seen a lot of people struggle with this on the forums aswell.
@danielmoniz394
@danielmoniz394 3 жыл бұрын
@@Kekdot I've actually found a setting which seems to completely remove the stutter. I haven't yet determined if there are any meaningful consequences. Try your original setup (with the PlayerController and Character owned by the client), go to the TopDownCharacter, and check Requested Move Use Acceleration. This instantly fixed my issue, even with large amounts of simulated latency. Again, I can't vouch for this in production, but I had never heard of the setting and will be trying it out. It's much simplified over the other approach and removes the aspect of the user having to wait for every action.
@stefanfrings1070
@stefanfrings1070 3 жыл бұрын
Thank you so much for sharing! As I said last time, your tutorials are so easy to understand and so helpful for people like me! I wish you all the best with your indie dev journey and your channel - you guys deserve it!
@Kekdot
@Kekdot 3 жыл бұрын
Appreciate you!
@Kekdot
@Kekdot 3 жыл бұрын
Hi Stefan! Checkout our latest updated video on how to reliably replicate the topdown template so that it is lag independent. The setup that I use in this updated video is great for online multiplayer: kzfaq.info/get/bejne/bcqdoryU2LqplIE.html
@stefanfrings1070
@stefanfrings1070 3 жыл бұрын
@@Kekdot Thank you so much for letting me know. I really appreciate that. I'll check it out... now :)
@Alex-bn4ht
@Alex-bn4ht 3 жыл бұрын
This and the comparison video betwen U4 and Unity made me go for Unreal Engine. I'm new here and had no idea what, where, why and how things work with these engines :D
@Kekdot
@Kekdot 3 жыл бұрын
Always great to start learning something new!
@Alex-bn4ht
@Alex-bn4ht 3 жыл бұрын
@@Kekdot but what if i want to do small movies? If you do this, could you show us some steps and what to do in this situation with Unreal Engine?
@Kekdot
@Kekdot 3 жыл бұрын
Sure! Ill add a sequencer tutorial to the list of tutorials coming soon! Expect it next week!
@Alex-bn4ht
@Alex-bn4ht 3 жыл бұрын
@@Kekdot omg, can i subscribe more than once? :))
@brannonharris4642
@brannonharris4642 3 жыл бұрын
I highly suggest sending your input to an AI controller. The AI controller posseses the Pawn (character) that is using the standard Character Movement component. Use a Nav Mesh and use AI Move To or write a nice simple behavior tree for movement tasks Unreal put a ton of love into that Character Movement component and how it replicates reliably.
@Kekdot
@Kekdot 3 жыл бұрын
Agreed! I’m making a follow up video on this today!
@tmuhlhausen4091
@tmuhlhausen4091 2 жыл бұрын
I am still open to suggestions personally but it's way more complex to use that method. As long as everything is being replicated the end result is the same regardless. Besides you should never have had to use an extra controller that's designed to control AI, not playable characters, and replication is replication pure and simple.
@vladchernushevich3786
@vladchernushevich3786 3 жыл бұрын
This solution doesn't seem to work if there is even a slight amount of network lag.
@Kekdot
@Kekdot 3 жыл бұрын
This is true since the AI movement is now server dependant. So if the clients connection to the server is bad then the Client is basically fighting the Server and that's why the jitter shows. I've figured out a fix for this issue and will post a new video on this tomorrow! (it is a bit more complex than the gameplay from this current video tho!)
@vladchernushevich3786
@vladchernushevich3786 3 жыл бұрын
@@Kekdot Cool! So far I've seen 3 ways to replicate top down movement: a server proxy character (which is obviously complicated to handle), the solution that you have here (which jitters) and checking "Use acceleration for paths" in the character movement component (makes the character slide around instead of turning normally). I wish epic would spend like 5 minutes of their time to make the top down template replicate properly.
@Kekdot
@Kekdot 3 жыл бұрын
Checkout our latest tutorial on how to reliably replicate the topdown template so that it is lag independent! kzfaq.info/get/bejne/bcqdoryU2LqplIE.html
@DaGamerDad
@DaGamerDad 3 жыл бұрын
How can you replicate your animations?
@Kekdot
@Kekdot 3 жыл бұрын
Checkout our Animation Replication tutorial! UE4 Animation Replication Tutorial | Multiplayer - Client-Server | Blueprints | UE4.26.1 kzfaq.info/get/bejne/atCIiNufm6qWZKc.html
Smart Sigma Kid #funny #sigma #comedy
00:19
CRAZY GREAPA
Рет қаралды 17 МЛН
Backstage 🤫 tutorial #elsarca #tiktok
00:13
Elsa Arca
Рет қаралды 45 МЛН
Must-have gadget for every toilet! 🤩 #gadget
00:27
GiGaZoom
Рет қаралды 8 МЛН
Why Solo Developers Should Use Unreal
10:55
Thomas Brush
Рет қаралды 317 М.
Multiplayer in Unreal Engine: How to Understand Network Replication
22:08
Nanite for Artists | GDC 2024
22:09
Unreal Engine
Рет қаралды 90 М.
ТЫКАЮ НА ХОМЯКА В AMONG US MINECRAFT!
21:57
EdisonPts
Рет қаралды 1,3 МЛН
skibidi toilet - season 24 (all episodes)
25:14
DaFuq!?Boom!
Рет қаралды 20 МЛН
[RU] BLAST Premier Spring Final 2024 - Day 5
4:46:21
RLG PARI RU
Рет қаралды 364 М.