本帖最后由 plmo43 于 2017-10-2 02:00 编辑  
 
update里没有刷新你自己新建的这个窗口,使用本地变量命名窗口然后在适当的地方update它就好了。脑抽造成误导,涂一下,十分抱歉。 
 
不过如果这个窗口在游戏里经常显示的话,推荐你在Scene_Map一开始创建Window_shortcut,然后使用visible方法隐藏或显示并在适当的地方update它。 
def start     super     SceneManager.clear     $game_player.straighten     $game_map.refresh     $game_message.visible = false     create_spriteset     create_all_windows     @menu_calling = false       @window_shortcut = Window_shortcut.new     @window_shortcut.activate     if $shortcut_window == 1       @window_shortcut.visible = true     else       @window_shortcut.visible = false     end     end     def shortcut_window     #@window_shortcut.update if @window_shortcut.visible == true     if Kboard.keyboard(0x09)       if @window_shortcut.visible == false         @window_shortcut.visible = true         $shortcut_window = 1       else         @window_shortcut.visible = false         $shortcut_window = 0       end     end   end 
 
 def start  
    super  
    SceneManager.clear  
    $game_player.straighten  
    $game_map.refresh  
    $game_message.visible = false  
    create_spriteset  
    create_all_windows  
    @menu_calling = false  
   
    @window_shortcut = Window_shortcut.new  
    @window_shortcut.activate  
    if $shortcut_window == 1  
      @window_shortcut.visible = true  
    else  
      @window_shortcut.visible = false  
    end  
   
  end  
   
  def shortcut_window  
    #@window_shortcut.update if @window_shortcut.visible == true  
    if Kboard.keyboard(0x09)  
      if @window_shortcut.visible == false  
        @window_shortcut.visible = true  
        $shortcut_window = 1  
      else  
        @window_shortcut.visible = false  
        $shortcut_window = 0  
      end  
    end  
  end  
 
  
 
 
 |