Search Unity

Help Wanted How do I make a networked turn-based game where players don't need to be connected all the time?

Discussion in 'Multiplayer' started by AlfakynAH, Jun 7, 2021.

  1. AlfakynAH


    Mar 1, 2021
    I wasn't sure how to word the title of this post, but I'll explain in detail here:

    My intention is to make a 1v1 strategy tabletop-like game where players will place 1 piece on a board per turn.
    I've seen several games (mostly for mobile) where Player 1 would play a turn, send the data of their actions, and they can then close the game. Player 2 can then open their game at any given time after that, see the actions from Player 1, play their turn, and send the data of their actions back to Player 1, who can then decide to play another turn at any given time.
    This is precisely how I want it to work for my game, but I haven't been able to find any info on how to do it.

    I have no experience whatsoever in making online games, but I am a game programming student, and willing to learn. I've attempted to start using MLAPI, following the most basic tutorials, but it already assumes someone will host a game, someone will connect as client, or there will be a server where both clients can connect to.

    I'm familiar with hosting, servers and clients as a concept, but I've never developed anything that uses them. I'm also familiar with the concept of P2P connections, but again, I've never set one up.

    I'm mostly looking for someone to point me in the right direction to start learning everything I need to accomplish this kind of turn-based functionality over the internet.

    My questions are the following:
    1. Am I right to assume that there would be an easier way to do what I want to do without the need for a host-client relationship?
    2. If I'm right about question 1, would a P2P connection be the right way to develop the functionality I want for my game? Otherwise, which would be the best/right way?

    Apologies if this might be too simple of a concept to ask in this forum, but I haven't been able to find any tutorials/guides after hours of googling.

    Thanks in advance!
    Last edited: Jun 7, 2021