Space Bowling

PROGRAMMING (Unity, C#)

3D bowling in space. The main challenge was the implementation of the scoring system compliant with official ten-pin bowling rules. Personal project.

Overview

  • Written in C#
  • Engine: Unity
  • Platform: PC/Mac, Android/iOS
  • Camera: follow-cam
  • Character: none (ball)
  • Controls: Touch, Mouse

Details

  • Implemented architecture, fully compliant with official ten-pin bowling rules, using test-driven development (TDD) with unity testing tools:
    • GameManager class holds game state.
    • GameManager requests next appropriate action from static action system class.
    • GameManager requests current score from static scoring system class.
    • Realtime scoring system takes possible bonuses from future attempts into account.
  • Animations with sub-state machines.
  • Manipulation of Unity’s physics engine.
  • Touch control system with swipe input for launching the ball.
  • Camera chases the ball until in front of the pins.

Scoring

First ball Scoring the first ball…

Second ball …the second ball adds to a frame score.

Hitting a spare 1 The first ball of the frame hit nine pins, now we hit this last pin with the second ball of the frame…

Hitting a spare 2 …which adds up to a spare.

Last frame The last frame is special. Had we managed to bowl a strike or spare with the first two balls, a bonus ball would have been rewarded.