Retained some schemas

This commit is contained in:
Anthony Calosa
2019-09-03 11:20:10 +08:00
parent c38bae910a
commit a4d34bb858
119 changed files with 783 additions and 292 deletions

View File

@@ -133,7 +133,7 @@ public final class ImageKeys {
// if there's an art variant try without it
if (setlessFilename.matches(".*[0-9]*$")) {
file = findFile(dir, setlessFilename.replaceAll("[0-9]*$", ""));
return file;
if (file != null) { return file; }
}
}
} else if (filename.contains("/")) {
@@ -144,7 +144,7 @@ public final class ImageKeys {
// try lowering the art index to the minimum for regular cards
if (setlessFilename.contains(".full")) {
file = findFile(dir, setlessFilename.replaceAll("[0-9]*[.]full", "1.full"));
return file;
if (file != null) { return file; }
}
}

View File

@@ -47,8 +47,13 @@ public abstract class LobbyPlayer {
}
LobbyPlayer other = (LobbyPlayer) obj;
if (name == null) {
return other.name == null;
} else return name.equals(other.name);
if (other.name != null) {
return false;
}
} else if (!name.equals(other.name)) {
return false;
}
return true;
}
public int getAvatarIndex() {

View File

@@ -598,7 +598,10 @@ public final class CardType implements Comparable<CardType>, CardTypeView {
if (multiWordTypes[0].startsWith(type) && !multiWordTypes[0].equals(type)) {
return true;
}
return multiWordTypes[1].startsWith(type) && !multiWordTypes[1].equals(type);
if (multiWordTypes[1].startsWith(type) && !multiWordTypes[1].equals(type)) {
return true;
}
return false;
}
public static class Constant {

View File

@@ -216,7 +216,10 @@ public class DeckRecognizer {
if (line.toLowerCase().contains("schemes")) {
return true;
}
return line.toLowerCase().contains("vanguard");
if (line.toLowerCase().contains("vanguard")) {
return true;
}
return false;
}
public void setDateConstraint(int month, Integer year) {

View File

@@ -159,7 +159,11 @@ public final class PaperCard implements Comparable<IPaperCard>, InventoryItemFro
if (!edition.equals(other.edition)) {
return false;
}
return (other.foil == foil) && (other.artIndex == artIndex);
if ((other.foil != foil) || (other.artIndex != artIndex)) {
return false;
}
return true;
}
/*