Followers

Saturday, April 3, 2021

Co-op - First steps

The first steps towards co-op have been achieved! Using Mirror, Underlair now supports a Server-Client approach for co-op gameplay, where one player will host a session for other players to join in.

Bellow, is an in-game image showing 3 players connected, represented by placeholder 3d models and one first-person view. Each group of characters represents a player. You can see that, depending on the player count, the characters controlled will change accordingly. 


The multiplayer component already synchronizes player position and locomotion animations across all clients but there are still some aspects I need to take care of, like interacting with the world and making those changes visible across all players.

Another aspect I need to consider is having these 3D models reacting to the floor's obstacles and adjust their vertical position when using stairs. Once I get all this sorted out, I will make a video demonstrating the co-op in action.

9 comments:

  1. This is looking great and might be a really unique feature in this game. I wonder, mechanically, how will you handle the switch between turn-based combat and real-time movement if multiple players are doing different things?

    While I'm probably never going to co-op, might this possibly allow having AI rival parties as in Wiz7, racing you for certain quests and rewards?

    ReplyDelete
  2. This is a very good question. If you played Fallout 1 / 2, it will follow a similar route. When the player gets attacked or he attacks an NPC, the game goes into turn based mode. Once in turn based, there will be an initiative score that will lay down a playing order. It is possible to chase or be chased by an NPC in Realtime. Combat will only trigger when an attack is committed, either in melee or ranged attack.

    Anyway, this is all theoretically, I might end up changing the mechanics, and I will have to listen for player feedback on this regard. There is no point coming up with a mechanics no one will enjoy.

    There are no plans for NPC controlled parties at the moment. But I won't exclude itfor later stages of development. It will all depend on complexity, development time and cost.

    ReplyDelete
  3. Cool. That sounds like a tried and true solution for single player, but since you plan to allow multiple players, how will that work if one player enters combat but the others don't? Will time continue in real-time outside of combat while combatants at the same time take their time giving commands turn by turn?

    ReplyDelete
  4. There will be a threshold range for triggering combat. Players who come close into a unfolding combat will also enter into combat mode. But yes, you can hbave playes in real time while others in turn based. There are some things I still need to consider by this is the premise. Players will also have a time limit per turn, so. If a far away player wants to help another player in combat, he should rush in and the player that requires help will mostly take advantage of that timer by executing his actions when about to run out of time.

    Regardless, I foreseen that, players will stay together for the majority of time, because the combat will be calibrated for a 6 character party. Time will advance in realtime (day-night cycle) when at least one player is in real time mode. So, this factors in another strategic point to consider.

    ReplyDelete
  5. Cool. Purists might not like those timers in their turns, but it makes sense and I can see this working quite well.

    ReplyDelete
    Replies
    1. I'm planning having an option to disable the timer or extend the time limit itself, albeit, I will strongly advise playing without a timer. Nonetheless, I'll make sure there will be a decent amount of time for players take their time thinking while keeping a certain degree of pressure. Also, time is important so other players don't die of boredom. In a single player game, there will be no timer, unless the players wants to.

      Underlair will feature a set of options that players can configure to suite their play style, but this will also unbalance the game, naturally. Balacing Unerlair will revolve around a specific setup, which will be the recommend one for players to experience Underlair the way it was intended. But then again, the intended way will not be everyone's cup of tea, hence the configuration possibility - they will just have to "setup it up at their own risk".

      Delete
  6. You could look at how Divine Divinity does this. There are no timers. I quite like it.

    ReplyDelete
    Replies
    1. I do not recall a co-op mode in Divine Divinity. There was one in Divinity: Original Sin I and II, which I played alone, so I wouldn't know. Could you explain how it works?

      Delete
  7. This comment has been removed by the author.

    ReplyDelete