From 1f66ec432d457bc56cc702c5a8243f879daae80d Mon Sep 17 00:00:00 2001 From: Maxmtg Date: Sun, 2 Feb 2014 01:08:53 +0000 Subject: [PATCH] shifted MagicColors 1 bit to the right --- forge-core/src/main/java/forge/card/ColorSet.java | 2 +- forge-core/src/main/java/forge/card/MagicColor.java | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/forge-core/src/main/java/forge/card/ColorSet.java b/forge-core/src/main/java/forge/card/ColorSet.java index 3e96a85734b..325984e4018 100644 --- a/forge-core/src/main/java/forge/card/ColorSet.java +++ b/forge-core/src/main/java/forge/card/ColorSet.java @@ -62,7 +62,7 @@ public final class ColorSet implements Comparable, Iterable { } public static ColorSet fromMask(final int mask) { - int mask32 = (mask & MagicColor.ALL_COLORS) >> 1; + int mask32 = mask & MagicColor.ALL_COLORS; if (allColors[mask32] == null) { allColors[mask32] = new ColorSet((byte) mask); } diff --git a/forge-core/src/main/java/forge/card/MagicColor.java b/forge-core/src/main/java/forge/card/MagicColor.java index 4e024df98ae..d5665ee03af 100644 --- a/forge-core/src/main/java/forge/card/MagicColor.java +++ b/forge-core/src/main/java/forge/card/MagicColor.java @@ -11,11 +11,11 @@ import com.google.common.collect.ImmutableList; public class MagicColor { public static final byte COLORLESS = 0; - public static final byte WHITE = 1 << 1; - public static final byte BLUE = 1 << 2; - public static final byte BLACK = 1 << 3; - public static final byte RED = 1 << 4; - public static final byte GREEN = 1 << 5; + public static final byte WHITE = 1 << 0; + public static final byte BLUE = 1 << 1; + public static final byte BLACK = 1 << 2; + public static final byte RED = 1 << 3; + public static final byte GREEN = 1 << 4; public static final byte ALL_COLORS = BLACK | BLUE | WHITE | RED | GREEN; public static final int NUMBER_OR_COLORS = 5;