top of page
Search

The Journey of Peiya!

Updated: Mar 29


GitLab Repository: Click Here

Download Now: Click Here


Game Overview

The Journey of Peiya is a third-person adventure game where players take on the role of Peiya, a young woman who embarks on a journey to become a true fisherman. Inspired by her friend, she must travel to Khanom Lake, catch fish from a specific list, and prove her skills under a time limit.


The game combines physics-based fishing mechanics with AI-driven fish behavior, requiring players to carefully time their casts and react to fish movement patterns. Players will also need to navigate obstacles while fishing, adding an extra layer of challenge.


Story & Gameplay

A young woman named Peiya has grown tired of city life. One day, she receives a letter from a friend saying:"Long time no see. I'm currently in Jelly Village. There's a lot to do here. I'm a snack fisherman now. If you are interested, you can come visit me."


Curious about this new way of life, Peiya decides to quit her job at Dessert City Inc. and travel to Jelly Village to meet her friend. Excited about becoming a fisherman, she tells her friend about her plan.

Her friend laughs and replies: "Sure, but you need to train at the lake first!" Handing Peiya a list of fish to catch, she sets off to Khanom Lake, determined to complete her fishing journey.


How To Play

  1. Move using W, A, S, D, and left-click to cast a fishing rod.

  2. Players need to collect over 50 points within a time limit.

  3. Each area has obstacles that hinder the players. Players must be careful not to be swept into the water by these obstacles. If a player falls into the water, the player will lose the allotted time.


Development Team

  1. Kanyavee Sematong

  2. Junlacak Juntaslip

  3. Theeramate Saeba


My Role

Gameplay Programmer


Core Mechanic that I created


Fishing Mechanics

This project creates a fishing system that combines physics, logic, and object interaction. The casting system functions like a gun firing bullets, but instead of bullets, fishing bait is generated. When the player left-clicks, the bait is propelled forward via a rigid body using the "AddForce"command. Finally, a cooldown system requires a 5-second delay to prevent the player from casting too rapidly.


Figure 1: Fishing mechanic script with physics-based casting and cooldown system.
Figure 1: Fishing mechanic script with physics-based casting and cooldown system.

The bass string incorporates Unity's physics system called Hinge Joint, connecting the hook and the fishing line. This physics simulates hinge rotation or movement, allowing the fishing line to swing back and forth according to the character's movement.


Figure 2: Example of the fishing line physics using a Hinge Joint in Unity, allowing the hook and line to swing naturally based on the character’s movement.
Figure 2: Example of the fishing line physics using a Hinge Joint in Unity, allowing the hook and line to swing naturally based on the character’s movement.

Nevertheless, there's a Collision Detection system that uses the OnCollisionEnter function to detect whether an object is a valid tag and then destroys it, simulating a successful fish catch.


Figure 3: Fish catch detection using OnCollisionEnter.
Figure 3: Fish catch detection using OnCollisionEnter.

Fish AI Behavior

The AI ​​system for the fish in this project is designed with an A-star movement pattern, meaning that waypoints are defined to make it appear as if the fish is swimming in a specific direction. The fish will move along the set waypoints, and when they are close to a point (less than 1 meter away), the system will immediately change its target to the next point.


Figure 4: Waypoint-based fish AI movement system.
Figure 4: Waypoint-based fish AI movement system.

Each AI fish will respond differently to bait depending on its type: easy_fish calls the "AddPointeasy" function, medium_fish calls the "AddPointmedium" function, and finally hard_fish calls the "AddPointhard" function. The score will depend on how difficult the fish is to catch.


Figure 5: Example of fish AI differentiation, where each fish type (easy, medium, hard) triggers a different scoring function, resulting in varied points based on difficulty.
Figure 5: Example of fish AI differentiation, where each fish type (easy, medium, hard) triggers a different scoring function, resulting in varied points based on difficulty.

Obstacles Environment

The obstacle system is designed to increase the challenge for players in the game. The pendulum is the first obstacle players will see. It uses physics-based movement (hinge joint) to create an obstacle that requires players to time their movements to avoid it. These objects have a box collider to detect collisions with the player. If a player walks into or is hit by these objects, the player will be knocked back.


Figure 6: Pendulum obstacle system using hinge joint physics and box colliders to create timing-based challenges and player knockback effects.
Figure 6: Pendulum obstacle system using hinge joint physics and box colliders to create timing-based challenges and player knockback effects.

The ice surface system utilizes Unity's Physic Material to modify character movement behavior for a smoother experience. This is achieved by setting the dynamic friction value very low, so that objects moving on this surface flow fluidly and don't suddenly stop when the player disables movement.


Figure 7: An in-game example featuring the integrated environment.
Figure 7: An in-game example featuring the integrated environment.

Tools Used:

  • Unity 2021.2+

  • GitLab

  • SmartGit


GitLab Repository: Click Here

Download Now: Click Here



 
 
 

Comments


bottom of page