Hello everybody, I have been working on a game for college and I'm currently putting the final touches to it. Currently my timer is shown using the showText method, however I want to use a custom font instead. My code for the timer is in the MyWorld subclass, and I'm trying to make the following code work:
I note that "setImage()" doesn't work in the MyWorld subclass, so how do I make it work? Thank you.
GreenfootImage img = new GreenfootImage(500, 100); img.setColor(Color.BLACK); img.fill(); img.setColor(Color.RED); img.setFont(new Font("Calibri", false, false , 100)); img.drawString("Time Left: "+ timer/60 + " sec", 700, 15); setImage(img);