top of page

Create Your First Project

Start adding your projects to your portfolio. Click on "Manage Projects" to get started

Refraction

Project Type

3D Game in Unity

Date

April 2023

Role

Programmer, Designer

A Cube-Based Puzzle Game

This game revolves around redirecting lasers using yourself and mirrors scattered in levels.

Using the starter pack provided to me by Singapore Polytechnic's lecturers, I was given free reign to build upon what was given and try to make an interesting experience out of it, while restricting myself to using only cubes and other primitive shapes.

In this game, player can use themselves and mirrors to redirect lasers into switches to trigger them. Players can press R to change which direction they redirect a laser by rotating themselves, but mirrors redirect lasers in a fixed direction.

I accomplished this by attaching an empty game object with a trigger to the end of the laser - created using LineRenderer - which causes refractive objects (mirrors and the player) to fire their own laser, or cause a laser switch to activate (resulting in a door opening).

I was also proud of my level design in this game; In the tutorial does not tell you all the mechanics explicitly, such as your ability to redirect lasers. Players discover this themselves when they have to move through a laser, causing a door to close until they move away from the laser.

I was also proud of my second level which challenged the player by providing them only one laser but multiple mirrors and tasking them with redirecting the single laser throughout a winding level until it reaches the end where it can be used to open the exit door.

Laser Emitter Script: https://pastebin.com/n34nSgas
Reflective Object Script: https://pastebin.com/vp2Gm614

Refraction game ZIP file download: https://drive.google.com/file/d/1dA8qelJTZXyRjBky7wzgiLEPIbT0v8E8/view?usp=share_link

Gameplay Video Link: https://youtu.be/q2V9p0QrLdM

bottom of page