Modifier and Type | Method and Description |
---|---|
static Race |
fromName(java.lang.String raceName)
Converts specified race name to race enumeration
|
java.lang.String |
getDefaultSpritesheet(Gender sex)
Returns default spritesheet name for this race
|
java.lang.String |
getRandomTextId(java.lang.String category)
Returns random text ID of specified category for this race
|
static Race |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Race[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Race HUMAN
public static final Race GOBLIN
public static final Race WOLF
public static Race[] values()
for (Race c : Race.values()) System.out.println(c);
public static Race valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic static Race fromName(java.lang.String raceName)
raceName
- String with race namepublic java.lang.String getDefaultSpritesheet(Gender sex)
public java.lang.String getRandomTextId(java.lang.String category)
category
- Random text category (e.g. aggressive, idle or friendly)