Skip to content

Underwater Maze Mini‐Game

rp3002 edited this page Oct 15, 2024 · 8 revisions

Overview:

MazeUnderwater is an underwater mini-game in the main game, where the player navigates through a maze to find the lost fish eggs. A big tide has scattered the Fish eggs, and it's the player's mission to recover as many FishEggs as possible while navigating through the underwater dark maze, avoiding dangerous sea creatures. The player controls the lost fish in the maze, and must safely find the eggs and make their way back home. The number of eggs collected directly impacts the medal the player earns, with more eggs leading to a better medal and score.

When the game starts the screen looks like this: Screenshot 2024-09-29 at 9 59 45 PM

Background Story:

After a powerful tide swept through the underwater world, group of precious fish eggs were separated from their home. Now, the fish must brave the dangerous waters filled with angler fish, electric eels, jelly fish and also the maze obstacles to rescue the fish eggs and find a way home. However, it’s not going to be easy. The maze is dark, and visibility is limited. The player can only see a small radius around the fish, increasing the challenge of the game.

Main Objective:

The goal is to collect as many fish eggs as possible while avoiding enemies such as the angler fish, electric eels, jelly fish and navigating through the maze. The more eggs you collect, the better score and medal the player will earn at the end of the game.

Controls:

  • W S A D: Navigate the fish in four directions (Up, Down, Left, Right)

Game Mechanics:

  1. Maze Navigation:

    • The player moves the fish through a maze with limited visibility. Walls of the maze are represented as squares.
    • The maze design includes complex paths and traps, requiring players to carefully explore in order to find all the hidden fish eggs.
  2. Limited Sight Radius:

    • The fish has a restricted sight radius, meaning players can only see a small area around the fish. This adds difficulty as players need to remember or guess the path while avoiding dangers.
  3. Fish-Egg Collection:

    • The fish eggs are scattered throughout the maze. Collecting them is the main task of the game.
    • Each egg has a hit box, which allows the player to pick it up when they come into contact with it.

UnderWater Maze Pop-Up###

Before the Underwater Maze mini-game starts, a pop-up screen will appear, providing players with important instructions. It will explain how to control the fish as it navigates through the maze, detailing the key actions and movements required to avoid obstacles and enemies. The pop-up will also introduce the main character, the fish, and any special items or challenges it will encounter along the way. The game's objective will be outlined, including how to successfully complete the maze, earn points, and avoid losing health. Additional information such as how to pause/ restart and exit the game will be there.

Screenshot 2024-10-15 at 8 00 03 PM

Fish

The fish and it's particle effects are shown in the image below:

Screenshot 2024-10-15 at 1 58 00 PM

More information about the particle effect

Fish Eggs:

Screenshot 2024-09-29 at 9 59 57 PM Screenshot 2024-09-29 at 10 26 34 PM

Fish Animation

Screenshot 2024-10-15 at 7 59 10 PM
  1. Medal System:
    • The number of eggs collected determines the medal the player receives at the end of the game:
      • Bronze for a small number of eggs.
      • Silver for a moderate collection.
      • Gold for collecting most or all of the eggs.
    • Medals and scores are saved for future reference.

Enemies and Hazards:

  1. Angler Fish:
    • The Angler Fish is the main antagonist of the game. It chases the player throughout the maze using a pathfinding algorithm.
    • It deals 20 damage upon collision and poses a significant threat to the fish.
    • The Angler Fish has a bounding box that determines its hit area, and it chases the player based on the maze's pathfinding system.

The angler Fish turns red showing danger as the game difficulty increases:

Screenshot 2024-09-29 at 10 32 41 PM

Angler Fish Animation

Screenshot 2024-10-15 at 7 57 40 PM
  1. Electric Eel:
    • The eels have no light source when they are not charged and can appear to pop out at the player.
    • If the player is hit by an eel, the fish is stunned for a short time.
    • The eel's stun effect temporarily freezes the fish, making it easier for other enemies (like the Angler Fish) to catch up.
    • Eels also illuminate parts of the maze when they stun the player, giving the player a brief view of the surrounding area.
    • They deal 5 damage upon contact.

The electricity from the Eel:

Screenshot 2024-09-29 at 10 01 53 PM

Electric Eel Animation

Screenshot 2024-10-15 at 7 58 56 PM
  1. Jellyfish:
    • Jellyfish float through the maze and can deal 10 damage when they come into contact with the fish.
    • There are green and blue jellyfish.
    • The blue jellyfish have unpredictable movement, but are slow
    • The green jellyfish continually patrol between two points and are faster. The jellyfish add another layer of difficulty for the player.
Screenshot 2024-10-15 at 1 49 29 PM

Jelly Fish Animation

Screenshot 2024-10-15 at 7 59 32 PM Screenshot 2024-10-15 at 7 59 51 PM
  1. Octopus:
    • The octopus will be harmful, affecting the fish.
Screenshot 2024-10-15 at 1 46 53 PM
  • When the fish collides with the octopus, it will release a splash of ink on the screen.
Screenshot 2024-10-15 at 1 48 12 PM

Octopus Animation

Screenshot 2024-10-15 at 8 00 26 PM

Friendly Turtle:

  • The turtle will be a friendly creature, not an enemy.
  • It won’t harm the fish, but instead, it will carry fish eggs on its back.
Screenshot 2024-10-15 at 1 47 34 PM

Turtle Animation

Screenshot 2024-10-15 at 8 01 16 PM

Enemies (Angler Fish, Electric Eel, Jelly Fish and the Octopus):

Screenshot 2024-09-29 at 10 00 04 PM

Health and Damage System:

  • Angler Fish starts the game with 100 health points.
  • Each collision with an enemy reduces health:
    • Angler fish: 20 damage.
    • Jellyfish: 10 damage.
    • Electric Eel: 5 damage.
    • Octopus: 15 damage
  • If the fish's health reaches zero, the game ends, and the player is taken to the end-game screen.
Screenshot 2024-09-29 at 10 27 11 PM

Also, in the this game, indicators display the amount of health lost when the fish collides with enemies, showing how much is subtracted from 100, while collecting fish eggs shows how much score is added. Here are some images below for reference:

In the image below, the fish collects a fish egg, which increases the score by 1.

Screenshot 2024-10-15 at 7 36 34 PM

In these images below, the fish collides with enemies, showing how much health is subtracted from 100. **Note: The turtle does not indicate anything as it does not harm the fish.

Fish colliding with the enemy Angler Fish:

Screenshot 2024-10-15 at 7 39 11 PM

Fish colliding with the enemy Electric Eel:

Screenshot 2024-10-15 at 7 41 24 PM

Fish colliding with the enemy Jelly Fish:

Screenshot 2024-10-15 at 7 28 45 PM

Fish colliding with the enemy Octopus:

Screenshot 2024-10-15 at 7 42 32 PM

Maze/ Path finding

The MazeUnderwater game features a dynamic pathfinding system used primarily by the Angler Fish to chase the fish through the maze. The path finding algorithm allows the Angler Fish to navigate around walls and obstacles, following the fish's movements without getting stuck. This adds a level of difficulty, as the player must constantly avoid being cornered by the Angler Fish while searching for the lost fish eggs. The maze's complexity and the limited sight radius of the player make the pathfinding a crucial aspect of the game, forcing players to think strategically while exploring.

Status Effects

In MazeUnderwater, different enemies apply unique status effects on the player, making each encounter a new challenge. The key status effects include:

Stun (Electric Eel): When the player is hit by an Electric Eel, the fish is briefly stunned, losing control for a short duration. While stunned, the Electric Eel also illuminates parts of the maze, giving players a temporary advantage in navigating the maze. This effect is a double-edged sword that can help the player get their bearings, but also could lead to them getting hit by a combo attack from multiple enemies.

Pause (Enemies): When the enemies run into the player, they are stunned from a brief period. This prevents the player being hit repeatedly and dying instantly.

Scoring and Medals System

In MazeUnderwater, the scoring and medal system is based on the number of fish eggs collected by the player. The more fish eggs the player collects, the higher the medal they earn at the end of the game. The game ends once all fish eggs are collected or the player loses all health (out of 100). This system motivates players to explore the maze and strategically collect as many eggs as possible while avoiding enemies.

  • A score is calculated based on the number of eggs collected.
  • A scoreboard displays the player’s performance and awards a medal based on the number of eggs collected.

The High Score is now saved and carried over for the next gameplay session.

Screenshot 2024-10-15 at 1 50 20 PM

Medal Criteria:

Bronze Medal: Collect 8 fish eggs. Silver Medal: Collect 12 fish eggs. Gold Medal: Collect 16 or more fish eggs.

Screenshot 2024-10-01 at 2 32 14 PM

End Game Screen and the change of Screen Colour:

After the fish successfully exits the maze, the game will display an end-game screen showing the player’s score, collected medals, and the two options to retry or exit to the Main game screen, also the game's medals will change to reflect the player's performance:

Screen without medals: If the player collects fewer than 8 fish eggs (no medal earned).

Screenshot 2024-10-15 at 1 54 59 PM

Bronze Screen: If the player collects 8 or more but fewer than 12 fish eggs, corresponding to a Bronze Medal.

Screenshot 2024-10-15 at 1 53 00 PM

Silver Screen: If the player collects 12 or more fish eggs, corresponding to a Silver Medal.

Screenshot 2024-10-15 at 1 53 47 PM

Gold Screen: If the player collects 16 or more fish eggs, corresponding to a Gold Medal.

Screenshot 2024-10-15 at 1 54 20 PM

Lighting Design Decisions

  • A limited sight radius was chosen as it fit the theme of a dark underwater labyrinth while also leading to more tense gameplay.
Screenshot 2024-10-01 at 11 27 22 AM
  • The angler lighting was made to change colour from green -> yellow -> red-orange -> red as more fish eggs were collected and the difficulty of the game increased. This colour scheme was chosen as green is a colour typically associated with safety whereas red is typically associated with danger. This gives a clear visual indication of difficulty to the player and leads to more tense gameplay.
Screenshot 2024-10-01 at 11 18 47 AM Screenshot 2024-10-01 at 11 18 38 AM
  • Small blue and green lights were added to the jellyfish as this fits the underwater aesthetic
Screenshot 2024-10-01 at 2 55 56 PM
  • A white flickering light appears when the eel is charged with electricity or when it electrocutes the player. This was added to create more juice for the eel.
Screenshot 2024-10-01 at 11 23 07 AM Screenshot 2024-10-01 at 11 23 58 AM

Difficulty Testing

The game progressively gets harder as more fish eggs are collected. This makes the difficulty margin between the medal cutoffs more substantial. Four methods were employed to increase the difficulty throughout the game. These were:

  • Increase number of enemies
  • Increase speed of enemies
  • Dim lighting of player
  • Dim lighting of enemies

To fine-tune the rate of difficulty increase, user-testing was conducted to get an estimate of how many tries it took players to reach each of the medal cutoffs. Our ideal targets were: a Bronze medal should be achievable in 1-3 tries. A Silver medal should take 3-8 tries. Gold was made to be difficult for testers who played the minigame a lot.

Wireframes

Screenshot 2024-10-01 at 11 02 09 AM

UML Diagrams

image

image

PHOTO-2024-10-02-02-31-21

Sequence Diagram

Screenshot 2024-09-30 at 12 36 06 PM

Testing Plans

For a comprehensive overview of the testing approach, including details on the classes that have been tested as well as those that remain to be tested, please refer to the UnderWater Maze Testing Plan Wiki

Clone this wiki locally