I went back to the GDD this morning and tweaked little bits of information that have “evolved” during the development of Hanami. I took a look at the list of events that I wrote right at the beginning of this project, to try to work out how to conclude the game. So far, motivations for playing the game have been about progression, so I finally needed to realise a result of the player’s hard efforts!
The best way I could think to conclude the game was to have a Boss Battle, which was something I wasn’t originally planning but feel that the player would be let down if the game ended without one final challenge. So, the final door that is opened will lead to a “battle” with the Zashiki Warashi spirit, resulting in the spirit transforming back into her Kokeshi doll form. This essentially solves the “Hanami crisis”, and the player will be able to roam the world obstacle free in order to collect the remaining blossoms. There shouldn’t be many left (about 10 or so?), but only be collecting EVERY SINGLE LAST BLOSSOM will the game truly end.
The terms “Boss” and “Battle” are strong words, but it’s the best way to describe this glorified final obstacle! I haven’t introduced any new techniques to the battle, the Zashiki Warashi spirit can be de defeated in the same way as the Deceitful Blossom, by jumping on the enemy’s head. The main difference is that this enemy has a 5 health points and a projectile attack! The battle is really based on the sort of sub-boss battles you’d fight in old Super Mario games, where jumping three times on a Koopa’s head will let you pass to the next stage. I’ll record a video to show what I mean if I get the time!
EDIT: Here you are, Boss fight footage recorded exclusively recorded for this Blog:
For this stage, I’ve created three new game assets. The first is the Za-chan object, which controls everything that the enemy does. She works with three alarms, one which instigates “attack 1”, another which instigates “attack 2” and a final alarm which determines how long she is static for when hit. She has her own health counter, which is shown by my second new asset which aligns with original HUD:
The third new asset I have (half) created is an object called obj_attack. At the moment, this object is represented by my Gunkan Sushi sprite, as I haven’t actually drawn anything to go here yet… So, when the enemy shoots her attack towards at player, she is currently shooting sushi. This has been fun to test, and I will almost be sad to see it changed! This has been the easiest to program, as it’s only job is to move steadily towards the player. If the player is hit, then the projectile is destroyed, to avoid being hit twice by the same attack.
This is by far the most complex AI controlled NPC character I’ve created so far. The character moves in relation to two objects, the player and a “block” object, which keeps the enemy within a certain space. Za-chan moves slightly slower than the player, so it is possible to catch up and jump on her head! If the player is quite far from the enemy, the enemy will move towards the player. If the player is very close to the enemy, the enemy will move away in evasion. As well as this, there is a certain distance from the player that Za-chan will simply stand still and spam the player with attacks, however this will only happen if the player is also standing completely still. This system works well enough to keep the enemy moving about, but I noticed that it was possible to defeat her too easily by trapping her in a corner. So, I’ve added a final line of code that states that the enemy must move towards the player if she gets too close to the “block” object, even if this means a collision with the player. Colliding with the enemy actually causes player damage, so this in itself acts as a sort of attack mechanism.
Za-chan’s two “attacks” are thrown when each of the first two alarms go off, and this code simply resets each one so the enemy constantly attacks at an even rate. Attack 1 throws one sushi, and attack two which is less regular throws 2 sushi!
I’ve used almost exactly the same code as the Deceitful Blossom to program what happens when Za-chan is jumped on. I’ve simply changed the squashed flower sprite to a new sprite, and ensured that during this time she can neither deal or receive damage, and she cannot move! I thought it would be appropriate to make a new sprite animation where she sits down and rubs her poorly head after having an full grown woman jump on top of it…
Once she has been defeated, I’ve also created a new “transformation” animation which turns her from spirit form to Kokeshi form. To do this, I created a cloud which passes over her to reveal the doll underneath. I’ve made this in the same style as my previous “auspicious clouds”, and drew out the animation first to make sure the swirls moved bout fluidly:
At the moment, I’ve set the battle out in the most final stage I have made, even though this is currently far from finished. The aim for the rest of this week is to finish the inside of the building and build a proper “Boss Stage” level for the battle to be held in. I’ve recorded a video of the battle so far, although I think I still need to make some tweaks to the rapidity and speed of attacks. I’ll probably have to get back onto SunVox too to create some epic Boss Battle music!