DEV Community

Jesús Pineda
Jesús Pineda

Posted on

Multiplayer Challenges

Hellu, and welcome back to another weekly update for A Wargame Without Compromise (WWC)!

We kicked off this week with our standard Agile rituals: reviewing PRs, merging code, and scoping the next sprint. The project is currently in a very healthy position. Our core gameplay loop feels solid, and while we still need to polish a few features, we had enough stability for me to continue the heavy lifting on the online multiplayer integration.

The Integration Reality Check:
Following the success of my initial Proof of Concept (PoC) last week, I moved on to a much more difficult task: integrating our existing single-player features into the networked environment.

My first victory was the spawning system. After refactoring some of our instantiation logic to ensure the server had proper authority, I successfully managed to spawn the different players along with their respective units across the network.

State Synchronization & Race Conditions:
Next, I tackled the pre-game flow. I created a new network-aware Game State to ensure all players were fully connected and synchronised before the match actually started. This proved quite difficult to sync; I initially ran into race conditions where the states were not updating simultaneously across clients. After some rigorous debugging, I finally managed to get the server to orchestrate the state changes correctly.

The Movement Synchronisation Hurdle:
The biggest challenge of the week, and the one that ultimately bested me, was unit movement. I attempted to synchronise the units' physical movements across the network. While I successfully managed to sync their rotation, I struggled to synchronise their actual positional movement and inputs without causing severe jitter or desynchronization. Networked movement requires a complex balance of client prediction and server reconciliation, and I am still figuring out the best architecture for our specific grid/movement system.

Reflective Practice: Managing Risk and Scope:
For the first time in this project, I was not able to fully complete my assigned sprint tasks. However, rather than feeling defeated, I am actually quite happy with the foundational results.

This experience brought up a critical aspect of software engineering: Risk Management. Networking is an exponentially complex feature. My main learning this week is that we must objectively assess our remaining time. As a team, we need to evaluate if it is truly viable to deliver a robust online experience before the module deadline, or if we should pivot and focus our remaining time on polishing a flawless local multiplayer or single-player experience instead.

Action Plan for Next Sprint Going into next week, my goals are split between technical research and project management:

  1. Transform Sync Deep Dive: I will dedicate focused time to researching networked Transform synchronisation (specifically position interpolation) to see if I can crack the movement bug.
  2. The "Go/No-Go" Meeting: I will present my findings to the team so we can make a definitive, data-driven "Go/No-Go" decision on continuing the online multiplayer development versus cutting our losses to protect the final grade.

Thank you so much if you got here!

See you next week for another update! 🛼🤟🏽

Top comments (0)