Jump to content
Sign in to follow this  
LadyAnna

Change Face set size?

Recommended Posts

find this method within Window_Base: (begins on line 376.)

#--------------------------------------------------------------------------
# * Draw Face Graphic
#     enabled : Enabled flag. When false, draw semi-transparently.
#--------------------------------------------------------------------------
def draw_face(face_name, face_index, x, y, enabled = true)
  bitmap = Cache.face(face_name)
  rect = Rect.new(face_index % 4 * 96, face_index / 4 * 96, 96, 96)
  contents.blt(x, y, bitmap, rect, enabled ? 255 : translucent_alpha)
  bitmap.dispose
end

within rect's definition, replace each 96 with your custom value.

Edited by dbchest

Share this post


Link to post
Share on other sites

remember that the image displays at 0, 0 of the rect. if you set that value to something larger than 96, your facesets are going to have the bottoms cut off. if you make that value smaller, the facesets won't be centered in the message window. if you change that value, you will also have to change the x and y values accordingly in order to display the image appropriately.

Share this post


Link to post
Share on other sites

you set them at the time the method is called, sweetie.

draw_face(face_name, face_index, x, y, enabled)

 

here is a little background information on some practical use in the default scripts:

within the Window_MenuStatus class, under the "draw_item" definition, you'll find the "draw_actor_face" method call. "draw_actor_face" is defined within Window_Base, and is used to draw the face of an actor as the engine passes through an index of available party members. if you were to analyze "draw_actor_face" within the Window_Base, you would see that it calls the method i posted above, which is the main processing for drawing the image onto the screen.

 

when you see parenthesis, information is passed for evaluation (usually specified at a later time when the method is called). knowing this, we can make a change to the default draw_actor_face so that it will draw the faces in a different spot. take a look at "draw_actor_face" within Window_Base:

#--------------------------------------------------------------------------
# * Draw Actor Face Graphic
#--------------------------------------------------------------------------
def draw_actor_face(actor, x, y, enabled = true)
  draw_face(actor.face_name, actor.face_index, x, y, enabled)
end

here we are shown information being passed for evaluation at a later time (actor, x, y, enabled). if you look closely at the definition itself, you will see the original method i mentioned at the top of this page. each piece of information is specified here(face_name, face_index, x, y, and enabled). this is how arguments work.

 

so by changing the x, and y, values of draw_actor_face, you will change the display position of the facesets in the menu. the same will go for changing the position displayed within the message box, however i'm sure that working within the message window will require a deeper level of analyzing, and possibly some more complicated too acount for the change.

Edited by dbchest

Share this post


Link to post
Share on other sites
Guest scappy345

Hi, sorry for the silly question but what version is this for? I can’t find Window_Base anywhere for rpgmaker 2003. 

Share this post


Link to post
Share on other sites

Your content will need to be approved by a moderator

Guest
You are commenting as a guest. If you have an account, please sign in.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×