Project1
标题:
如何把菜单的行走图,换成头象
[打印本页]
作者:
一杯清茶
时间:
2008-4-29 00:12
标题:
如何把菜单的行走图,换成头象
高手教我,如何把菜单里的行走图,换头象,最好是把状态栏里的也换成自已的图片
作者:
cZooCz
时间:
2008-4-29 01:39
去下个66RPG整合系统就可以了
这个即是大富翁的Window_MenuStatus脚本
#==============================================================================
# ■ Window_MenuStatus
#------------------------------------------------------------------------------
# 显示菜单画面和同伴状态的窗口。
#==============================================================================
class Window_MenuStatus < Window_Selectable
#--------------------------------------------------------------------------
# ● 初始化目标
#--------------------------------------------------------------------------
def initialize
super(0, 0, 480, 480)
self.contents = Bitmap.new(width - 32, height - 32)
refresh
self.active = false
self.index = -1
end
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
def refresh
self.contents.clear
@item_max = $game_party.actors.size
for i in 0...$game_party.actors.size
x = 108
y = i * 116
actor = $game_party.actors[i]
testname = actor.battler_name+"_f.png"
if $加密 == true
bitmap=Bitmap.new("Graphics/battlers/#{testname}")
src_rect = Rect.new(0, 0, 100, 100) #——可自己调整大小
self.contents.blt(0, y, bitmap, src_rect)
draw_actor_name(actor, x, y)
draw_actor_class(actor, x + 200, y)
draw_actor_level(actor, x, y + 32)
draw_actor_state(actor, x + 90, y + 32)
draw_actor_exp(actor, x, y + 64,180)
draw_actor_hp(actor, x + 200, y + 32)
draw_actor_sp(actor, x + 200, y + 64)
else
if FileTest.exist?("Graphics/battlers/#{testname}")
bitmap=Bitmap.new("Graphics/battlers/#{testname}")
src_rect = Rect.new(0, 0, 100, 100) #——可自己调整大小
self.contents.blt(0, y, bitmap, src_rect)
else
draw_actor_graphic(actor, x - 60, y + 80)
end
draw_actor_name(actor, x, y)
draw_actor_class(actor, x + 200, y)
draw_actor_level(actor, x, y + 32)
draw_actor_state(actor, x + 90, y + 32)
draw_actor_exp(actor, x, y + 64,180)
draw_actor_hp(actor, x + 200, y + 32)
draw_actor_sp(actor, x + 200, y + 64)
end
end
end
#--------------------------------------------------------------------------
# ● 刷新光标矩形
#--------------------------------------------------------------------------
def update_cursor_rect
if @index < 0
self.cursor_rect.empty
else
self.cursor_rect.set(0, @index * 116, self.width - 32, 96)
end
end
end
复制代码
图片存放在Graphics/battlers文件夹···文件名是战斗图名字加上 _f.png
作者:
朔月乌鸦
时间:
2008-4-29 22:59
提示:
作者被禁止或删除 内容自动屏蔽
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1