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.

face in message window?

Status
Not open for further replies.
simple as that. I can boot my text over myself, and enlarge the window hold a 64 x 64 picture.

the face file path will be Graphics/Characters/Faces.
when calling the file, call actor.name_portrait.png

i just need these faces inserted into my messages. at the top left corner of my message and inside its own 64 x 64 window borders
 

Mac

Member

First add this above def draw_actor_name:-

Code:
# Face Graphic #
  def draw_actor_face(actor, x, y)
  bitmap = RPG::Cache.picture("MenuFace/#{actor.id}")
   cw = bitmap.width 
   ch = bitmap.height 
   src_rect = Rect.new(0, 0, cw, ch)
   self.contents.blt(x - cw/5, y - ch, bitmap, src_rect)
 end

Then place this where you want it to be drawn. (remeber change the co-ordinates to fit what you are doing)

Code:
      draw_actor_face(actor, x - 60 ,y + 160)
 
Status
Not open for further replies.

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