mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 10:48:00 +00:00
[Mobile] Add AI Status to Deck ListView
This commit is contained in:
@@ -2,6 +2,7 @@ package forge.itemmanager;
|
|||||||
|
|
||||||
import java.util.Map.Entry;
|
import java.util.Map.Entry;
|
||||||
|
|
||||||
|
import com.badlogic.gdx.graphics.Color;
|
||||||
import com.badlogic.gdx.utils.Align;
|
import com.badlogic.gdx.utils.Align;
|
||||||
|
|
||||||
import forge.Forge;
|
import forge.Forge;
|
||||||
@@ -133,6 +134,10 @@ public final class DeckManager extends ItemManager<DeckProxy> implements IHasGam
|
|||||||
x += IMAGE_SIZE + FList.PADDING;
|
x += IMAGE_SIZE + FList.PADDING;
|
||||||
ColorSet deckColor = deck.getColor();
|
ColorSet deckColor = deck.getColor();
|
||||||
float availableNameWidth = w - CardFaceSymbols.getWidth(deckColor, IMAGE_SIZE) - IMAGE_SIZE - 2 * FList.PADDING;
|
float availableNameWidth = w - CardFaceSymbols.getWidth(deckColor, IMAGE_SIZE) - IMAGE_SIZE - 2 * FList.PADDING;
|
||||||
|
if (deck.getAI()) {
|
||||||
|
g.drawOutlinedText("AI", font, Color.GREEN, Color.BLACK, x, y, w, IMAGE_SIZE, true, Align.left, true, false);
|
||||||
|
x += IMAGE_SIZE + FList.PADDING;
|
||||||
|
}
|
||||||
String name = deck.getName();
|
String name = deck.getName();
|
||||||
if (!deck.getPath().isEmpty()) { //render path after name if needed
|
if (!deck.getPath().isEmpty()) { //render path after name if needed
|
||||||
name += " (" + deck.getPath().substring(1) + ")";
|
name += " (" + deck.getPath().substring(1) + ")";
|
||||||
|
|||||||
Reference in New Issue
Block a user