How I Made The Game

I have now designed a fully functioning retro game. It's based on Super Mario Bros but with ordinary citizens - your girlfriend has been kidnapped by someone and you have to fight them to rescue them. When you play it, it looks like it was a piece of cake to make, but it wasn't. Here are some of the challenges I faced when making the game.

The first challenge I faced was the health bar. Rather than just displaying it as simple text, I wanted to use the circle design with the 4 colours to represent whereabouts your health is that was used in Super Mario 64. Firstly, I had trouble trying to get it to follow the player on the screen and not appear as part of the level. Eventually, I realised that to do this, I had to go to the HUD layer and set the parallax to 0,0, and move the health bar to the margin. This means that regardless of how high or low the main character is on the screen (I thought I had to place it above him for it to work), it will always appear in the top left corner. Also, when I was making it on Piskel, I originally did all the different states for different health amounts together as one animation but I had to make each frame its own animation on Piskel so it correlates to the health number, which worked fine. At first, I noticed it wasn't refilling itself when I ate the apple yet when I hit another enemy, it still went to 7 (full health is 8) but that was down to a typing error on the event sheet. I fixed it and it worked fine. I struggled to find a way to get it to not reset itself at the start of every level but after I realised I had to make it a global variable (I'd already assigned it to the player meaning I'd have to undo a lot of the code), I decided to leave it and make the platforms a bit harder so it's more of a relief that it resets itself.

Another challenge I faced was the setting for the boss level. I arranged it to have skateboarding thugs spawning in at the end of every platform so some were to the left of the player and some to the right. The problem was that they were all facing the same direction so the ones on the left were skateboarding away from the player, which made it too easy. Then if I tried mirroring them, it just mirrored all of them. It took a while before I learnt that is no way other than to re-import them as separate sprites. Then it started working. Additionally for this level, I had to find a way to make it so that touching normally hurts you but if you jump on his head, he'll take damage instead. The only solution that I could think of was to create an invisible box so that when the player collides with it, it deducts health from the boss instead of them. It caused a few glitches. The player still flashes as they then touch the boss anyway and I found out that you can just stand on his head and the box will automatically deduct the health straight away as soon as it re-spawns every 20 seconds, which will eventually just kill him (the win by doing nothing glitch).

Another problem I faced with all enemies was just trying to get them to work properly. The issue was that first, they were never there when I got to where they should be (caused by me not turning the default controls off meaning I was controlling them when I was controlling the player). Then the simulation wasn't working properly. The animations were working fine but the enemy just wouldn't move. I later found out there was a line of sight option meaning that when you're within a certain number of pixels from the enemy, it then starts charging towards you. You can then also set the acceleration, max speed and deceleration like you would with the player.

Other challenges I faced included the exit button. I had no idea how I was meant to get it to do that until I realised that in order to do that, I needed to assign that task to the browser. Once I did that, it worked fine. Another issue with the menu was that for some reason, despite me giving it clear instructions in the event sheet to do so, after the death or victory screen, it wouldn't go back to the main menu. I was just telling it that after death or victory, wait 5 seconds before going to the death or victory screen, then wait another 5 seconds before going to the main menu, and it wouldn't do that last instruction for some reason. I decided to give the two screens a separate event sheet and re-structured the code so that instead, on the start of the layout, whichever one it is, the system will be triggered to wait for 5 seconds before going to the main menu. After that, it worked fine.

Comments

Popular posts from this blog

Game Review

Sound Problems

Psychology of Sound