Creating both Multiplayer (Coop) Offline Mode and Single Player Mode

I am in the development stage of a new game. I want to incorporate a coop mode and single player mode, but do not know the best way to go about this. I have done some research on Unity Netcode and some other resources, but still need some guidance.

Some core features for the Multiplayer mode I am looking into developing are the following:

  • Each player gets a character they can control
  • Split screen
  • Building with GameObjects that results in a final product/output worked on together.
  • Identifying options for character chosen by player. For example, option 1 is food maker, and option 2 is food producer, than each player can choose which option they want to be apart of, but both can not be apart of the same option at the same time.

The game will center on teaching about food access, nutrition, zero hunger,etc. and is a educational/social impact video game.

Thank you for your time.

Single Player == Host playing all by him/herself. If needed you can make client approval check always fail in singleplayer to ensure no players can join.

Thank you! So to make sure I understand correctly, when writing the game, just default to single player? So does that mean even if it’s “coop” when really it’s just two single players working together?

No, you make the game assuming that it is always networked. When starting singleplayer or multiplayer in both cases you start as a host. Only difference being that in singleplayer no one else joins, whereas in coop someone else can join. In fact the singleplayer only exists to serve a player‘s expectations but technically that player is still hosting a network game, although you may configure the network settings/code so that the sp game session cannot be joined.

"Just" disable the lobby creation part with a button click when starting a new singlaplayer session and you'll have yourself a singleplayer game.

1 Like

Thanks. I understand better now.