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.

Blt question

k. Just a quick question. should be fairly simple.
But this is what i got. I am making a new Load screen using No Window Classes at all. Just easier for me. Completly functional and everything. I can print the name of a character i know how to do that:

@Fileslot.bitmap.draw_text(.......)

now.. I wanna put the characters image in this as well. but this doesnt work
@Fileslot.bitmap.blt(.....) doesnt work.. Is there any other way I can do this?
 
The arguments for blt are like this:
sprite.bitmap.blt(dest_x, dest_y, src_bitmap, src_rect, [opacity = 255])
The opacity defaults to 255 (full).

To show the picture of the battler, you would need to get the bitmap with
src_bitmap = RPG::Cache.battler($game_party.actors[n].battler_name, $game_party.actors[n].battler_hue)

The src_rect can generally be found as
src_bitmap.rect
However, if you don't want the whole battler bitmap, you would make your own rect with
src_rect = Rect.new(x, y, width, height)
 

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