#When should multiplayer be implemented?

1 messages · Page 1 of 1 (latest)

coral tiger
#

I'm creating a multiplayer game. This is my first time interfacing with a game this way, and I wanted to know when I should actually start implementing netcode, etc. Looking online, I've seen that it's fine to do it both at the beginning and at the end, but I'd prefer to discuss it with someone who may have encountered the same question/problem.

When did you do it?
If you did it at the end, did you encounter any problems converting everything?

finite ginkgo
#

It ought to be at the very beginning. Waiting until later means having to rewrite whole parts of the game and it's a huge mess. It's poss but I would never recommend doing it that way.

coral tiger
#

Then I don't understand another thing, looking around I saw that some people make 2 or 3 scripts, one for the single player game and one for the multiplayer one, maybe because some things change, others instead use the same script simply changing it to network and implementing what is needed

#

I also thought it would be better to do it at the beginning, but I'm having a lot of difficulty transforming a script that works very well in single player into multiplayer.

#

Even if it's just for the simple fact that I want to do something in multiplayer and that thing isn't needed in single-player.
I've seen that it would be convenient to create, for example, two prefabs for each object, one for single-player and one for multiplayer. Although I don't know if it's very efficient, in the end it's excessive duplication in my opinion. Is that possible, or am I wrong?

#

Then I saw some people make everything seem like it was just multiplayer, and then make it work in single-player too.

I'd like to know what the best way is; I'd like to avoid having to redo everything from scratch.

finite ginkgo
#

The easiest way to make single player act the same as the host connecting to itself. That was you don't have to code everything twice. There is even a SinglePlayer Transport to help with this

coral tiger
#

ok, thank you

midnight stirrup