What I learned

This was a deep dive into Unity and Game Programming.

I made use of 3D math and the Unity physics engine to control the main character and manipulate objects. I applied my knowledge of algorithms and data structures and games to implement gameplay features effectively. I used many features of the Unity Engine such as scripting, physics, UI and rendering.

Intrduction to Stray

Stray (not that one!) was a group project I did during a Game Programming course at the University of Calabria and also my first Unity project.

In this game the main character is a robot that tries to escape from a spaceship called Prometheus. The main enemy is the spaceship AI that tries to stop the robot by blocking doors and alarming other robots in the area.

The main mechanics of this game are:

  • Character movement
    • Walking
    • Running
    • Jumping
    • Crouching
    • Jetpack
  • Gravity powers (very similar to HalfLife2 Gravity Gun)
  • Interact with objects
  • Slaying two types of enemies: Drones and Mining Spiders
Stray
Overview of Stray’s mechanics.

My Role

I worked on several mechanincs using 3D vector maths concepts and Unity’s Physics library.

I also explored many Unity’s features:

  • C# Scripting
  • RigidBody Physics
  • UI
  • Rendering
    • All types of light
    • Light backing
    • Light probes
    • Reflection probes
    • Emissive materials
    • PostProcessing
  • Particle System

Finally, I also worked to the level design and music production for the game.

Character Controller

The main character movement is based on Unity’s CharacterControllerComponent. It checks for the users’ input and act accordingly to the current “state”. The state is gathered querying the geometry around the players using raycasts (e.g. checking if they are gorunded, if they can jump or stand up). The actuation of the movement is not physics based, every tick the next position in calculated and used to move the underlying CharacterMovementComponent.

Gravity powers

Forces are used to implement the main character’s powers. These powers let the player grab, for a certain duration, every object that are interactable (even the enemies). This can be used to reach high places or throw object to enemies (or enemies to walls).

Updated: