java.lang.Object
com.pixelmonmod.pixelmon.entities.npcs.registry.TrainerData
All Implemented Interfaces:
ITrainerData

public class TrainerData extends Object implements ITrainerData
JSON data for NPC Trainers.
  • Field Details

    • trainerType

      public BaseTrainer trainerType
      Indexing data for the Trainer.
    • winnings

      public int winnings
      The base amount of PokéDollars awarded after defeating the Trainer.
    • id

      public String id
      The name of the Trainer class.
  • Constructor Details

    • TrainerData

      public TrainerData(String id)
      Initializes the NPC Trainer data.
      Parameters:
      id - The name of the Trainer class.
  • Method Details

    • addPokemon

      public void addPokemon(PokemonBase poke)
      Adds a possible Pokémon to the Trainer.
      Parameters:
      poke - A Pokémon the Trainer can have.
    • addChat

      public void addChat(String opening, String win, String lose)
      Adds possible dialogue to the Trainer.
      Parameters:
      opening - Dialogue when the Trainer begins a battle.
      win - Dialogue when the Trainer wins a battle.
      lose - Dialogue when the Trainer loses a battle.
    • getRandomParty

      public ArrayList<Pokemon> getRandomParty()
      Randomly chooses a party for the Trainer to have.
      Returns:
      A randomly chosen party for the Trainer.
    • getRandomName

      public int getRandomName()
      Randomly chooses an index corresponding to a name the Trainer can have.
      Returns:
      An index corresponding to a name the Trainer can have.
    • getRandomChat

      public int getRandomChat()
      Randomly chooses an index corresponding to dialogue the Trainer can have.
      Returns:
      An index corresponding to dialogue the Trainer can have.
    • getRandomLevel

      public int getRandomLevel()
      Randomly chooses an index corresponding to a pokemonLevel the Trainer's Pokémon can be.
      Returns:
      An index corresponding to a pokemonLevel the Trainer's Pokémon can be.
    • getMinLevel

      public int getMinLevel()
    • getMaxLevel

      public int getMaxLevel()
    • getMinPartyPokemon

      public int getMinPartyPokemon()
    • getMaxPartyPokemon

      public int getMaxPartyPokemon()
    • getName

      public String getName(int index)
      Specified by:
      getName in interface ITrainerData
    • getChat

      public TrainerChat getChat(int index)
      Specified by:
      getChat in interface ITrainerData