| 
 
| 赞 | 0 |  
| VIP | 0 |  
| 好人卡 | 0 |  
| 积分 | 1 |  
| 经验 | 1220 |  
| 最后登录 | 2018-9-22 |  
| 在线时间 | 2 小时 |  
 Lv1.梦旅人 
	梦石0 星屑55 在线时间2 小时注册时间2006-11-5帖子68 | 
| 
从主战找到了一个脚本,我把它演变成菜单里的游戏时间了。
x
加入我们,或者,欢迎回来。您需要 登录 才可以下载或查看,没有帐号?注册会员  下面切入正题:
 先吧Window_PlayTime的脚本覆盖
 
 复制代码
#==============================================================================
# 本脚本来自www.66RPG.com,使用和转载请保留此信息
#==============================================================================
#==============================================================================
# ■ Window_PlayTime
#------------------------------------------------------------------------------
#  菜单画面显示游戏时间的窗口。
#==============================================================================
class Window_PlayTime < Window_Base
  #--------------------------------------------------------------------------
  # ● 初始化对像
  #--------------------------------------------------------------------------
  def initialize
    super(0, 0, 160, 128 )
    self.contents = Bitmap.new(width - 32, height - 32)
    refresh
  end
  #--------------------------------------------------------------------------
  # ● 刷新
  #--------------------------------------------------------------------------
  def refresh
    self.contents.clear
    self.contents.font.color = system_color
    self.contents.draw_text(4, -4, 120, 32, "当前时间")
    @total_sec = Graphics.frame_count / Graphics.frame_rate
    t = Time.now
$game_variables[204] = t.wday  # 星期
$game_variables[208] = ["周日", "周一", "周二", "周三", "周四", "周五", "周六"][$game_variables[204]]
text = sprintf("%02d:%02d:%02d", t.hour, t.min, t.sec) 
text2 = sprintf("%02d.%02d.%02d", t.year, t.month, t.day) 
text3 = sprintf($game_variables[208]) 
self.contents.font.color = normal_color
    self.contents.draw_text(4, 24, 110, 32, text2, 2)
    self.contents.draw_text(-25, 48, 110, 32, text3, 2)
    self.contents.draw_text(-3, 72, 110, 32, text, 2)
    end
  #--------------------------------------------------------------------------
  # ● 刷新画面
  #--------------------------------------------------------------------------
  def update
    super
    if Graphics.frame_count / Graphics.frame_rate != @total_sec
      refresh
    end
  end
end
#==============================================================================
# 本脚本来自www.66RPG.com,使用和转载请保留此信息
#==============================================================================
好了,然后进入Window_Steps
 在第12行
 super(0, 0, 160, 96)
 改为
 super(0, 0, 160, 64)
 
 在第24行
 self.contents.draw_text(4, 32, 120, 32, $game_party.steps.to_s, 2)
 改为
 self.contents.draw_text(4, 0, 120, 32, $game_party.steps.to_s, 2)
 
 最后
 在Scene_Menu里面
 将48行的
 @steps_window.y = 320
 改为
 @steps_window.y = 352
 大功告成!
 
 
 ![]() | 
 |