Download

Things to avoid doing with multiplayer in mind for the future?

Hello, I’m just a beginner with 3 months into a project starting from 0 knowledge on scripting/blueprinting. I know certain things cause issues with multiplayer, and my goal is to have multiplayer in my game whenever it’s done, though that will take years. So, what can I avoid doing now to make integrating multiplayer easier later on?

I’ve seen on various topics people suggest avoiding event tick as it is based on frame rate, so I’m using delay loops triggered by an event instead. I would guess that the Get Player Character node should either not be used or be added onto at a later date, since index 0 would mean only the 1st player? I’m also avoiding using bindings in widgets as I’ve heard that is far more taxing on performance than simply making the code yourself to set texts and whatnot.

I just don’t want to make my game impossible/ridiculous to make multiplayer by using easily avoidable techniques, so help me out! Thanks.

You should not plan on making a single player game, then converting to multiplayer at a later date. If you are planning on making a multiplayer game, you should build it that way from the very start, you are going to have to remake “the majority” of things all over again to make it worl in multiplayer, becase things are done vastly different in multiplayer games as opposed to single player games…just sayin

Okay, but how do I do that? I don’t know where to make a decision based on the fact I want multiplayer.

Well that rabbit hole goes deep, the only thing i can tell you is to find and read/watch as many tutorials you can find about multiplayer and replication you can get your hands on, for instance I have 2 series of 3rd person shooter multiplayer tutorials for sale on my sellfy store, as well as some free information on my youtube page.

Figure out the type of multiplayer your idea / game really needs. For that, look to other games, but at the same time read threads about UE4 multiplayer ‘large-worlds’ limits and Physics Rewind etc… Plus basically anything that requires multiplayer/network coding-greatness or art-form to prefect. Making a single-player or split-screen game in UE4 is easy and sometimes possible using just BP.

Whereas Online Multiplayer is hell to perfect… Make no mistake about it, you are in the fight of your life! That’s why the advice often given for a first game is, never start with multiplayer. Not interested in hearing that? Well ok, I broke that rule in UDK too, but it was a far easier engine. Avoiding PC0 Hardcoding / Widget Binding is the least of your worries. Some topics to consider:

  1. Large Worlds / Map size limits / Jitter problems / Floating point Precision limits…
    Even after using origin-rebasing you need custom Syncing between clients / server

  2. Physics / Physics-Rewind / Prediction when using a non-deterministic game engine.

  3. General Replication design / strategy to avoid lag issues or other game killing problems.

  4. Networking / Hosting / Steam - Lobbies-Achievements / Server Travel / Load-balancing

  5. Anti-Cheat strategies plus Anti-Hack-strategies to protect against micro-transaction theft.

Figure out the type of multiplayer your idea / game really needs. For that, look to other games, but at the same time read threads about UE4 multiplayer ‘large-worlds’ limits and Physics Rewind etc… Plus, read up on basically anything that requires multiplayer/network coding-greatness or art-form to perfect. Making a single-player or Multiplayer split-screen game in UE4 is easy and sometimes even possible just using BP.

Whereas Online Multiplayer is hell to perfect… Make no mistake about it, you are in the fight of your life! That’s why the advice often given for a first game is, never start with multiplayer. Not interested in hearing that? Well ok, I broke that rule in UDK too, but it was a far easier engine. Avoiding PC0 Hardcoding / Widget Binding is the least of your worries. Some topics to consider:

  1. Large Worlds / Map size limits / Jitter problems / Floating point Precision limits…
    Even after using origin-rebasing you need custom Syncing between clients / server!

  2. Physics / Physics-Rewind / Prediction when using a non-deterministic game engine.

  3. General Replication design / strategy to avoid lag issues or other game killing problems.

  4. Networking / Hosting / Steam - Lobbies-Achievements / Server Travel / Load-balancing

  5. Anti-Cheat strategies plus Anti-Hack-strategies to protect against micro-transaction theft.

My inspiration for multiplayer would be things like Dark Souls and I guess even Watch Dogs, the drop-in invasion style PVP and even co-op. Who knows, that might be even harder than a shooter with 12v12 lobbies.

I guess my question then is: will I just be completely screwing myself over for later if I make an entire game and then try to add multiplayer, or is it still possible, yet incredibly difficult, later on?

I could just make it a purely singleplayer experience and it would be largely the same, but I feel for longevity’s sake, multiplayer adds hours and hours .Just look at Dark Souls, if there weren’t invasions, it would be dead already, yet there’s still multiple large channels on YouTube and the player count is quite good for a 2 year old game.

I guess my question then is: will I just be completely screwing myself over for later if I make an entire game and then try to add multiplayer, or is it still possible, yet incredibly difficult, later on?

I wouldnt do it, if i wanted multiplayer id make it that way from the start, but that is just me, i wouldnt say you cant make a single player then convert it later on, but it would essetially be the same difference as just making the game all over again IMO

If you are thinking on adding MP later, at least get familiar now with how things would be done in MP, things like not relying on gamemode for data (because if clients want to read from it, they won’t be able to, use gamestate instead), or knowing that giving commands for clients, you need to be owner of things… converting a game to MP is mostly a rewrite because from the start the game may be coded like “do this thing” instead of “tell the server to do this thing for me”…

Although in the end, even if you tried your best to keep things “MP Friendly” without doing MP, turning on the switch at a later time will nevertheless come with a big amount of work, so as @franktech said, It will be painful to start with multiplayer, and if you decided to do it, make sure you really know the type of multiplayer you are doing.

Well I suppose I am fortunate to know the exact kind of multiplayer I want, but unfortunate to have absolutely no knowledge on the subject. So far I’ve really only made the player character, 1 enemy and many widgets, I don’t know to what extent the “multiplayer workflow” mingles with BPs, whether it’s mostly for level stuff or literally everything you make needs to be made a certain way.

I guess if I want MP, I’d have to learn it sometime anyway, so I may as well learn it now before I set myself up for making the game a second time.

What about the basic like setting up the character movement animations, controls, is it like that it is a completely different process? I mean I would expect that the most of this part is the same?

basic movment is replicated by default, however when you get into crouch sprint prone aimoffset any montages they all have to be done a certain way

I’d suggest you to just browse through the multiplayer blueprint tutorials to get a starting point for your thought process.