@@ -0,0 +1,1102 @@
+package revert.MainScene;%0A%0Aimport java.awt.Dimension;%0Aimport java.awt.Graphics2D;%0Aimport java.awt.Panel;%0Aimport java.util.Observable;%0Aimport java.util.Observer;%0A%0Aimport revert.Entities.Player;%0Aimport revert.MainScene.notifications.WorldNotification;%0A%0Aimport com.kgp.core.AssetsManager;%0Aimport com.kgp.imaging.BitmapFont;%0Aimport com.kgp.imaging.BitmapFont.Alignment;%0A%0Apublic class HUD implements Observer %7B%0A%0A%09BitmapFont font;%0A%09%0A%09Player player;%0A%09Dimension view;%0A%09%0A%09String score = %22$ 0%22;%0A%09String hp = %22# 0 / 10%22;%0A%09String time = %220%22;%0A%09%0A%09World world;%0A%09%0A%09public HUD(Player p, World w, Dimension view)%0A%09%7B%0A%09%09this.player = p;%0A%09%09%0A%09%09font = new BitmapFont(%22bm%22, AssetsManager.Images);%0A%09%09world = w;%0A%09%09world.addObserver(this);%0A%09%09this.view = view;%0A%09%7D%0A%09%0A%09public void display(Graphics2D g)%0A%09%7B%0A%09%09font.drawString(g, score, view.width-10, view.height - 10, Alignment.Right);%0A%09%09font.drawString(g, hp, 10, 10 + font.getLineHeight());%0A%09%7D%0A%09%0A%09@Override%0A%09public void update(Observable o, Object args) %7B%0A%09%09if (o == world)%0A%09%09%7B%0A%09%09%09WorldNotification n = (WorldNotification) args;%0A%09%09%09score = n.score;%0A%09%09%09time = n.time;%0A%09%09%7D%0A%09%7D%0A%0A%09%0A%09%0A%7D%0A

Create HUD class