📒
Deluxe Battle Kit Tutorial
  • Deluxe Battle Kit for v21.1
    • Deluxe Animations
      • Animation: Databoxes
      • Animation: Item Usage
      • Animation: Fleeing Pokemon
      • Animation: Mega Evolution
      • Animation: Primal Reversion
      • Animation: Shadow Pokemon
    • Deluxe Battle Rules
      • Rules: Battle Modes
      • Rules: Battle Visuals
      • Rules: Battle Audio
      • Rules: Editing the Player
      • Rules: Mega Evolution
      • Rules: Capturing Pokemon
      • Rules: Editing Wild Pokemon
    • Wild Boss Attributes
      • Attribute: Boosted HP
      • Attribute: Immunities
    • Mid-Battle Scripting
      • Trigger Keys
        • Triggers: Round Phases
        • Triggers: Battler Turns
        • Triggers: Item Usage
        • Triggers: Wild Capture
        • Triggers: Switching
        • Triggers: Megas & Primals
        • Triggers: Move Usage
        • Triggers: Damage Results
        • Triggers: Battler Condition
        • Triggers: End of Effects
        • Triggers: End of Battle
        • Triggers: Variable
        • Triggers: Choices
        • Triggers: Extensions
          • Extensions: User
          • Extensions: Frequency
      • Command Keys
        • Commands: Text & Speech
        • Commands: Audio & Animation
        • Commands: Utilities
        • Commands: Battle Mechanics
        • Commands: Battler Attributes
        • Commands: Battlefield Conditions
        • Commands: Extensions
      • Advanced Scripting
        • Advanced: Speech Utilities
          • Speech: General
          • Speech: Choices
          • Speech: Speakers
        • Advanced: Variable Utilities
        • Advanced: Storing Scripts
        • Advanced: Hardcoding
        • Advanced: Global Scripts
    • Example Battles
      • Examples: Wild Battles
      • Examples: Trainer Battles
    • Miscellaneous Utilities
    • Add-On Tutorials
      • Enhanced Battle UI
        • UI: Battler Info
        • UI: Poke Ball Shortcut
        • UI: Move Info
      • SOS Battles
        • SOS: Plugin Overview
        • SOS: PBS Data
        • SOS: Battle Rules
        • SOS: Mid-Battle Scripting
      • Raid Battles
      • Z-Power
        • Z-Power: Z-Moves
        • Z-Power: Ultra Burst
        • Z-Power: Animations
        • Z-Power: Battle Rules
        • Z-Power: Mid-Battle Scripting
      • Dynamax
        • Dynamax: Properties
        • Dynamax: Move Data
        • Dynamax: Form Data
        • Dynamax: Animations
        • Dynamax: Battle Rules
        • Dynamax: Mid-Battle Scripting
      • Terastallization
        • Terastal: Tera Types
        • Terastal: Tera Forms
        • Terastal: Animations
        • Terastal: Battle Rules
        • Terastal: Mid-Battle Scripting
      • Improved Item AI
        • Item AI: Handlers
      • Wonder Launcher
        • Launcher: Plugin Overview
        • Launcher: PBS Data
        • Launcher: Battle Rules
        • Launcher: Mid-Battle Scripting
      • Animated Pokemon System
        • Animated: Pokemon Sprites
        • Animated: Dynamic Sprite Effects
        • Animated: UI Sprites
        • Animated: Sprite Editor
        • Animated: Mid-Battle Scripting
      • Animated Trainer Intros
        • Intros: Trainer Sprites
        • Intros: Sprite Editor
        • Intros: UI Sprites
        • Intros: Battle Transitions
        • Intos: Mid-Battle Scripting
Powered by GitBook
On this page

Was this helpful?

  1. Deluxe Battle Kit for v21.1
  2. Deluxe Battle Rules

Rules: Editing Wild Pokemon

Section 2.G

These are rules related to editing certain attributes on wild Pokemon to customize encounters.

"editWildPokemon"

You can use this rule to edit various attributes of wild Pokemon prior to initiating battle. This allows you to customize their Natures, IV's, shinyness, and more. In double or triple wild battles, this only edits the attributes of the primary wild Pokemon that appears in the first slot. This is entered as setBattleRule("editWildPokemon", Attributes), where "Attributes" is a hash containing all the settings you want to apply to the wild Pokemon. More details on this found below.

"editWildPokemon2"

This rule functions identically to "editWildPokemon", ​accept this rule only edits the attributes of the second wild Pokemon in a double or triple battle.

"editWildPokemon3"

This rule functions identically to "editWildPokemon", accept this rule only edits the attributes of the third wild Pokemon in a triple battle.


Here are all of the possible attributes you may set in a hash for any of the above rules:

Key
Value
Description

:species

Species ID

Changes the species of the wild Pokemon.

:form

Integer

Sets the form of the wild Pokemon.

:form_simple

Integer

Sets the form of the wild Pokemon. Use this instead of :form to skip the move learning prompt for species like Rotom.

:name

String

Sets the nickname of the wild Pokemon.

:level

Integer

Sets the level of the wild Pokemon.

:gender

Integer

Sets the gender of the wild Pokemon (0 = Male, 1 = Female).

:hp

Integer

Sets the HP of the wild Pokemon (out of its total HP).

:status

Status ID

Sets the status condition of the wild Pokemon.

:statusCount

Integer

Sets the status counter of the wild Pokemon (for Sleep and Poison).

:shiny

Boolean

Sets whether this wild Pokemon should be shiny or not.

:super_shiny

Boolean

Sets whether this wild Pokemon should be super shiny or not.

:nature

Nature ID

Sets the Nature of the wild Pokemon.

:item

Item ID

Sets the Item of the wild Pokemon.

:mail

Mail Object

Sets the held mail of the wild Pokemon. You must create the mail object prior to this rule.

:ability

Ability ID

Sets the Ability of the wild Pokemon.

:ability_index

Integer

Sets the Ability index of the wild Pokemon.

:moves

Move ID (or Array)

Sets the moves this wild Pokemon will have.

:ribbons

Ribbon ID (or Array)

Sets the ribbons this wild Pokemon will have.

:pokerus

Boolean

Sets whether the wild Pokemon will have Pokerus or not.

:happiness

Integer

Sets the happiness level of this wild Pokemon (0-255).

:iv

Integer, Array or Hash

Sets the IV's of the wild Pokemon. When set as an integer, all of the Pokemon's IV's are set to the same number. When set as an array, each of the Pokemon's IV's are set to the number in the array (in PBS stat order). When set as a hash, directly sets the IV's of each stat ID in the hash.

:ev

Integer, Array or Hash

Sets the EV's of the wild Pokemon. When set as an integer, all of the Pokemon's EV's are set to the same number. When set as an array, each of the Pokemon's EV's are set to the number in the array (in PBS stat order). When set as a hash, directly sets the EV's of each stat ID in the hash.

:obtain_text

String

Sets the met location text that will appear in the memo page of the Summary once this wild Pokemon has been captured.


Example:

setBattleRule("editWildPokemon", {
  :name    => "Sparky",
  :shiny   => true,
  :ability => :VOLTABSORB,
  :item    => :LIGHTBALL,
  :nature  => :HASTY,
  :moves   => [:VOLTTACKLE, :SURF, :WISH, :ENCORE],
  :iv      => 31
})
WildBattle.start(:PIKACHU, 35)

Exclusive Attributes for Supported Plugins

Key
Value
Description

:shiny_leaf

Integer (0-6)

Sets a number of shiny leaves on the wild Pokemon. Six leaves will apply a shiny leaf crown.

Key
Value
Description

:memento

Ribbon or Mark ID

Sets the memento that should be adorned on this wild Pokemon. If the memento has a title, that title will be automatically given to the Pokemon.

:scale

Integer (0-255)

Sets the size of the wild Pokemon, where 0 is the smallest and 255 is the largest.

Key
Value
Description

:dynamax_able

Boolean

Toggles whether the wild Pokemon is capable of using Dynamax.

:dynamax_lvl

Integer (0-10)

Sets the Dynamax level of the wild Pokemon.

:gmax_factor

Boolean

Sets whether the wild Pokemon has G-Max Factor.

:dynamax

Boolean

Sets whether the wild Pokemon is Dynamaxed.

Key
Value
Description

:terastal_able

Boolean

Toggles whether the wild Pokemon is capable of using Terastallization.

:tera_type

Type ID

Sets the Tera type of the wild Pokemon.

:terastallized

Boolean

Sets whether the wild Pokemon is Terastallized.

PreviousRules: Capturing PokemonNextWild Boss Attributes

Last updated 1 year ago

Was this helpful?