One thing you may have noticed while moving our hero around the map is that no matter where our hero goes, he always faces the same direction (downwards). While this behavior was widely accepted in the 1980s, the same cannot be said for today's games, even for mobile games. We will now address this in the following section.
As the title says, there are two new things our hero must be able to do. The first one is walking, which will involve animation. The second one is facing the right direction, which will involve using more features of our sprite sheet.
Character class contains everything related to our hero, we will open the
character.js file and add ...