def buildStarter(self, species): """ Creates a Pokemon with Starter stats """ self.name = species self.species = species self.level = 5 self.ability = Ability() self.battleDelegate = PokemonBattleDelegate().buildStarter(self) self.displayDelegate = PokemonDisplayDelegate(self.species) return self
def buildStarter(species): """ Creates a Starter Pokemon's Display Delegate """ return PokemonDisplayDelegate(species)
def loadFromXML(tree, pkmn): """ Loads a Pokemon object from a file """ if tree is None: return PokemonDisplayDelegate(pkmn.species) else: return AlternateDisplayDelegate(tree.text)