06 Hours in: GDHQ Certification Devlog

Mohamed Hijazi
Nerd For Tech
Published in
3 min readSep 2, 2021

Previous devlog (04 Hours In: GDHQ Certification Devlog), I added player levels through which the player will upgrade his weapons and added an enemy prototype. Now I made some improvements to the levels and to the player’s projectiles.

New Projectile

The new projectile is a little faster than the normal laser bullet, this one is an electrified laser that travels faster and does higher damage.

New Laser

Player Health

I added the first iteration of player’s health. Basically the player will have be able to take 6 shots. I first thought of making the player lose all his upgrades if he takes damage but this would be a little too harsh (maybe I could this if I introduce difficulty), then I made him lose 3 levels per 1 damage which is a little more forgiving but punishing as well.

Player losing levels upon taking damage

Level Manager

My first iteration of levels where added directly to the Player’s attack script just to get a feel of how levels should work. Now I refactored everything and created a player level manager script that is responsible for managing upgrading the player per level, degrading levels when he takes damage.

Laser Bug Fix

As mentioned before, the many player and camera rig are being controlled through timeline to give me acute control of the movement in the scene. This created a problem: player projectiles are not moving in sync with the player rig.

Out of sync lasers

As you can see, the lasers kind of slow down as the camera speeds up and if the lasers are actually have low speed, they would appear as if they are not moving if the camera is moving a little too fast. At first I thought by updating the laser speed based on the camera’s speed, but that still left some bullets out of sync, the fix was simply parenting the lasers to the Rig that held both the camera and the player. Now all the lasers no matter if they are slow or fast, will always be in sync with the camera.

--

--

Mohamed Hijazi
Nerd For Tech

A knowledge seeking biologist who is following his passion into a full time career in Unity / Game Development. https://www.linkedin.com/in/mohamed-hijazi/