mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 12:18:00 +00:00
try to fix Mobile gui for tickets
This commit is contained in:
@@ -193,6 +193,7 @@ public enum FSkinImage implements FImage {
|
||||
COUNTERS3 (FSkinProp.IMG_COUNTERS3, SourceFile.ICONS),
|
||||
COUNTERS_MULTI (FSkinProp.IMG_COUNTERS_MULTI, SourceFile.ICONS),
|
||||
ENERGY (FSkinProp.IMG_ENERGY, SourceFile.ICONS),
|
||||
TICKET (FSkinProp.IMG_TICKET, SourceFile.ICONS),
|
||||
|
||||
//Dock Icons
|
||||
SHORTCUTS (FSkinProp.ICO_SHORTCUTS, SourceFile.ICONS),
|
||||
|
||||
@@ -467,6 +467,7 @@ public class VPlayerPanel extends FContainer {
|
||||
private int poisonCounters = player.getCounters(CounterEnumType.POISON);
|
||||
private int energyCounters = player.getCounters(CounterEnumType.ENERGY);
|
||||
private int experienceCounters = player.getCounters(CounterEnumType.EXPERIENCE);
|
||||
private int ticketCounters = player.getCounters(CounterEnumType.TICKET);
|
||||
private String lifeStr = String.valueOf(life);
|
||||
|
||||
private LifeLabel() {
|
||||
@@ -515,7 +516,7 @@ public class VPlayerPanel extends FContainer {
|
||||
adjustHeight = 1;
|
||||
float divider = Gdx.app.getGraphics().getHeight() > 900 ? 1.2f : 2f;
|
||||
if(Forge.altPlayerLayout && !Forge.altZoneTabs && Forge.isLandscapeMode()) {
|
||||
if (poisonCounters == 0 && energyCounters == 0 && experienceCounters == 0) {
|
||||
if (poisonCounters == 0 && energyCounters == 0 && experienceCounters == 0 && ticketCounters ==0) {
|
||||
g.fillRect(Color.DARK_GRAY, 0, 0, INFO2_FONT.getBounds(lifeStr).width+1, INFO2_FONT.getBounds(lifeStr).height+1);
|
||||
g.drawText(lifeStr, INFO2_FONT, getInfoForeColor().getColor(), 0, 0, getWidth(), getHeight(), false, Align.left, false);
|
||||
} else {
|
||||
@@ -544,6 +545,12 @@ public class VPlayerPanel extends FContainer {
|
||||
g.drawText(String.valueOf(experienceCounters), INFO_FONT, getInfoForeColor().getColor(), textStart, (halfHeight*mod)+2, textWidth, halfHeight, false, Align.left, false);
|
||||
mod+=1;
|
||||
}
|
||||
if (ticketCounters > 0) {
|
||||
g.fillRect(Color.DARK_GRAY, 0, (halfHeight*mod)+2, INFO_FONT.getBounds(String.valueOf(ticketCounters)).width+halfHeight+1, INFO_FONT.getBounds(String.valueOf(ticketCounters)).height+1);
|
||||
g.drawImage(FSkinImage.TICKET, 0, (halfHeight*mod)+2, halfHeight, halfHeight);
|
||||
g.drawText(String.valueOf(ticketCounters), INFO_FONT, INFO_FORE_COLOR.getColor(), textStart, (halfHeight*mod)+2, textWidth, halfHeight, false, Align.left, false);
|
||||
mod+=1;
|
||||
}
|
||||
adjustHeight = (mod > 2) && (avatar.getHeight() < halfHeight*mod)? mod : 1;
|
||||
}
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user