61 lines
No EOL
2.7 KiB
Ruby
61 lines
No EOL
2.7 KiB
Ruby
#==============================================================================
|
||
# ■ VXAce-RGSS3-14 立ち絵ステータス [Ver1.0.0] by Claimh
|
||
#------------------------------------------------------------------------------
|
||
# ステータス画面に立ち絵を追加します
|
||
#------------------------------------------------------------------------------
|
||
# 立ち絵は Graphics/Pictures 以下の
|
||
# Actor{アクターID} を表示します(アクター1 : Actor1.png)
|
||
#------------------------------------------------------------------------------
|
||
# ●立ち絵の変更
|
||
# $game_actors[アクターID].picture = "ファイル名"
|
||
#==============================================================================
|
||
|
||
|
||
|
||
#==============================================================================
|
||
# ■ Window_Base
|
||
#==============================================================================
|
||
class Window_Base < Window
|
||
#--------------------------------------------------------------------------
|
||
# ● アクターの立ち絵描画
|
||
#--------------------------------------------------------------------------
|
||
def draw_actor_picture(actor, x, y, enabled = true)
|
||
bitmap = Cache.picture(actor.picture)
|
||
rect = Rect.new(0, 0, bitmap.width, bitmap.height)
|
||
contents.blt(x + 130, y - 290, bitmap, rect, enabled ? 255 : translucent_alpha)
|
||
bitmap.dispose
|
||
end
|
||
end
|
||
|
||
#==============================================================================
|
||
# ■ Game_Actor
|
||
#==============================================================================
|
||
class Game_Actor < Game_Battler
|
||
#--------------------------------------------------------------------------
|
||
# ● 公開インスタンス変数
|
||
#--------------------------------------------------------------------------
|
||
attr_accessor :picture # 立ち絵(277x288)
|
||
#--------------------------------------------------------------------------
|
||
# ● セットアップ
|
||
#--------------------------------------------------------------------------
|
||
alias setup_picture setup
|
||
def setup(actor_id)
|
||
setup_picture(actor_id)
|
||
@picture = "Actor#{actor_id}"
|
||
|
||
end
|
||
end
|
||
|
||
#==============================================================================
|
||
# ■ Window_Status
|
||
#==============================================================================
|
||
class Window_Status < Window_Selectable
|
||
#--------------------------------------------------------------------------
|
||
# ● ブロック 1 の描画
|
||
#--------------------------------------------------------------------------
|
||
alias draw_block1_picture draw_block1
|
||
def draw_block1(y)
|
||
draw_actor_picture(@actor, 0, contents_height-288, false)
|
||
draw_block1_picture(y)
|
||
end
|
||
end |