Fixing "Shoulder to Shoulder" bug and introducing "rules" card.

This commit is contained in:
marcins78@gmail.com
2011-09-03 12:44:38 +00:00
parent 6c1f5ee4ea
commit 1080a1fe92
2 changed files with 17 additions and 12 deletions

View File

@@ -48,10 +48,11 @@ public class Card1_059 extends AbstractLotroCardBlueprint {
if (PlayConditions.canUseFPCardDuringPhase(game.getGameState(), Phase.MANEUVER, self)
&& (
Filters.canSpot(game.getGameState(), game.getModifiersQuerying(), Filters.canExert(),
Filters.canSpot(game.getGameState(), game.getModifiersQuerying(),
Filters.or(
Filters.keyword(Keyword.ELF),
Filters.keyword(Keyword.DWARF))))) {
Filters.keyword(Keyword.DWARF)),
Filters.canExert()))) {
final CostToEffectAction action = new CostToEffectAction(self, Keyword.MANEUVER, "Use Shoulder to Shoulder");
List<Effect> possibleCosts = new LinkedList<Effect>();

View File

@@ -16,17 +16,21 @@ var Card = Class.extend({
this.cardId = cardId;
this.owner = owner;
this.attachedCards = new Array();
if (cardCache[blueprintId] != null) {
var cardFromCache = cardCache[blueprintId];
this.horizontal = cardFromCache.horizontal;
this.imageUrl = cardFromCache.imageUrl;
if (blueprintId == "rules") {
this.imageUrl = "/gemp-lotr/images/rules.png";
} else {
this.imageUrl = this.getUrlByBlueprintId(blueprintId);
this.horizontal = this.isHorizontal(blueprintId);
cardCache[blueprintId] = {
imageUrl: this.imageUrl,
horizontal: this.horizontal
};
if (cardCache[blueprintId] != null) {
var cardFromCache = cardCache[blueprintId];
this.horizontal = cardFromCache.horizontal;
this.imageUrl = cardFromCache.imageUrl;
} else {
this.imageUrl = this.getUrlByBlueprintId(blueprintId);
this.horizontal = this.isHorizontal(blueprintId);
cardCache[blueprintId] = {
imageUrl: this.imageUrl,
horizontal: this.horizontal
};
}
}
},