Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 CTB - A Final Fantasy X-like Battle System, Version 3.2
Ok, it was a division by zero. It is caused by your first actor that does not have SPs. Use this modified version of the refresh method for the Bar class:

Code:
#--------------------------------------------------------------------------
  # ? Refresh
  #--------------------------------------------------------------------------
  def refresh(value,max)
    @bar_bg=RPG::Cache.picture(@bar_background)
    @bar_fg=RPG::Cache.picture(@bar)
    @src_bg = Rect.new(0, 0, @bar_bg.width, @bar_bg.height)
    @src_fg = Rect.new(0, 0, @bar_fg.width, @bar_fg.height)
    value=[value,max].min
    if value==max and @highlight_complete
      @bar_fg=RPG::Cache.picture(@bar_complete)
    end
    x_ratio=@width/200.0
    y_ratio=@height/32.0
    bg_dest = Rect.new(@x, @y, @width, @height)
    @bitmap.stretch_blt(bg_dest, @bar_bg, @src_bg, @back_opacity)
    return if max==0
    dest = Rect.new(@x+(4*x_ratio).ceil, @y+(4*y_ratio).ceil, ((@width-8*x_ratio)*value/max).ceil, (@height-8*y_ratio))
    @bitmap.stretch_blt(dest, @bar_fg, @src_fg, @opacity)
  end

EDIT: I'd suggest you to remove the link above, and to use PMs to send links.
Reply }


Messages In This Thread
CTB - A Final Fantasy X-like Battle System, version 3.1 (NEW Jul 4 2010) - by Charlie Fleed - 11-25-2009, 02:11 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
   Battle Item Count kyonides 4 856 02-04-2024, 05:49 AM
Last Post: kyonides
   Super Simple Vehicle System - Enhanced DerVVulfman 65 83,008 06-02-2023, 06:16 PM
Last Post: Sujabes467
   Dalissa's Battle Cry DerVVulfman 2 6,638 05-09-2023, 03:07 AM
Last Post: DerVVulfman
   Zenith Tactical Battle System Plus (ZTBS+) DerVVulfman 0 2,025 05-10-2022, 10:42 PM
Last Post: DerVVulfman
   Actor Battle Items DerVVulfman 4 4,940 11-08-2020, 12:36 PM
Last Post: Melana
   Battle Report Raziel 1 6,233 05-29-2020, 02:27 AM
Last Post: Whisper
   Commercial System Package DerVVulfman 11 12,063 01-04-2020, 12:37 AM
Last Post: Pelip
   KItemDesc XP & VX Zilsel Version kyonides 4 6,535 12-01-2019, 06:11 AM
Last Post: kyonides
   ZLSL's Battle Portraits DerVVulfman 4 6,478 11-12-2019, 04:10 AM
Last Post: DerVVulfman
   ACBS - Atoa Custom Battle System 3.2 Victor Sant 150 224,548 03-02-2019, 04:47 AM
Last Post: dragonprincess44



Users browsing this thread: