Hi, I'm having a weird issue that doesn't make sense to me. I have a Player class which has a draw method which draws a quad. I also have a healthBar object which also has a draw method that will draw another quad. Here's the structure this works under. Main() > Player.draw() > healthBar.draw().
Here's the Player classhttp://pastebin.java-gaming.org/f4cf61c4d63
Here's the healthbar class (the healthbar does create another square instead of a rectangle for testing)http://pastebin.java-gaming.org/4cf6c2d4361
When I create an instance of the healthbar and player in the main class, I can use Player.draw() and healthbar.draw(), it works fine. I'm just curious why I can't create this from within the Player class and call Player.draw() inside the main class to handle drawing both the player quad and healthbar quad. Is there something that prevents me from doing this? Thank you for your assistance.