In this section, we will learn about enemies that follow a predefined path. We will also learn how to shoot bullets and kill enemies in the game.
Let's try to make enemies who follow a path made by us. We will create a new enemy type called star:
This type of an enemy will follow the path that we create in the Tiled map editor. I have created the map, which looks like the following screenshot:
The Objects layer looks like this:
As you can see, we created a path in the Objects layer using a polygon. We named the path as star. The ...