PokéRogue
    Preparing search index...
    Index

    Constructors

    Properties

    bgm: string
    biomeId: BiomeId
    eventTarget: EventTarget = ...
    ignoreAbilities: boolean
    ignoringEffectSource: BattlerIndex | null
    lastTimeOfDay: TimeOfDay
    playerFaints: number

    Saves the number of times a party pokemon faints during a arena encounter.
    globalScene.currentBattle.enemyFaints is the corresponding faint counter for the enemy (this resets every wave).

    playerTerasUsed: number = 0
    pokemonPool: ArenaPokemonPools
    positionalTagManager: PositionalTagManager = ...

    All currently-active PositionalTags on both sides of the field, sorted by tag type.

    tags: ArenaTag[] = []

    All currently-active ArenaTags on both sides of the field.

    terrain: Terrain | null
    trainerPool: TrainerPools
    weather: Weather | null

    Accessors

    • get bgmLoopPoint(): number

      A float representing the loop point of the current biome's bgm in seconds

      Returns number

    • get trainerChance(): number

      The denominator for the chance for a trainer spawn (e.g. if this is 4, then the chance for a trainer battle in that biome is 1/4)

      Returns number

    Methods

    • Add a new ArenaTag to the arena, triggering overlap effects on existing tags as applicable.

      Parameters

      • tagType: ArenaTagType

        The ArenaTagType of the tag to add.

      • turnCount: number

        The number of turns the newly-added tag should last.

      • sourceMove: MoveId | undefined

        The MoveId of the move creating the tag, or undefined if not from a move.

      • sourceId: number

        The PID of the Pokemon creating the tag.

      • side: ArenaTagSide = ArenaTagSide.BOTH

        The ArenaTagSide(s) to which the tag should apply; default ArenaTagSide.BOTH.

      • quiet: boolean = false

        Whether to suppress messages produced by tag addition; default false.

      Returns boolean

      true if the tag was successfully added without overlapping.

    • Helper method to determine whether or not to reroll a legend-like species generation attempt based on the estimated BST and wave.

      Parameters

      • species: PokemonSpecies

        The species being checked

      • adjustedWave: number

        The adjusted wave index, accounting for Daily Mode

      Returns boolean

      Whether rerolling is required

    • Generates a boss BiomePoolTier for a given tier value.

      Tier Tier Values Chance
      Boss 20-63 44/64
      Boss R 6-19 14/64
      Boss SR 1-5 5/64
      Boss UR 0 1/64

      Parameters

      • tierValue: number

        Number from 0-63

      Returns BiomePoolTier

      the generated BiomePoolTier

    • Generates a non-boss BiomePoolTier for a given tier value.

      Tier Tier Values Chance
      Common 156-511 356/512
      Uncommon 32-155 124/512
      Rare 6-31 26/512
      Super Rare 1-5 5/512
      Ultra Rare 0 1/512

      Parameters

      • tierValue: number

        Number from 0-511

      Returns BiomePoolTier

      the generated BiomePoolTier

    • Returns boolean

      Whether the current biome takes place "outdoors" (for the purposes of time of day tints)

    • Sets weather to the override specified in overrides.ts

      Returns void

    • Generate a random Pokemon species for the current biome

      Parameters

      • waveIndex: number

        The current wave number

      • level: number

        The level of the Pokemon to generate

      • attempt: number = 0

        Internal counter used to track legendary mon rerolls; should always be 0 when called initially

      • luckValue: number = 0

        (Default 0) The player's luck value, used to decrease the RNG ceiling of higher rarities (and thus make them more likely)

      • OptionalisBoss: boolean

        (Optional) Whether the Pokemon is a boss

      Returns PokemonSpecies

      A Pokemon species.

    • Find and remove all ArenaTags with the given tag types on the given side of the field.

      Parameters

      Returns void

      Review the other tag manipulation functions to see if they can be migrated towards using this (more efficient + foolproof)

    • Clears weather, terrain and arena tags when entering new biome or trainer battle.

      Returns void

    • Sets a random weather based on the time of day and the current biome

      Returns void

    • Parameters

      • ignoreAbilities: boolean
      • ignoringEffectSource: BattlerIndex | null = null

      Returns void

    • Function to trigger all weather based form changes

      Parameters

      • Optionalsource: Pokemon

        The Pokemon causing the changes by removing itself from the field

      Returns void

    • Function to trigger all weather based form changes back into their normal forms

      Returns void

    • Attempt to set the current terrain to the specified type.

      Parameters

      • terrain: TerrainType

        The TerrainType to try and set.

      • ignoreAnim: boolean = false

        (Default false) Whether to prevent showing an the animation

      • Optionaluser: Pokemon

        (Optional) The Pokemon creating the terrain

      Returns boolean

      Whether the terrain was successfully set.