Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 [RMXP]Game Over and Atoa Battle Status mishaps
#8
Meh, when all else fails. HIT IT WITH A HAMMER!!!!

So that's what I did.... twice over with two separate patches. Put em both below your ATB addon script:

I altered the Battlestatus window to be larger, so it can draw an entire 640x160 background can show... I expanded the window by 32px in all directions and moved it up and left by 16. And then I adjusted the objects within to match. Doing that, I got it to show the way you want (or I hope). I had to have some fun with the AT bars, making sure that the y-position of the bars adjusted each time the status window moved and stuff. I figure, most of your problems were in these sections. Enjoy.

Code:
#==============================================================================
# PATCH:  Battle Window Add-On & Scene GameOver Karen
# by DerVVulfman (Based on Atoa/Victor Sant's work)
# August 6, 2014
#==============================================================================
# This patch, placed below the Battle Windows add-on, rewrites the methods that
# draw and refresh  the Battle Status window.   Particularly for the purpose of
# allowing the use of a background image instead of a windowskin window.
#
# For that, this script must at least be placed below the Battle Window add-on
# script.  But if in use with his ATB add-on,  this this script must be placed
# directly below Atoa's Active Time Battle script.
#
# NOTE:  As this pastes a background image within the confines of the Battle
#        Status window, and the window itself has a 16px border all the way
#        around, the calculated dimensions of the battlestatus window have
#        been increased to compensate, as have the placement of the status
#        display objects such as 'draw hp', 'draw sp'.
#
#==============================================================================



#==============================================================================
# ** Window_BattleStatus
#------------------------------------------------------------------------------
#  This window displays the status of all party members on the battle screen.
#==============================================================================

class Window_BattleStatus < Window_Base
  #--------------------------------------------------------------------------
  # * Object Initialization
  #--------------------------------------------------------------------------
  def initialize
    super(Battle_Window[0]-16, Battle_Window[1]-16,
          Battle_Window[2]+32, Battle_Window[3]+32)
    self.contents = Bitmap.new(width - 32, height - 32)
    @level_up_flags = []
    for i in 0...$game_party.actors.size
      @level_up_flags << false
    end
    self.z = 900
    self.back_opacity = Battle_Window[4]
    self.opacity = Battle_Window[4] if Battle_Window[5]
    if Battle_Window_Backgroud != nil and Battle_Window_Backgroud != ''
      self.back_opacity = 0
      self.opacity      = 0
      @bg_img           = RPG::Cache.picture(Battle_Window_Backgroud)
      bw                = @bg_img.width
      bh                = @bg_img.height
      @bgsrc_rect       = Rect.new(0, 0, bw, bh)
    end    
    refresh
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    self.contents.clear
    if Battle_Window_Backgroud != nil and Battle_Window_Backgroud != ''
      self.contents.blt(0, 0, @bg_img, @bgsrc_rect)
    end
    @item_max = $game_party.actors.size
    for i in 0...$game_party.actors.size
      self.contents.font.size = 22
      hp_w = HP_Number[3] ? 140 : 80
      sp_w = SP_Number[3] ? 140 : 80
      actor = $game_party.actors[i]
      case Display_Type
      when 0
        wd = (width - 32) / Max_Party
        actor_x = Horizontal_Centralize ? ((i * wd) +  (wd * (Max_Party - $game_party.actors.size) / 2)) : i * wd
        actor_y = 0
      when 1
        actor_x = 0
        actor_y = i * 32
      when 2
        actor_x = Custom_Stat_Position[i][0]
        actor_y = Custom_Stat_Position[i][1]
      end
      draw_actor_battle_face(actor, 16+actor_x + Face_Config[0], 16+actor_y + Face_Config[1], Face_Config[2]) if Show_Faces
      draw_actor_battle_graphic(actor, 16+actor_x + Char_Config[0], 16+actor_y + Char_Config[1], Char_Config[2]) if Show_Char
      draw_actor_name(actor, 16+actor_x + Name_Config[0], 16+actor_y + Name_Config[1])
      draw_actor_hp(actor, 16+actor_x + HP_Text[0], 16+actor_y + HP_Text[1], hp_w)
      draw_actor_sp(actor, 16+actor_x + SP_Text[0], 16+actor_y + SP_Text[1], sp_w)
      draw_actor_level(actor, 16+actor_x + Level_Text[0], 16+actor_y + Level_Text[1]) if Draw_Level
      if @level_up_flags[i] and Lvl_Up_Flag
        self.contents.font.color = normal_color
        self.contents.draw_text(16+actor_x + State_Config[0], 16+actor_y + State_Config[1], 132, 32, Lvl_Up_Msg )
      else
        draw_actor_state(actor, 16+actor_x + State_Config[0], 16+actor_y + State_Config[1])
      end
    end
  end
end

Code:
#==============================================================================
# PATCH:  Atoa's Active Time Battle & Scene GameOver Karen
# by DerVVulfman (Based on Atoa/Victor Sant's work)
# August 6, 2014
#==============================================================================
# This patch, placed below the Active Timer Battle patch,  rewrites a method in
# the Window_BattleStatus class  that refreshes the AT waiting bars  as well as
# key methods that draws and places the AT bars within the window itself.
#
# For that, this script must be placed directly below Atoa's Active Time Battle
# script.
#
# NOTE:  Designed for use in tandem with the BattleStatus / Game_Over patch,
#        this patch has allowances that adjusts the position  of the bars by
#        16  or so pixels.   For further  vertical adjustments,  consult the
#        Y_METER_ADJUST configurable below.
#
# ADDTL: The refresh_meter method contains a couple rewrites. Of note is a
#        rewrite of the  'automatic adjustment' (case 1) branch as the ori-
#        ginal calculations of the face/hp/sp position didn't match up.
#
#==============================================================================


Y_METER_ADJUST = 48

#==============================================================================
# ** Window_BattleStatus
#------------------------------------------------------------------------------
#  This window displays the status of all party members on the battle screen.
#==============================================================================

class Window_BattleStatus < Window_Base
  #--------------------------------------------------------------------------
  # * Time bar update
  #--------------------------------------------------------------------------
  def active_time_update
    need_reset
    @atb_meters.refresh(self.y) if @atb_meters != nil
    @enm_meters.refresh if @enm_meters != nil
    @atb_bars.refresh if @atb_bars != nil
  end
end

#==============================================================================
# ** ATB_Meters
#------------------------------------------------------------------------------
# Class that shows the time meters of actors
#==============================================================================

class ATB_Meters
  #--------------------------------------------------------------------------
  # * Include Settings Module
  #--------------------------------------------------------------------------
  include Atoa
  #--------------------------------------------------------------------------
  # * Public Instance Variables
  #--------------------------------------------------------------------------
  attr_accessor :meters
  #--------------------------------------------------------------------------
  # * Object Initialization
  #--------------------------------------------------------------------------
  def initialize
    @meters = []
    @skin = RPG::Cache.windowskin(Meter_Skin)
    i = 0
    for actor in $game_party.actors
      @meter = MeterSprite.new(@skin, 5)
      refresh_meter(i)
      i += 1
    end
    refresh(Y_Meter - (Y_METER_ADJUST+8))
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh(y_position)
    i = 0
    for actor in $game_party.actors
      refresh_meter_y(i, actor, y_position + Y_METER_ADJUST)
      @meters[i].line = actor.atb_linetype
      @meters[i].amount = actor.atb_lineamount
      @meters[i].refresh
      @meters[i].atb_visible = true
      i += 1
    end
  end
  #--------------------------------------------------------------------------
  # * Update meter
  #     index : index
  #--------------------------------------------------------------------------
  def refresh_meter(index)
    actor = $game_party.actors[index]
    case Meter_Pos_Style
    when 0
      @meter.x = index * (624 / Max_Party) + 4 + X_Meter + 16
      @meter.y = Y_Meter
      @meter.z = 1000
    when 1
      # NEW -------------
      width = Battle_Window[2]+32
      wd = (width - 32) / Max_Party
      actor_x = 16 + (index * wd) +  (wd * (Max_Party - $game_party.actors.size) / 2)
      @meter.x = actor_x
      # -------------------
      #@meter.x = X_Meter + ((624 / Max_Party) * ((4 - $game_party.actors.size)/2.0 + index)).floor
      @meter.y = Y_Meter
      @meter.z = 1000
    when 2
      @meter.x = X_Meter
      @meter.y = index * 32 + Y_Meter
      @meter.z = 1000
    when 3
      @meter.x = actor.base_x - @skin.width / 2
      @meter.y = actor.base_y - @skin.height / 5
      @meter.z = 100
    when 4
      @meter.x = actor.base_x - @skin.width / 2
      @meter.y = actor.base_y - @skin.height / 5 - 64
      @meter.z = 2500
    when 5
      base = Meter_Position[index]
      @meter.x = base[0]
      @meter.y = base[1]
      @meter.z = 2500
    end
    @meters[index] = @meter
  end
  #--------------------------------------------------------------------------
  # * Update meter
  #     index : index
  #     actor : actor
  #     y_position : y-position in battlestatus window
  #--------------------------------------------------------------------------
  def refresh_meter_y(index, actor, y_position)
    case Meter_Pos_Style
    when 0
      @meters[index].y = y_position
    when 1
      @meters[index].y = y_position
    when 2
      @meters[index].y = index * 32 + y_position
    when 3
      @meters[index].y = actor.base_y - @skin.height / 5
    when 4
      @meters[index].y = actor.base_y - @skin.height / 5 - 64
    when 5
      @meters[index].y = base[1]
    end
  end
end
Up is down, left is right and sideways is straight ahead. - Cord "Circle of Iron", 1978 (written by Bruce Lee and James Coburn... really...)
[Image: QrnbKlx.jpg]
[Image: sGz1ErF.png] [Image: liM4ikn.png] [Image: fdzKgZA.png] [Image: sj0H81z.png]
[Image: QL7oRau.png] [Image: uSqjY09.png] [Image: GAA3qE9.png] [Image: 2Hmnx1G.png] [Image: BwtNdKw.png%5B]
Above are clickable links

Reply }


Messages In This Thread
RE: [RMXP]Game Over and Atoa Battle Status mishaps - by DerVVulfman - 08-06-2014, 08:30 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
   ACBS - Atoa Custom Battle System and TP System zlsl 2 3,859 10-20-2021, 05:09 AM
Last Post: zlsl
   [RMXP] Showing skill gained by leveling up on battle result FrQise 12 10,711 05-07-2021, 02:05 PM
Last Post: FrQise
   Adding face script on Cogwheel's RTAB Battle Status rekkatsu 15 13,353 08-25-2020, 03:09 AM
Last Post: DerVVulfman
   I want to add an Atoa Custom Battle System command cut-in. zlsl 11 12,205 11-11-2019, 08:55 PM
Last Post: DerVVulfman
   Question about ACBS (Atoa Custom Battle System) aeliath 10 11,158 08-08-2019, 02:50 PM
Last Post: aeliath
   YAMI Battle symphony + Holder add on (Loop casting anim) Starmage 0 3,952 03-01-2018, 09:03 AM
Last Post: Starmage
   (RMVXace) Battle error with Tankentai's battle system, help. x( Starmage 0 3,531 02-14-2018, 04:25 PM
Last Post: Starmage
   Atoa Individual Battle Commands Geminil 3 6,330 08-02-2017, 03:17 AM
Last Post: DerVVulfman
   Display State Ranks in Status Screen Melana 3 6,826 04-02-2017, 12:46 AM
Last Post: marketing small business ideas
  Expiration States with Atoa acbs: error Noctis 5 8,272 02-18-2017, 01:10 AM
Last Post: DerVVulfman



Users browsing this thread: