Project1
标题: 如何将存档行走图改为脸图 [打印本页]
作者: kkwo 时间: 2014-1-14 18:02
标题: 如何将存档行走图改为脸图
我有用站内找到的截图存档脚本
所以不能直接用脸图存档脚本...
看了很久终于找到应该改的地方
#==============================================================================
# ■ Window_SaveFile
#------------------------------------------------------------------------------
# セーブ画面およびロード画面で表示する、セーブファイルのウィンドウです。
#==============================================================================
class Window_SaveFile < Window_Base
#--------------------------------------------------------------------------
# ● オブジェクト初期化
# index : セーブファイルのインデックス
#--------------------------------------------------------------------------
def initialize(index)
super(160, 0, Graphics.width-160, Graphics.height-fitting_height(1))
@file_index = index
@selected = true
refresh
end
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
def refresh
contents.clear
change_color(normal_color)
w = (self.width-PS0::Window_SaveFile_Plus::Thumbnail_Width-16)/2
h = (self.height-PS0::Window_SaveFile_Plus::Thumbnail_Height-16)/2
width = w + PS0::Window_SaveFile_Plus::Thumbnail_ox
height = h + PS0::Window_SaveFile_Plus::Thumbnail_oy
draw_shadow(width+5, height+5)
draw_text((self.width-32-PS0::Window_SaveFile_Plus::NO_DATA.length*16)/2,
self.height/2-32, PS0::Window_SaveFile_Plus::NO_DATA.length*32,
line_height, PS0::Window_SaveFile_Plus::NO_DATA)
draw_party_characters(32, Graphics.height-fitting_height(1)-32)
draw_playtime(-10, contents.height - line_height-10, contents.width - 4, 2)
draw_snapshoot(width, height)
end
#--------------------------------------------------------------------------
# ● 角色描繪
#--------------------------------------------------------------------------
def draw_party_characters(x, y)
header = DataManager.load_header(@file_index)
return unless header
header[:characters].each_with_index do |data, i|
draw_character(data[0], data[1], x + i * 48, y)
end
end
#==============================================================================
# ■ Window_SaveFile
#------------------------------------------------------------------------------
# セーブ画面およびロード画面で表示する、セーブファイルのウィンドウです。
#==============================================================================
class Window_SaveFile < Window_Base
#--------------------------------------------------------------------------
# ● オブジェクト初期化
# index : セーブファイルのインデックス
#--------------------------------------------------------------------------
def initialize(index)
super(160, 0, Graphics.width-160, Graphics.height-fitting_height(1))
@file_index = index
@selected = true
refresh
end
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
def refresh
contents.clear
change_color(normal_color)
w = (self.width-PS0::Window_SaveFile_Plus::Thumbnail_Width-16)/2
h = (self.height-PS0::Window_SaveFile_Plus::Thumbnail_Height-16)/2
width = w + PS0::Window_SaveFile_Plus::Thumbnail_ox
height = h + PS0::Window_SaveFile_Plus::Thumbnail_oy
draw_shadow(width+5, height+5)
draw_text((self.width-32-PS0::Window_SaveFile_Plus::NO_DATA.length*16)/2,
self.height/2-32, PS0::Window_SaveFile_Plus::NO_DATA.length*32,
line_height, PS0::Window_SaveFile_Plus::NO_DATA)
draw_party_characters(32, Graphics.height-fitting_height(1)-32)
draw_playtime(-10, contents.height - line_height-10, contents.width - 4, 2)
draw_snapshoot(width, height)
end
#--------------------------------------------------------------------------
# ● 角色描繪
#--------------------------------------------------------------------------
def draw_party_characters(x, y)
header = DataManager.load_header(@file_index)
return unless header
header[:characters].each_with_index do |data, i|
draw_character(data[0], data[1], x + i * 48, y)
end
end
如上...
不过我改了以后存读档时原本行走图的位置就看不到任何图了...
#==============================================================================
# ■ Window_SaveFile
#------------------------------------------------------------------------------
# セーブ画面およびロード画面で表示する、セーブファイルのウィンドウです。
#==============================================================================
class Window_SaveFile < Window_Base
#--------------------------------------------------------------------------
# ● オブジェクト初期化
# index : セーブファイルのインデックス
#--------------------------------------------------------------------------
def initialize(index)
super(160, 0, Graphics.width-160, Graphics.height-fitting_height(1))
@file_index = index
@selected = true
refresh
end
#--------------------------------------------------------------------------
# ● リフレッシュ
#--------------------------------------------------------------------------
def refresh
contents.clear
change_color(normal_color)
w = (self.width-PS0::Window_SaveFile_Plus::Thumbnail_Width-16)/2
h = (self.height-PS0::Window_SaveFile_Plus::Thumbnail_Height-16)/2
width = w + PS0::Window_SaveFile_Plus::Thumbnail_ox
height = h + PS0::Window_SaveFile_Plus::Thumbnail_oy
draw_shadow(width+5, height+5)
draw_text((self.width-32-PS0::Window_SaveFile_Plus::NO_DATA.length*16)/2,
self.height/2-32, PS0::Window_SaveFile_Plus::NO_DATA.length*32,
line_height, PS0::Window_SaveFile_Plus::NO_DATA)
draw_party_characters(32, Graphics.height-fitting_height(1)-32)
draw_playtime(-10, contents.height - line_height-10, contents.width - 4, 2)
draw_snapshoot(width, height)
end
#--------------------------------------------------------------------------
# ● パーティキャラの描画
#--------------------------------------------------------------------------
def draw_party_characters(x, y)
header = DataManager.load_header(@file_index)
return unless header && header[:faces]
header[:faces].each_with_index do |data, i|
draw_face(data[0], data[1], x + i * 96, y)
end
end
#==============================================================================
# ■ Window_SaveFile
#------------------------------------------------------------------------------
# セーブ画面およびロード画面で表示する、セーブファイルのウィンドウです。
#==============================================================================
class Window_SaveFile < Window_Base
#--------------------------------------------------------------------------
# ● オブジェクト初期化
# index : セーブファイルのインデックス
#--------------------------------------------------------------------------
def initialize(index)
super(160, 0, Graphics.width-160, Graphics.height-fitting_height(1))
@file_index = index
@selected = true
refresh
end
#--------------------------------------------------------------------------
# ● リフレッシュ
#--------------------------------------------------------------------------
def refresh
contents.clear
change_color(normal_color)
w = (self.width-PS0::Window_SaveFile_Plus::Thumbnail_Width-16)/2
h = (self.height-PS0::Window_SaveFile_Plus::Thumbnail_Height-16)/2
width = w + PS0::Window_SaveFile_Plus::Thumbnail_ox
height = h + PS0::Window_SaveFile_Plus::Thumbnail_oy
draw_shadow(width+5, height+5)
draw_text((self.width-32-PS0::Window_SaveFile_Plus::NO_DATA.length*16)/2,
self.height/2-32, PS0::Window_SaveFile_Plus::NO_DATA.length*32,
line_height, PS0::Window_SaveFile_Plus::NO_DATA)
draw_party_characters(32, Graphics.height-fitting_height(1)-32)
draw_playtime(-10, contents.height - line_height-10, contents.width - 4, 2)
draw_snapshoot(width, height)
end
#--------------------------------------------------------------------------
# ● パーティキャラの描画
#--------------------------------------------------------------------------
def draw_party_characters(x, y)
header = DataManager.load_header(@file_index)
return unless header && header[:faces]
header[:faces].each_with_index do |data, i|
draw_face(data[0], data[1], x + i * 96, y)
end
end
改过的如上
因为存档时行走图的截图会出问题...(显示不完整)
可能是因为有用到八方多帧行走脚本的关係吧...
求教该如何改...
作者: rmav 时间: 2014-1-14 21:03
本帖最后由 rmav 于 2014-1-14 21:40 编辑
看了楼主的问题,发现俺的行走插件没做这方面的处理。
现已更新完毕1.032
读档界面,行走图会是完整的。如果档栏不够大,行走图会自动缩小,默认有对齐。
-----------
其他问题留给楼下^_^
欢迎光临 Project1 (https://rpg.blue/) |
Powered by Discuz! X3.1 |