#===================================================
#
# Yanfly Engine RD - Display Party Data
# Last Date Updated: 2009.02.23
# Level: Easy
#
# This pretty much changes the party information window in battles to show the
# party member names horizontally than vertically. When structured as such,
# you'll be able to see the party members' faces and/or sprites. With the new
# arrangement, the player can also see up to four status effects on each actor
# as opposed to the original two. A big difference.
#
#===============================================================
# Instructions
#===============================================================
#
# Just put this script under ¥ Materials and that's it. If you'd like to change
# other settings such as showing the face graphic or changing its opacity, just
# scroll down a bit and make adjustments as necessary.
#
#===============================================================
#
# Compatibility
# - Alias: Window_BattleStatus, initialize
# - Overwrites: Window_BattleStatus, draw_item
#
#===============================================================
$imported = {} if $imported == nil
$imported["DisplayPartyData"] = true
module YE
module BATTLE
module DISPLAY
# This changes what will and will not be shown. If you choose to shown
# the actor's face graphic, you can choose its opacity. 255 means it's
# fully visible while 0 means it's completely transparent. For the
# number of states shown, do not exceed 4 unless you want the states to
# overlap into the next actor's data window.
SHOW_ALLY_FACE = true
ALLY_FACE_OPACITY = 100
SHOW_ALLY_SPRITE = true
MAX_STATES_SHOWN = 4
end # end module DISPLAY
end # end module BATTLE
end # end module YE
#===============================================================
# Don't touch anything past here or else your computer will explode and you will
# be a very sad person.
#===============================================================
#===============================================================
# Window_BattleStatus
#===============================================================
class Window_BattleStatus
#--------------------------------------------------------------------------
# Alias Object Initialization
#--------------------------------------------------------------------------
alias displaypartydata_initialize initialize
def initialize
displaypartydata_initialize
@column_max = $game_party.members.size
@spacing = 0
end
#--------------------------------------------------------------------------
# Draw Item
#--------------------------------------------------------------------------
def draw_item(index)
rect = Rect.new(index * 96, 96, 96, 96)
rect.width = 96
rect.height = 96
actor = $game_party.members[index]
fo = YE::BATTLE::DISPLAY::ALLY_FACE_OPACITY
draw_party_face(actor, 96 * index + 2, 2, fo, 92) if YE::BATTLE::DISPLAY::SHOW_ALLY_FACE
draw_actor_graphic(actor, 96 * index + 72, 48) if YE::BATTLE::DISPLAY::SHOW_ALLY_SPRITE
draw_actor_state(actor, 96 * index, WLH * 1, 24 * YE::BATTLE::DISPLAY::MAX_STATES_SHOWN)
draw_actor_name(actor, 96 * index + 4, 0)
draw_actor_hp(actor, 96 * index + 2, WLH * 2, 92)
draw_actor_mp(actor, 96 * index + 2, WLH * 3, 92)
end
#--------------------------------------------------------------------------
# Update Cursor
#--------------------------------------------------------------------------
def update_cursor
if @index
self.cursor_rect.empty
else
self.cursor_rect.set(@index * 96, 0, 96, 96)
end
end
#--------------------------------------------------------------------------
# Draw Party Face
#--------------------------------------------------------------------------
def draw_party_face(actor, x, y, opacity = 255, size = 96)
face_name = actor.face_name
face_index = actor.face_index
bitmap = Cache.face(face_name)
rect = Rect.new(0, 0, 0, 0)
rect.x = face_index % 4 * 96 + (96 - size) / 2
rect.y = face_index / 4 * 96 + (96 - size) / 2
rect.width = size
rect.height = size
self.contents.blt(x, y, bitmap, rect, opacity)
bitmap.dispose
end
end # end Window_BattleStatus
#===============================================================
#
# END OF FILE
#
#===============================================================