[Review]DoubleX RMVXA Basic ATB Bar

Purpose
Aids other scripters to learn how atb system addon dependency can be solved

Script Calls
  1. #  * Battle manipulations                                                      |
  2. #    1. batb_offset_change = true                                              |
  3. #       - Notifies that the atb bars' x or y offsets are changed               |
Expand to see the code.


Configurations
  1.    # Sets the actor atb bars to be shown at their sprites instead of the
  2.     # status window if ATB_BAR_ACTOR returns true
  3.     # It should only return true if the actor sprites are already created
  4.     # If ATB_BAR_WIDTH_SWITCH_ID is a natural number, the state of switch with
  5.     # id ATB_BAR_WIDTH_SWITCH_ID will be used instead of using ATB_BAR_ACTOR
  6.     # The state of switch with id ATB_BAR_WIDTH_SWITCH_ID should remain the same
  7.     # during the same battle to ensure proper atb bar displays
  8.     ATB_BAR_ACTOR = false
  9.     ATB_BAR_WIDTH_SWITCH_ID = 0
  10.  
  11.     # Sets the maximum atb bar width as ATB_BAR_W
  12.     # If ATB_BAR_W_VAR_ID is a natural number, the value of variable with id
  13.     # ATB_BAR_W_VAR_ID will be used instead of using ATB_BAR_W
  14.     # The value of variable with id ATB_BAR_W_VAR_ID should remain the same
  15.     # during the same battle to ensure proper atb bar displays
  16.     ATB_BAR_W = 48
  17.     ATB_BAR_W_VAR_ID = 0
  18.  
  19.     # Sets the atb bar height as ATB_BAR_H
  20.     # If ATB_BAR_H_VAR_ID is a natural number, the value of variable with id
  21.     # ATB_BAR_H_VAR_ID will be used instead of using ATB_BAR_H
  22.     # The value of variable with id ATB_BAR_H_VAR_ID should remain the same
  23.     # during the same battle to ensure proper atb bar displays
  24.     ATB_BAR_H = 12
  25.     ATB_BAR_H_VAR_ID = 0
  26.  
  27.     # Sets the atb bar x offset from the battler sprite as ATB_BAR_X
  28.     # If ATB_BAR_X_VAR_ID is a natural number, the value of variable with id
  29.     # ATB_BAR_X_VAR_ID will be used instead of using ATB_BAR_X
  30.     # The value of variable with id ATB_BAR_X_VAR_ID should remain the same
  31.     # during the same battle to ensure proper atb bar displays
  32.     ATB_BAR_X = -12
  33.     ATB_BAR_X_VAR_ID = 0
  34.  
  35.     # Sets the atb bar y offset from the battler sprite as ATB_BAR_Y
  36.     # If ATB_BAR_Y_VAR_ID is a natural number, the value of variable with id
  37.     # ATB_BAR_Y_VAR_ID will be used instead of using ATB_BAR_Y
  38.     # The value of variable with id ATB_BAR_Y_VAR_ID should remain the same
  39.     # during the same battle to ensure proper atb bar displays
  40.     ATB_BAR_Y = -8
  41.     ATB_BAR_Y_VAR_ID = 0
  42.  
  43.     # Sets the atb bar z position as ATB_BAR_Z
  44.     # If ATB_BAR_Z_VAR_ID is a natural number, the value of variable with id
  45.     # ATB_BAR_Z_VAR_ID will be used instead of using ATB_BAR_Z
  46.     # The value of variable with id ATB_BAR_Z_VAR_ID should remain the same
  47.     # during the same battle to ensure proper atb bar displays
  48.     ATB_BAR_Z = 125
  49.     ATB_BAR_Z_VAR_ID = 0
  50.  
  51.     # Sets the atb back bar color 1 as ATB_BACK_COLOR1
  52.     # If ATB_BACK_COLOR1_VAR_ID is a natural number, the value of variable with
  53.     # id ATB_BACK_COLOR1_VAR_ID will be used instead of using ATB_BACK_COLOR1
  54.     # The value of variable with id ATB_BACK_COLOR1_VAR_ID should remain the
  55.     # same during the same battle to ensure proper atb back bar color displays
  56.     ATB_BACK_COLOR1 = 15
  57.     ATB_BACK_COLOR1_VAR_ID = 0
  58.  
  59.     # Sets the atb back bar color 2 as ATB_BACK_COLOR2
  60.     # If ATB_BACK_COLOR2_VAR_ID is a natural number, the value of variable with
  61.     # id ATB_BACK_COLOR2_VAR_ID will be used instead of using ATB_BACK_COLOR2
  62.     # The value of variable with id ATB_BACK_COLOR2_VAR_ID should remain the
  63.     # same during the same battle to ensure proper atb back bar color displays
  64.     ATB_BACK_COLOR2 = 15
  65.     ATB_BACK_COLOR2_VAR_ID = 0
Expand to see the code.


Games Using This Script
None so far

Video


Prerequisites
Scripts:
1. DoubleX RMVXA Basic ATB:
http://www.hbgames.org/forums/viewtopic.php?f=11&t=78855
Abilities:
1. Little RGSS3 scripting proficiency to fully utilize this script

Terms Of Use
You shall keep this script's Script Info part's contents intact
You shalln't claim that this script is written by anyone other than DoubleX or his aliases
None of the above applies to DoubleX or his aliases

Instructions
1. Open the script editor and put this script into an open slot between Materials and Main, save to take effect.

Authors
DoubleX

Changelog
  1. #    v1.00b(GMT 0900 9-9-2015):                                                |
  2. #    1. Fixed drawing the actor sprite atb bars and window atb bars together   |
  3. #    2. Fixed not updating the atb bar positions when their offsets changes    |
  4. #    3. Little RGSS3 scripting proficiency's needed to fully utilize the script|
  5. #    v1.00a(GMT 0900 22-8-2015):                                               |
  6. #    1. 1st version of this script finished                                    |
Expand to see the code.


Download Link
http://pastebin.com/Lg0NCYU5

Original thread: https://www.hbgames.org/forums/viewtopic.php?t=78857