v0.2.4: moved loot and continue tags to bottom right, much more accessable
This commit is contained in:
@@ -57,8 +57,6 @@ public class StatusPane extends Component {
|
||||
private BitmapText keys;
|
||||
|
||||
private DangerIndicator danger;
|
||||
private ResumeIndicator resume;
|
||||
private LootIndicator loot;
|
||||
private BuffIndicator buffs;
|
||||
private Compass compass;
|
||||
|
||||
@@ -120,12 +118,6 @@ public class StatusPane extends Component {
|
||||
danger = new DangerIndicator();
|
||||
add( danger );
|
||||
|
||||
loot = new LootIndicator();
|
||||
add( loot );
|
||||
|
||||
resume = new ResumeIndicator();
|
||||
add ( resume );
|
||||
|
||||
buffs = new BuffIndicator( Dungeon.hero );
|
||||
add( buffs );
|
||||
}
|
||||
@@ -151,49 +143,17 @@ public class StatusPane extends Component {
|
||||
|
||||
keys.y = 6;
|
||||
|
||||
layoutTags();
|
||||
danger.setPos( width - danger.width(), 18 );
|
||||
|
||||
buffs.setPos( 32, 11 );
|
||||
|
||||
btnMenu.setPos( width - btnMenu.width(), 1 );
|
||||
}
|
||||
|
||||
private void layoutTags() {
|
||||
|
||||
float pos = 18;
|
||||
|
||||
if (tagDanger) {
|
||||
danger.setPos( width - danger.width(), pos );
|
||||
pos = danger.bottom() + 1;
|
||||
}
|
||||
|
||||
if (tagLoot) {
|
||||
loot.setPos( width - loot.width(), pos );
|
||||
pos = loot.bottom() + 1;
|
||||
}
|
||||
|
||||
if (tagResume) {
|
||||
resume.setPos( width - resume.width(), pos );
|
||||
}
|
||||
}
|
||||
|
||||
private boolean tagDanger = false;
|
||||
private boolean tagLoot = false;
|
||||
private boolean tagResume = false;
|
||||
|
||||
@Override
|
||||
public void update() {
|
||||
super.update();
|
||||
|
||||
if (tagDanger != danger.visible || tagLoot != loot.visible || tagResume != resume.visible) {
|
||||
|
||||
tagDanger = danger.visible;
|
||||
tagLoot = loot.visible;
|
||||
tagResume = resume.visible;
|
||||
|
||||
layoutTags();
|
||||
}
|
||||
|
||||
float health = (float)Dungeon.hero.HP / Dungeon.hero.HT;
|
||||
|
||||
if (health == 0) {
|
||||
|
||||
Reference in New Issue
Block a user