Boss Arriving Part-3: Health & Final Wave- Game Dev Series 54

Objective: Create health bar of the boss and add boss to final wave.

It looks more crazy with some damage animation!

With special movement and attacking methods, now should be a wonderful chance to defeat our boss.

In this article, we will create the health bar of the boss and send it into our spawning routing.

Health bar

Create a new slider under Canvas and adjust anything you need like what we did in the previous articles.

Cyborg Orb got a long health bar!

In the UIManager script, create a public method to update the slider value.

And in our Boss script, set the health limit to 100 with an integer. Then create a LaserHit() method as in Enemy script, we can create a damage calculation in it.

And don’t forget to set the maximum value of slider in UIManager.

With this LaserHit() method, boss will lost 2 health per damage, which means you need 50 shot to defeat the boss!

Put it in routine

Now we can create the last wave to reveal the boss.

In our SpawnManager script, under the waves end, add some lines to it to start the boss wave.

In our spawning rules, when the wave counts is equal to the number we set for the maximum wave, it will stop spawning. We just need to enable the boss right before the spawning loop is about to finish.

And that is pretty much everything we need to do in SpawnManager. When the waves is over, it will release the boss to finish the job.

Bonus animation

You can also create some animation to it to make it more like alive.

This is the damage animation.

And use the trigger in LaserHit() method to make a transition.

Demonstration of animation transition.

Boss is finally ready. Prepare for a fully challenge till the end to fight the boss!




A passionate gamer whose goal is to work in video game development.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Similar but Not the Same: You Still Need Developers, but Do You Need Coders?

Using AudioManager to Manage the Audio Effect- Game Dev Series 118

Paralympian @madison.____

The Ultimate Guide to GCP’s Logging Query Language

SES is not supported in your AWS region? Here’s what you can do

Concurrency in Go — #23

Go Lean or Go Agile: A Brief Analysis

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
S.J. Jason Liu

S.J. Jason Liu

A passionate gamer whose goal is to work in video game development.

More from Medium

Adding a thruster speed boost on keypress

What is a Control Track in Timeline

Upgrading A Unity Project To The Universal Render Pipeline (URP)

Setting up a Unity Project for the High Definition Render Pipeline (HDRP)