Week 5: Boss Design, Range-Based Projectiles, and Production Challenges

Introduction

Three weeks have passed since my last update due to a combination of a holiday, full-time work, and delays in receiving collaborated models from the design team. Despite these challenges, I focused on two major technical tasks: implementing a multi-phase boss system and refactoring projectile logic to use range instead of lifetime.

Production Notes

  • Next Steps: The balancing documents will be integrated in the following week as the designers finalize their assets.
  • Collaboration Delays: The design team was unable to provide finalized models, offering only placeholder assets and balancing documents. This slowed visual progress but allowed me to focus on core gameplay programming.

Boss System Implementation

I began work on the boss enemy, which features four difficulty phases (with phases 1–3 implemented and phase 4 delayed). The boss’s mechanics include:

  • State Management: All mechanics are managed via timers, networked variables, and RPCs for synchronized multiplayer gameplay.
  • Phase Triggers: At every 25% HP lost, the boss spawns elite enemies. Players must defeat all enemies before the boss becomes vulnerable again; otherwise, enemies respawn after a set time.
  • Difficulty 2 – Isolation Mechanic: Every 5–30 seconds, the system checks if players are separated. Isolated players take damage, encouraging team coordination.
  • Difficulty 3 – Cleave Mechanic: Players must move to safe zones to avoid a damaging cleave attack.

This approach is similar to best practices for multi-phase boss design in Unity, where state machines and timers manage transitions and mechanics

Projectile Refactor: Range-Based Despawning

Previously, projectiles were despawned after a fixed lifetime. I refactored the logic so that bullets now despawn based on distance traveled, allowing for more flexible weapon balancing (e.g., sniper rifles vs. shotguns).

Before:

  • Projectiles used a lifeTime variable and despawned after a set duration.

After:

  • When the total distance exceeds maxDistance, the projectile despawns.
  • Projectiles now track their starting position and sum the distance traveled each frame.

This method is consistent with recommendations for ranged weapon systems in Unity and Photon Fusion, where projectiles are often managed by distance for gameplay variety and network efficiency.

Above is the changed code using Github

Reflection

Despite the lack of new visual assets, this sprint enabled significant progress on core gameplay systems. The boss’s phase logic and new projectile mechanics lay a strong foundation for future content and balancing. The experience also highlighted the importance of clear communication and asset planning in collaborative projects.

References

Leave a comment

Design a site like this with WordPress.com
Get started