The RPG Maker Resource Kit

Other Game Creation => Program Troubleshooting => Topic started by: Iari on October 04, 2009, 08:06:19 PM

Title: Moving HP/SP Text? [RESOLVED]
Post by: Iari on October 04, 2009, 08:06:19 PM
To see what it is that's bothering me, look at this screenshot (http://s867.photobucket.com/albums/ab238/Zeralith/?action=view&current=HPSPBars.jpg).
I'm using the Tankentai XP Battle system, which adds small bars underneath the HP/SP text.  As you can see, the HP bar and the SP text overlap slightly.  How do I move the SP text down further?
Title: Re: Moving HP/SP Text?
Post by: Iari on October 04, 2009, 08:15:57 PM
I think you have misunderstood me.  I want to move the text saying "SP   747/747" down.  I know how to move the SP Bar the Tankentai system added already.
Title: Re: Moving HP/SP Text?
Post by: modern algebra on October 04, 2009, 08:20:23 PM
Well, he's asking to see the script, because we need to know how it is drawn in order to tell you how to move it.

I'm guessing there's some draw_sp method that needs to be altered.
Title: Re: Moving HP/SP Text?
Post by: Iari on October 04, 2009, 08:27:38 PM
I don't know which script it is!  It's part of the basic game!
Title: Re: Moving HP/SP Text?
Post by: modern algebra on October 04, 2009, 08:34:19 PM
Oh, I figured the Tankentai was altering the default. If it isn't then the following code ought to work (put it below all of your other scripts except for Main:


class Window_Base
  #--------------------------------------------------------------------------
  # * Draw SP
  #     actor : actor
  #     x     : draw spot x-coordinate
  #     y     : draw spot y-coordinate
  #--------------------------------------------------------------------------
  alias ma_iari_drawsp_lower_7jb3 draw_actor_sp
  def draw_actor_sp(actor, x, y, *args)
    y += 4
    ma_iari_drawsp_lower_7jb3 (actor, x, y, *args)
  end
end


Change this line:

    y += 4


to however much extra you want it to go down to. 4 means it will move down 4 pixels.
Title: Re: Moving HP/SP Text?
Post by: Iari on October 04, 2009, 08:45:36 PM
Thanks, Modern Algebra!  That worked!