| 
 
| 赞 | 1 |  
| VIP | 0 |  
| 好人卡 | 0 |  
| 积分 | 6 |  
| 经验 | 71075 |  
| 最后登录 | 2017-9-1 |  
| 在线时间 | 1752 小时 |  
 Lv2.观梦者 
	梦石0 星屑575 在线时间1752 小时注册时间2008-11-7帖子1431 | 
| 
x
加入我们,或者,欢迎回来。您需要 登录 才可以下载或查看,没有帐号?注册会员  复制代码module Freya
  Shangd = false #false  true
end  
$variables_id = 14
class Window_Shangd < Window_Base
  #--------------------------------------------------------------------------
  # ● 对象初始化
  #--------------------------------------------------------------------------
  def initialize
    super(285,400,110,50)  
    self.opacity = 0
    
    unless $game_system.s_dian   
      self.contents_opacity = 0
    end  
    
    @variable = 0  
    refresh  
  end  
  #--------------------------------------------------------------------------
  # ● 更新画面
  #--------------------------------------------------------------------------
  def update
    super
    if $game_system.s_dian
      self.contents_opacity = 255
    else
      self.contents_opacity = 0
    end
    refresh
  end   
  #--------------------------------------------------------------------------
  # ● 设置地图上显示的变量    刷新  # 在图表与变量都有变化的情况下
  #--------------------------------------------------------------------------
  def refresh
    if != $game_variables[$variables_id]
      self.contents.clear
      change_color(text_color(4))  #水晶
      self.contents.draw_text(0,0,50,32,$game_variables[$variables_id].to_s,3)
      
    #else
      #change_color(text_color(2))  #水晶
      #self.contents.draw_text(0,0,50,32,$game_variables[$variables_id].to_s,3)
      
      @variable = $game_variables[$variables_id]
    end
  end
end
class Game_System
  #--------------------------------------------------------------------------
  # ● 定义实例变量
  #--------------------------------------------------------------------------
  attr_accessor :s_dian                       
  #--------------------------------------------------------------------------
  # ● 初始化对象
  #--------------------------------------------------------------------------
  alias vw_initialize initialize
  def initialize
    vw_initialize
    @s_dian = Freya::Shangd
  end
end  
#==============================================================================
# ■ Scene_Map
#------------------------------------------------------------------------------
#  地图画面
#==============================================================================
class Scene_Map
  #--------------------------------------------------------------------------
  # ● 开始处理
  #--------------------------------------------------------------------------
  alias new_start start
  def start
    new_start
    @Shangd_window = Window_Shangd.new 
  end
  #--------------------------------------------------------------------------
  # ● 刷新窗口
  #--------------------------------------------------------------------------
  alias new_update update
  def update
    new_update
    @Shangd_window.refresh
  end
  #--------------------------------------------------------------------------
  # ● 释放窗口
  #--------------------------------------------------------------------------
  alias new_terminate terminate
  def terminate
    new_terminate
    @Shangd_window.dispose
  end
end  
 | 
 |