Week 10 - Presentation / Graphics


Its the little things

Hey all, welcome back to another round of "What I did this  week!"
This week focus was on getting your graphics and presentation sorted. As I had already done most of this in the previous weeks (especially with the level generator, I needed the tiles to be what they are so I could see what problems I was having) I spent my time working on getting a health and mana potion sprite working in the bottom corners of my game, amongst other things.


Health bar/potion

The health potion I made from scratch (I know right?! Me and art don't go well together) and positioned down in the bottom left corner of the screen. Its linked to a tracker script that controls and stores things like your current health, current mana, score and difficulty.
If you touch and enemy or vice versa you take some damage (using the hurtOnCollision script), this in turn reduces your health bar/potion by an equal amount. Eventually if you reach 0, you die.


Mana bar/potion

I added the mana potion straight after the I added the health potion, and this made things really simple. Just copy over what I did for the health potion, change the position, colours and names and most of it was sorted. The only tricky part was I didn't want it to reduce when the player took damage, so I changed that part and moved the trigger over to my shoot script, so when the player fires the LAZOR it reduces the mana potion by 40 (out of 100). 
Now I ran into a few problems, 1. The player could keep zapping even if he had run out of mana, and 2. The mana doesn't refill it self.
I fixed these issues by added an if statement that said, if the players current mana is less than 40, no zappy zappy. Cool, that's sorted.
Then I added a coroutine that did minus damage to the mana potion (as in, added to it) every few seconds, but I had to add a boolean statement to its initiation so that it couldn't be called multiple times (and refill it almost instantly).
All of this though, led to another issue, the mana wouldn't stop refilling and would go over the max mana of 100. Well you guessed it, another if statement to sort that one out.


Aiming guide

One of the requests by the testers was an aiming guide to see where the LAZOR was going to hit. Now if I added a full aiming guide that showed all the ricochets, that would be broken and make the game too easy. So I added an aiming guide that shows where the first hit would land. Touched it up with a fade effect and it works!


Particle effect on death

A small thing, but I like it. I added a small particle effect to the death of an enemy so that they don't just disappear when hit by the LAZOR. They POOF! into dust.


Extra bits

I added towards to the end, a GameOver_Overlay when the player dies with a button to return to title. Kind of a last minute addition. It works, kind of. 
I added mass to the enemies so you can't just push all of them around. This adds a challenge to the game because you can now be trapped in corners etc. I.e. You cannot push golems around, but you can push a goblin back.


Known Issues/Bugs

There are a few still floating about, but the ones I know of atm are:
 - When the player dies, the UI (Score, Health and Mana potions) stay on the screen after it returns to title. I had only just implemented that before upload and didn't realise it would stick around. Hoping to fix this problem this week.
 - Mana potion stops refilling. This is a big one. I'm still investigation as to why this happens.

Upcoming additions (hopefully)

I'm hoping to add a few more little bits to the game. 
1. Health potions to refill your health.
2. Powerups to temporary increase stats (increase ricochets number, speed up mana refill etc etc)
3. Adding hitpoints or something to the enemies. So for example Golems aren't one shot.

Files

24 Sept.zip 8 MB
Sep 24, 2020

Leave a comment

Log in with itch.io to leave a comment.