Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Custom image in the status screen.

My question is more than likely an easy one that has already been answered in another thread, but for the life of me I can't seem to find it anywhere so I'm asking here.

I'm using the default menu style (with just a few very minor changes). What I'd like is a way to change the sprite image to an image in the Graphics/Pictures directory. I'm using Minkoff's Animated Battlers script, so I don't want an image of the battlers.

I'm kinda ok with modifying scripts as necessary, given that I'm told what to modify and where. I think the solution is somewhere in Window_Status, but I just don't know the command to stick in there to call what I need. If anybody can point me in the right direction, I would really appreciate it.
 
Use something like this:
[ruby]class Window_Base
  #--------------------------------------------------------------------------
  # * Draw Graphic
  #     actor : actor
  #     x     : draw spot x-coordinate
  #     y     : draw spot y-coordinate
  #--------------------------------------------------------------------------
  def draw_actor_graphic(actor, x, y)
    # Array, stores menu picture for each actor
    actor_pic = [nil, "actor1.png", "actor2.png", "ac3.png", "ac4.png"]
    pic_name = actor_pic[actor.id]
    bitmap = RPG::Cache.picture(pic_name)
    w = bitmap.width
    h = bitmap.height
    src_rect = Rect.new(0, 0, w, h)
    self.contents.blt(x - 24 / 2, y - 76, bitmap, src_rect)
  end
end
[/ruby]
You have to tell the game which picture to use for each actor. You can use the code as it is, just edit the array actor_pic with the correct names. The game will search the pctures in Graphics/pictures.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top