| Modifier and Type | Field and Description |
|---|---|
java.util.ArrayList<java.lang.String> |
aliases |
| Constructor and Description |
|---|
SpecFlag(java.lang.String... aliases) |
SpecFlag(java.lang.String key,
boolean value) |
| Modifier and Type | Method and Description |
|---|---|
void |
apply(EntityPixelmon pixelmon)
Applies the spec to an
EntityPixelmon. |
void |
apply(Pokemon pokemon)
Applies the spec to a
Pokemon. |
SpecValue<java.lang.Boolean> |
clone()
Clones the data of this spec into a new one, to break references.
|
java.util.List<java.lang.String> |
getKeys()
All the acceptable keys for this spec type.
|
java.lang.Class<? extends SpecValue<?>> |
getSpecClass()
The
SpecValue class that this will create. |
java.lang.Class<java.lang.Boolean> |
getValueClass()
Gets the class for the generic T defining this SpecValue.
|
SpecValue<java.lang.Boolean> |
make(boolean value) |
boolean |
matches(EntityPixelmon pixelmon)
Returns true if the given
EntityPixelmon has this spec. |
boolean |
matches(Pokemon pokemon)
Returns true if the given
Pokemon has this spec. |
SpecValue<java.lang.Boolean> |
parse(java.lang.String arg)
Attempts to parse a spec of this type from a String argument.
|
SpecValue<?> |
readFromNBT(net.minecraft.nbt.NBTTagCompound nbt)
Reads this type of spec value from NBT.
|
boolean |
sentToClient()
Whether or not the client is informed about this spec.
|
java.lang.String |
toParameterForm(SpecValue<?> value)
Restores it to the form used in commands.
|
void |
writeToNBT(net.minecraft.nbt.NBTTagCompound nbt,
SpecValue<?> value)
Writes this type of spec value to NBT.
|
public SpecFlag(java.lang.String... aliases)
public SpecFlag(java.lang.String key,
boolean value)
public java.util.List<java.lang.String> getKeys()
ISpecTypepublic SpecValue<java.lang.Boolean> make(boolean value)
public SpecValue<java.lang.Boolean> parse(java.lang.String arg)
ISpecTypepublic SpecValue<?> readFromNBT(net.minecraft.nbt.NBTTagCompound nbt)
ISpecTypereadFromNBT in interface ISpecTypepublic void writeToNBT(net.minecraft.nbt.NBTTagCompound nbt,
SpecValue<?> value)
ISpecTypewriteToNBT in interface ISpecTypepublic java.lang.Class<? extends SpecValue<?>> getSpecClass()
ISpecTypeSpecValue class that this will create. This is needed for JSON deserialization.getSpecClass in interface ISpecTypepublic java.lang.String toParameterForm(SpecValue<?> value)
ISpecTypetoParameterForm in interface ISpecTypepublic java.lang.Class<java.lang.Boolean> getValueClass()
SpecValuegetValueClass in class SpecValue<java.lang.Boolean>public void apply(EntityPixelmon pixelmon)
SpecValueEntityPixelmon.public void apply(Pokemon pokemon)
SpecValuePokemon.public boolean matches(EntityPixelmon pixelmon)
SpecValueEntityPixelmon has this spec.public boolean matches(Pokemon pokemon)
SpecValuePokemon has this spec.public SpecValue<java.lang.Boolean> clone()
SpecValuepublic boolean sentToClient()