SVar:Rarity should be deprecated!

Came across such code in GUI_Quest_DeckEditor:: public void updateDisplay()
I decided to check that in card descriptions
So I suggest the card rarity should be considering only being tied with a set the card belongs to
and Card.set/getRarity be replaced by more flexible solutions.
- Code: Select all
// CardList top = readCardpoolAndConvertItToCardList();
ReadBoosterPack pack = new ReadBoosterPack();
// update top
for (int i = 0; i < top.size(); i++) {
Card c = top.get(i);
// add rarity to card if this is a sealed card pool
String cardName = c.getName();
if (!pack.getRarity(cardName).equals("error")) {
c.setRarity(pack.getRarity(cardName));
}
boolean filteredOut = filterByColor(c);
if (!filteredOut) {
filteredOut = filterByType(c);
}
if (!filteredOut) {
topModel.addCard(c);
}
}// for
I decided to check that in card descriptions
- Code: Select all
Name:Act of Treason
ManaCost:2 R
Types:Sorcery
Text:no text
A:SP$ GainControl | Cost$ 2 R | ValidTgts$ Creature | TgtPrompt$ Select target creature | LoseControl$ EOT | Untap$ True | AddKWs$ Haste | SpellDescription$ Gain control of target creature until end of turn. Untap that creature. It gains haste until end of turn.
SVar:Rarity:Uncommon
SVar:Picture:http://www.wizards.com/global/images/magic/general/act_of_treason.jpg
SetInfo:M11|[b]Common[/b]|http://magiccards.info/scans/en/m11/121.jpg
SetInfo:M10|[b]Uncommon[/b]|http://magiccards.info/scans/en/m10/124.jpg
SetInfo:M12|[b]Common[/b]|http://magiccards.info/scans/en/m12/121.jpg
End
So I suggest the card rarity should be considering only being tied with a set the card belongs to
and Card.set/getRarity be replaced by more flexible solutions.