Preparing your files

Please wait until the download is ready.

Elite Battle: DX

Elite Battle: DX

by Luka S.J.

Take your battles to the next level with the ultimate Battle System skin!

Battle Environments

Elite Battle: DX has a modular method of constructing the battle environments that you see during the battle. The idea boils down to adding parameters to a main Hash and passing this Hash as a configuration option.
You can also configure the battle environments in the Plugins/Elite Battle DX/[003] Config/Environments.rb file, as a means of easily grouping and accessing the various setups.

EliteBattle.set(:nextBattleBack, { options })
# Function used to set the Battle Environment for the next battle
# Options include the following
# - "backdrop" => (String)              | sets background graphic from Graphics/EBDX/Battlebacks/battlebg/
# - "base" => (String)                  | sets battle base graphic from Graphics/EBDX/Battlebacks/base/
# - "sky" => (Boolean)                  | shows outdoors skybox
# - "water" => (Boolean)                | shows animated water overlay
# - "spinLights" => (Boolean)           | shows PWT styled spinning lights
# - "lightsA" => (Boolean)              | shows lights, variation A
# - "lightsB" => (Boolean)              | shows lights, variation B
# - "lightsC" => (Boolean)              | shows lights, variation C
# - "vacuum" => (Boolean)               | creates animated ring particles (tunneling)
# - "bubbles" => (Boolean)              | creates a stream of bubbles on screen
# - "noshadow" => (Boolean)             | remove battler shadows from the scene

# - "imgXXX" => { options }             | shows an image file with options
#   - :scrolling => (Boolean)           | uses ScrollingSprite class to animate a scrolling image
#   - :sheet => (Boolean)               | uses SpriteSheet class to animate from spritesheet (requires :frames => (Numeric))
#   - :animated => (Boolean)            | uses BitmapWrapperSprite class to animate from standard sheet
#   - :rainbow => (Boolean)             | uses RainbowSprite class to animate hue shifts
#   - :frames => (Numeric)              | indicates how many frames spritesheet contains
#   - :bitmap => (String)               | sets image graphic from Graphics/EBDX/Battlebacks/elements/
#   - :scrolling => (Boolean)           | uses ScrollingSprite class to animate a scrolling image
#   - :flat => (Boolean)                | positions the image flat with the room
#   - :effect => (String)               | Applies additional animations
#         "wind" = animation to sway with wind
#         "rotate" = continuous rotation
#   - :colorize => (Boolean)(Color)     | applies color based on backdrop or Color.new object (if provided)
#   - :vertical => (Boolean)            | sets vertical animation if applicable
#   - :x, :y, :z, :ox, :oy, :speed,
#     :direction, :opacity => (Numeric) | standard Sprite parameters

# - "trees", "tallGrass" => { options } | batch renders trees in environment
#   - :bitmap => (String)               | sets bitmap graphic from Graphics/EBDX/Battlebacks/elements/
#   - :elements => (Numeric)            | number of trees to draw
#   - :x => (Numeric Array)             | x position of individual trees
#   - :y => (Numeric Array)             | y position of individual trees
#   - :z => (Numeric Array)             | z position of individual trees
#   - :zoom => (Numeric Array)          | zoom of individual trees
#   - :mirror => (Boolean Array)        | whether to mirror individual tree sprite
EliteBattle.set(:nextBattleBack, {
  "backdrop" => "DanceFloor", "img001" => {
    :bitmap => "discoBg",
    :ox => 0, :flat => true, :rainbow => true, :speed => 8
  }, "lightsB" => true, "img002" => {
    :bitmap => "crowd", 
    :oy => 32, :y => 102, :z => 2, :flat => false, :sheet => true,
    :vertical => true, :speed => 8, :frames => 2
  }
})

The { options } parameter for the data hash can be expressed as a symbolic name, which will serve to reference a valid environment defined in the Plugins/Elite Battle DX/[003] Config/Environments.rb file:
EliteBattle.set(:nextBattleBack, :DISCO)
You can also configure the Battle Environments for existing environments as defined in Essentials

EliteBattle.add_data(environment, :Environment, :BACKDROP, { options })
# Where environment can belong to the following:
# - :Cave
# - :MovingWater
# - :Underwater
# - :Forest
# - :None (Indoor locations)
# - :Grass

EliteBattle.add_data(terrain, :TerrainTag, :BACKDROP, { options })
# Extra configurations to enrich the Battle Environment based on the current terrain:
# - :Rock
# - :Puddle
# - :Sand
# - :Grass, :TallGrass

If you've defined your own PBEnvironment and PBTerrain entries, you'll be able to use them in the Battle Environment setup as long as you use their proper symbolic name during the data definition.

EliteBattle.add_data(:Forest, :Environment, :BACKDROP, {
  "backdrop" => "Forest", "lightsC" => true, "img001" => {
    :bitmap => "forestShade", :z => 1, :flat => true,
    :oy => 0, :y => 94, :sheet => true, :frames => 2, :speed => 16
  }, "trees" => {
    :bitmap => "treePine", :colorize => false, :elements => 8,
    :x => [92,248,300,40,138,216,274,318],
    :y => [132,132,144,118,112,118,110,110],
    :zoom => [1,1,1.1,0.9,0.8,0.85,0.75,0.75],
    :z => [2,2,2,1,1,1,1,1],
  }, "outdoor" => false
})

You can also get the configured data hash that the system will try to generate based on the current environment and terrain the player is standing in using the following:
data = EliteBattle.getNextBattleEnv
You can then edit and use this data hash to push a modified version of your generated environment by forcefully setting it as the new battle environment.