When the player dies after being hit by a box, the game freezes and stop screen.
Exception in thread "main" java.lang.NullPointerException: Cannot read the array length because "image" is null at engine.DrawManager.drawEntity(DrawManager.java:253) at screen.GameScreen.draw(GameScreen.java:438) at screen.GameScreen.update(GameScreen.java:350) at screen.Screen.run(Screen.java:89) at screen.GameScreen.run(GameScreen.java:253) at engine.Frame.setScreen(Frame.java:59) at engine.Core.main(Core.java:172)
It is confirmed that the screen freezes when the player dies after being hit by a box, regardless of whether it happens at the first or second attempt.
Todo List
Start the game and proceed with the gameplay.
When the player dies, make sure they die by being hit by a box.
Problem Description
When the player dies after being hit by a box, the game freezes and stop screen.
Exception in thread "main" java.lang.NullPointerException: Cannot read the array length because "image" is null at engine.DrawManager.drawEntity(DrawManager.java:253) at screen.GameScreen.draw(GameScreen.java:438) at screen.GameScreen.update(GameScreen.java:350) at screen.Screen.run(Screen.java:89) at screen.GameScreen.run(GameScreen.java:253) at engine.Frame.setScreen(Frame.java:59) at engine.Core.main(Core.java:172)
It is confirmed that the screen freezes when the player dies after being hit by a box, regardless of whether it happens at the first or second attempt.
Todo List