Add a convenience function for checking start color if you have the full colorPrint

git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@1017 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
Mike Thomas
2010-10-08 18:56:17 +00:00
parent 7dda42a091
commit b5a19fc68d
@@ -304,6 +304,16 @@ public class ColorPository implements Serializable
return cids;
}
/**
* Returns true if the specified color is legal for use at character creation time. false is
* always returned for non-existent colors or classes.
*/
public boolean isLegalStartColor (int colorPrint)
{
ColorRecord color = getColorRecord(colorPrint >> 8, colorPrint & 0xFF);
return (color == null) ? false : color.starter;
}
/**
* Returns true if the specified color is legal for use at character creation time. false is
* always returned for non-existent colors or classes.