mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 03:38:01 +00:00
- More changes related to supporting negative power and toughness, please test to see this doesn't break anything.
- Fixed some visualization issues in the deck editor related to supporting negative P/T (e.g. non-creatures showing up as P/T 2 billion+ / 2 billion+).
This commit is contained in:
@@ -428,15 +428,17 @@ public enum ColumnDef {
|
||||
int result = -1;
|
||||
if (i instanceof PaperCard) {
|
||||
result = ((IPaperCard) i).getRules().getIntPower();
|
||||
if (result == -1) {
|
||||
result = ((IPaperCard) i).getRules().getInitialLoyalty();
|
||||
if (result == Integer.MAX_VALUE) {
|
||||
if (((IPaperCard)i).getRules().getType().isPlaneswalker()) {
|
||||
result = ((IPaperCard) i).getRules().getInitialLoyalty();
|
||||
}
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
private static Integer toToughness(final InventoryItem i) {
|
||||
return i instanceof PaperCard ? ((IPaperCard) i).getRules().getIntToughness() : -1;
|
||||
return i instanceof PaperCard ? ((IPaperCard) i).getRules().getIntToughness() : Integer.MAX_VALUE;
|
||||
}
|
||||
|
||||
private static Integer toCMC(final InventoryItem i) {
|
||||
|
||||
Reference in New Issue
Block a user