The two power-ups in Super Mario Run (mushroom and star) are currently strictly visual and do not perform the functions that they are intend to perform which are namely, getting another life if the player hits a Goomba (enemy) and becoming invincible for a short period of time respectively. Another issue that occurs is that the limited time star power-up is never unequipped in a future level after players have already used it up. As a result, players are able to keep the star power-up forever which is not very intuitive. Lastly, the star music does not stop if the player pauses, quits, or loses the game and sometimes plays over the existing game music.
How These Changes/Fixes Can Be Implemented:
1) Mushroom Power-Up: In order to get this power-up working, the Run() method in the Goomba class needs to be modified such that if the player is equipped with the mushroom power-up, the player does not die and shrinks back to normal size (resetMushroomPurchased() method in playerProgressneeds to be called here). This indicates that if they player gets defeated by an enemy a second time, the player dies.
2) Star Power-Up: Similiar to the changes that need to be implemented for Mushroom Power-Up, the Run() method in the Goomba class needs to be modified such that if the player is equipped with the star power-up, the Goomba disappears upon any sort of contact from the side. The isGameOver method also needs to be modified accordingly so that it "unequips" the star power-up by calling the resetStarPurchased() method in the playerProgress class.
3) Music: The overlapping star music can be fixed by adding conditional statements in actionPerformed(), isGameOver(), and Pause() methods that check for the player's current power-up state and adjust the music coherently
The two power-ups in Super Mario Run (mushroom and star) are currently strictly visual and do not perform the functions that they are intend to perform which are namely, getting another life if the player hits a Goomba (enemy) and becoming invincible for a short period of time respectively. Another issue that occurs is that the limited time star power-up is never unequipped in a future level after players have already used it up. As a result, players are able to keep the star power-up forever which is not very intuitive. Lastly, the star music does not stop if the player pauses, quits, or loses the game and sometimes plays over the existing game music.
How These Changes/Fixes Can Be Implemented:
1) Mushroom Power-Up: In order to get this power-up working, the Run() method in the Goomba class needs to be modified such that if the player is equipped with the mushroom power-up, the player does not die and shrinks back to normal size (resetMushroomPurchased() method in playerProgressneeds to be called here). This indicates that if they player gets defeated by an enemy a second time, the player dies.
2) Star Power-Up: Similiar to the changes that need to be implemented for Mushroom Power-Up, the Run() method in the Goomba class needs to be modified such that if the player is equipped with the star power-up, the Goomba disappears upon any sort of contact from the side. The isGameOver method also needs to be modified accordingly so that it "unequips" the star power-up by calling the resetStarPurchased() method in the playerProgress class.
3) Music: The overlapping star music can be fixed by adding conditional statements in actionPerformed(), isGameOver(), and Pause() methods that check for the player's current power-up state and adjust the music coherently