back to the original page

11. Making the enemy boss

Create a boss character to come out at the end of the stage
Make a combination of parts using the parent-child hierarchy


Boss body - 4 boss legs - 3 boss turrets


Keep the project file created in the previous tutorial open

Create a sprite for a boss



Load 'resource/img_boss.bmp' into the image file and set the color key


Build the pattern list and set the hit decision
Note that the center position of the leg parts is not in the middle


Adjust the size of the leg parts to your liking, because if the defense judgment of the leg parts is larger than the turret parts, the shot's attack will not be able to pass


If you will need to rotate the sprite when directing or moving it, please prepare the image with respect to the downward direction

Create three types of characters: boss body, legs, and turret

Setting up the boss body, the key is to stop time while the boss is appearing
Show stamina is checked, but at this time it is not ready to be displayed
Later on in the layout settings will be discussed
The configuration of the boss leg parts
The setting of the boss turret
Switching between the three types is done in a script

Scripting for the boss body

Generate four leg parts as children
Appears while rotating from the top of the screen


Rotation is done in task 1

Edit the contents of the panel

Launch Task 1 for rotating the body
Place the leg parts as children
Note that the priority, angle, distance and offset angle are different
Move it off the screen above the screen
Move it into the screen
Finish the scene
Task 1 is only one rotating panel

Scripts for when the boss is destroyed

If you do not describe anything in the destruction task, it will be a small fry destruction effect


For flashy explosion effects

Edit the contents of the panel

Explosion effects
Explosion effects
Finally, do not forget to place the annihilation

Scripting for boss legs

Generate three types of turrets, as children

Edit the contents of the panel

Place the turret parts as a child
PARAM_A can be taken on the child side and can be branched in appearance and behavior
Note that the coordinates, drawing priority and PARAM_A are different

Scripting for the boss turret

Switching the pattern number of the turret in PARAM_A
Attacks at regular intervals (Task 1)
Rotate to face the direction of your plane (Task 2)

Edit the contents of the panel

Launch task 1 for rotation
Launch task 2 for the attack
Assign it to variable 00 since we have received PARAM_A from the parent (leg parts)
Reflect the contents of the variable 00 to the pattern number
Task 0 is now finished

Scripting for the boss turret 2

Edit task 1 for the attack

Edit the contents of the panel

100 frame weight to attack
Firing bullets in the direction the turret is facing After firing, 120 frame weight

Scripting for the boss turret 3

Set the rotating panel to face the direction of your machine

Test Play

If you can verify the behavior of the boss in character unit tests
Place 'BOSS' a little before the whole time in the stage edit


Test play a stage unit test to make sure it is working fine
Defeat the boss and advance to the next stage automatically after the entire time has elapsed

Back to top of page