Class ShowdownConverter
java.lang.Object
com.pixelmonmod.pixelmon.api.pokemon.export.impl.ShowdownConverter
- All Implemented Interfaces:
PokemonConverterProxy
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final char
static final String
static final String
static final String
static final String
static final String
static final char
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String[]
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
addColonSeparated
(StringBuilder builder, String label, Object value) Separates a label and a value by a colon, and inserts a newline afterwards.getExportText
(Pokemon data) Gets exportable text for the Pokémon.int
getIntAfterColon
(String string) Gets the part of a string that is after a colon, converted to an integer.getStringAfterColon
(String string) Gets the part of a string that is after a colon.importText
(String importText) Parses import text and saves it to the Pokémon.importText
(String... importText) Imports formatted text to a Pokemon instanceMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.pixelmonmod.pixelmon.api.pokemon.export.PokemonConverterProxy
getExportText, getExportText, getExportText, getFormattedExportedText, getFormattedExportedText, getFormattedExportedText, importText
-
Field Details
-
SPECIES_TEXT
- See Also:
-
GENDER_TEXT
- See Also:
-
ABILITY_TEXT
- See Also:
-
LEVEL_TEXT
- See Also:
-
SHINY_TEXT
- See Also:
-
HAPPINESS_TEXT
- See Also:
-
EV_TEXT
- See Also:
-
NATURE_TEXT
- See Also:
-
IV_TEXT
- See Also:
-
POKE_BALL_TEXT
- See Also:
-
GROWTH_TEXT
- See Also:
-
CLONES_TEXT
- See Also:
-
RUBY_TEXT
- See Also:
-
MINIOR_CORE_TEXT
- See Also:
-
SMELT_TEXT
- See Also:
-
MOVE_TEXT
- See Also:
-
STAT_TEXT
-
MALE_SYMBOL
public static final char MALE_SYMBOL- See Also:
-
FEMALE_SYMBOL
public static final char FEMALE_SYMBOL- See Also:
-
SHINY_YES
- See Also:
-
SHINY_NO
- See Also:
-
-
Constructor Details
-
ShowdownConverter
public ShowdownConverter()
-
-
Method Details
-
getExportText
Gets exportable text for the Pokémon.- Specified by:
getExportText
in interfacePokemonConverterProxy
- Parameters:
data
- The data object to export from.- Returns:
- Exportable text for the Pokémon.
-
addColonSeparated
Separates a label and a value by a colon, and inserts a newline afterwards.- Parameters:
builder
- The string builder to add the colon-separated string to.label
- The label to put before the colon.value
- The value to put after the colon.
-
importText
Description copied from interface:PokemonConverterProxy
Imports formatted text to a Pokemon instance- Specified by:
importText
in interfacePokemonConverterProxy
- Parameters:
importText
- The formatted text- Returns:
- The Pokemon instance
- Throws:
PokemonImportException
- thrown when there's an error with the given text
-
importText
Parses import text and saves it to the Pokémon.- Specified by:
importText
in interfacePokemonConverterProxy
- Parameters:
importText
- The text to save to the Pokémon.- Returns:
- Whether the text was successfully parsed.
- Throws:
ShowdownImportException
-
getIntAfterColon
Gets the part of a string that is after a colon, converted to an integer.- Parameters:
string
- The string to filter.- Returns:
- The part of the string that is after a colon, converted to an integer.
-
getStringAfterColon
Gets the part of a string that is after a colon.- Parameters:
string
- The string to filter.- Returns:
- The part of the string that is after a colon.
-