Vanquish Wolfgang the Ghast

Vanquish Wolfgang the Ghast

Summary

Vanquish Wolfgang the Ghast is a small shoot-em-up boss battle in an adventure setting, made in Unity. The goal was to get better at C# by making a boss with different stages and types of projectiles that gets more difficult over time. It was made as an assignment as part of my Level Design education at The Game Assembly. 

Specifications

  • Created in 3 weeks half-time
  • Using Unity 5
  • Scripting and particles by me
  • Graphical assets from the Unity Asset Store and open source
  • Main Arena platform sprite made by Robin Tran
  • Music by Anton Pilmark

Introduction

For this assignment we had to make a boss with three stages and two different types of projectiles in order to learn more about scripting. I knew that I really enjoyed scripting which is why I wanted to take this project further. My approach was to make all the systems as general and modular as possible so that they could be expandable. That way, I could start with a simple, working base and then build upon it. Looking back as a more experienced scripter, I see that I could have made the systems a lot easier to use, but for my first try, it went well! 🙂

The Player

The goal for this assignment was to push my knowledge in C# scripting and using Unity. This is why I chose to animate the player character using mechanim, a system I'd never used before. I also thought that it would be really cool to make an inventory system for the player. This was also done to make the boss battle have some different tactics to the gameplay and give the game a different feeling - rather than a regular shoot-em-up boss, this feels more like an action adventure game.

The Player Weapons

  • The sword
    • Works with the help of a raycast checking if the player hit an enemy
    • Is very strong but has very short range
  • The bow
    • Fires a projectile that deals damage based on collision
    • Has long range but is weaker than the sword
  • The shield
    • Blocks all incoming projectiles using collision. Does not block the bats.
    • Is attached to the player with an arm constraint and rotated around the player based on mouse position.

The player tests out their inventory of magical bow, sword and shield

Boss Behaviour

As I worked, I found a way to make a lot more varied boss stages more easily. This was done by making the projectile behaviour easy to change, combined with making the boss attack patterns more diverse. I found that the more small functions of events I made, the more I could combine them into new, bigger things.

The main components determining the enemy behaviour. Looking back on it, it's a bit of a mess 🙂
The next step would be to give the variables headlines and sort them in the inspector to increase usability.

 

Projectile Behaviour

Instead of making two different types of projectiles, I made many components with different behaviours that could be combined into various results. Then, I used the Boss Manager script in order to shut on and off certain components at different times, to create projectiles whose behaviours changed over time.

The boss and turrets can also fire any number of projectiles in different formations such at cones and circles, and can fire each projectile at the same time or with a delay. This can create many kinds of weapons and patterns of projectiles across the map.

Projectile Movements

  • Straight ahead
  • Towards the player
  • In a circle around the player

Combinations

  • Bat: Moving towards the player, but with a delay on stopping so that the bat moves through the player when it deals damage. 
  • Circling projectiles: Following the player, then forming a circle around the player. When the circle is complete, the projectiles in the circle fire toward the player in a random order.
  • Surprise homing shotgun: Firing in a shotgun formation until a distance away from the player, then switching to homing projectiles.

 

The circling projectile behaviour

The line-up shotgun behaviour

 

Boss Phase 1: Bubble Burst

The combat is started off with the boss speaking some intro dialogue while being immune. This is to give the player an opportunity to try their hand at switching weapons and also to establish a bit of story.

After this, the bossfight starts off with the boss moving up and down, firing projectiles straight ahead. The boss has a protective bubble at this stage. 
Once the bubble has been depleted to half health, the second part of phase 1 begins. 

The boss now spawns 3 bats and every third shot the boss fires is a shotgun, spreading projectiles evenly across the map. The shotgun serves as a clear signal that the boss is getting more difficult, while the bats are there to introduce the player to other types of enemies. 

Once the player has burst the bubble, the boss enters its first weak phase.

 

The dialogue sequence at the start of the game. The boss is covered in his Bubble.

 

The player can tell Wolfgang is in the weak phase by his expression, the red particles, and the way he yells "Aaah!".

Boss Phase 2: Weak Phase

 

In the weak phase, the boss is in a "hurt" animation and red particles spawn all around it, making it clear that it is damaged. However, the boss is in this stage immune to arrows. This is to incentivise the player to go up and try to smack it with the sword. In this process the players will discover that the sword deals a massive amount of damage, something that could go unnoticed through the previous phase if the player chose to stick to arrows.

I added a weak phase to let he player know they're doing something right and have the upper hand in the fight for a while, bringing more variety to the emotions you feel throughout the game.

Boss Phase 3-6: Variations of difficulty

Now we enter the difficult phase, which consists of the same phase with many variations. In the start of this phase, two turrets spawn and it is their attack pattern that will vary throughout the repetitions of this phase.

The boss will first spawn new bats, then fire the circling projectiles displayed above. When the circling projectiles are dead, the boss will fire the homing shotgun also displayed above. This cycle repeats until the boss gets to certain health thresholds, when the boss enters the weak phase. 

Each time the boss emerges from the weak phase, the turrets respawn (if they were killed) and their behaviour is updated to get more difficult. In the beginning, the turrets aim for the player but shoot straight ahead. Next time they respawn, they will fire homing projectiles. The final time they respawn, they will fire in a circle around them one shot at a time, filling the battlefield with projectiles. This is repeated until the boss is dead!

I chose to tie the turrets respawning to the end of the boss weak phase. Putting it right after a moment where the player has the upper hand ups the tension even more when they respawn and force the player to get back on their toes. This brings even more variety to the gameplay and leaves the player in anticipation of the boss' next move.

 

 

The boss is in a final stage, with turrets, bats and homing projectiles keeping the player on their toes.

 

Conclusion

 

This project was amazing to work on, and it was the assignment where I truly discovered my passion for scripting. Looking back, I think I did a decent job for a non-experienced scripter and Unity user. I definitely learned a ton from this project and the lessons have all gone into making Secret of the Forest Temple. It was also a great experience to work fully in 2D and using 2D systems.

A closeup of the player, boss and a player projectile