The problem I have is simple: on the battle menu, my actor's name is too long and gets covered by the states icons. How can I change the position of the states, moving them a few pixels to the right?
Edit position of states icons on battle
RPG Maker VXAce SupportWhat scripts are you using to draw the icons?
Is it the default?
Is it the default?
Default.
Ruby:
module R2_Status_Icon_Shift
X_SHIFT = 10
end
class Window_BattleStatus < Window_Selectable
#--------------------------------------------------------------------------
# * Draw Basic Area
#--------------------------------------------------------------------------
def draw_basic_area(rect, actor)
draw_actor_name(actor, rect.x + 0, rect.y, 100)
x_offset = R2_Status_Icon_Shift::X_SHIFT
draw_actor_icons(actor, rect.x + 104 + x_offset, rect.y, rect.width - 104)
end
end
and if you push the icons too far then it will cover the hp gauge
Or you could reverse them, put the icons first and the name next.
Ruby:
module R2_Status_Icon_Shift
X_SHIFT = 48
end
class Window_BattleStatus < Window_Selectable
#--------------------------------------------------------------------------
# * Draw Basic Area
#--------------------------------------------------------------------------
def draw_basic_area(rect, actor)
x_offset = R2_Status_Icon_Shift::X_SHIFT
draw_actor_name(actor, rect.x + x_offset, rect.y, 100)
draw_actor_icons(actor, 0, rect.y, rect.width - 104)
end
#--------------------------------------------------------------------------
# * Get Standard Padding Size
#--------------------------------------------------------------------------
def standard_padding
return 8
end
end
The default squeezing text method looks horrible in my opinion, so I installed a script to stop that from happening (Mithran's Text Cache). I understand that now some texts will be cut off, but they are just 2 so far and have been fixed easily.
Thanks for the little fix, I won't push the icons far, it looks perfect as it is (with X_SHIFT being 10).
Thanks for the little fix, I won't push the icons far, it looks perfect as it is (with X_SHIFT being 10).
Original thread: https://forums.rpgmakerweb.com/threads/edit-position-of-states-icons-on-battle.163746/