Beat your boss

ChallengeThe boss and the ending

This is the last challenge. Play your boss level, beat your boss, and win your game.

It is in your own game, and your game checks it with a test.

What should happen

  1. The hero walks into the boss room. The room goes dark.
  2. The boss sees the hero and attacks.
  3. The hero hits the boss again and again. After a few hits, the boss gets angry.
  4. The boss is beaten. The room lights up.
  5. The banner shows, and the game is won.

How to change the tests

Your old tests were for level 1 and level 2. They can not run in the boss room, so they have to go. The sections they belonged to keep their ticks.

  1. Press Open your game here, in the builder below.
  2. Press the Game button Game settings, under the map. In Game Settings, find Scripts and press Tests Tests.
  3. Press Code Code. Take out all the old tests, so the script is empty.
  4. Type these two lines.
when the {Big Slime} is beaten
  test "The hero beat the boss" if the {Hero} health is over 0
  1. Press Save Save.

If your boss has another ID, use that name in the test.

This makes a new game in your Lab and opens the builder right here. It is free.

Test it

  1. In the builder, go to level 3 and press Play Play game, under the map.
  2. Fight your boss. Swing with X, and keep out of its way.
  3. When the boss is beaten, look at the Test results drawer. Your test should have a tick.
  4. Look under the builder. It should say that your test passed.
If this happensWhat to do
The boss is too hardIt is your boss. Give it fewer hits, or make it angry later.
The boss is too easyGive it more hits, or make it angry sooner.
The test has no tickCheck that the name in the test is the same as your boss's ID.
The room does not light upCheck the name in the level script too.

Make every goal and every test pass to finish this section.