设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索
查看: 2007|回复: 2
打印 上一主题 下一主题

[转载] 【VA】纠错界面功能扩展 デバッグ画面を機能拡張します

[复制链接]

Lv2.观梦者

bluer
公主殿下

梦石
0
星屑
283
在线时间
533 小时
注册时间
2013-10-19
帖子
2067
跳转到指定楼层
1
发表于 2014-8-22 14:20:41 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有帐号?注册会员

x
嘛。。也大概汉化了一下前面的介绍和设定部分。

部分截图:







脚本部分:
RGSS3 代码复制
  1. #==============================================================================
  2. # ■ VXAce-RGSS-44 デバッグ++ [Ver.1.1.0]             by Claimh
  3. #------------------------------------------------------------------------------
  4. =begin
  5. デバッグ画面の機能拡張をします。
  6.  
  7. [追加功能]
  8. ・自助开关操作(目前是地图上所有活动)【其实窝没太看明白什么意思
  9. ・物品/武器/防具所持数量变更
  10. ・队伍变更
  11. ・演员編集【这是啥。。。原文:アクター編集
  12.   - 地图編集
  13.   - 技能習得・忘却
  14. ・地图移動(可以移動地点指定)
  15. ・音楽再生(BGM/BGS/ME/SE)
  16. ・その他情報操作
  17.   - 所持金、保存回数、戦闘回数の変更
  18.   - 保存禁止、菜单禁止、遇敌禁止、並び替え禁止の操作【这个没太明白大概是禁止商店?
  19.   - 天气操作
  20.   - 分辨率変更
  21.  
  22. [他スクリプトとの連動機能]
  23. ・熟練度系统
  24.   - 熟練度水平変更、得意属性・不得意属性の操作
  25. ・用語辞典
  26.   - 全初期化、表示設定変更
  27. ・世界地图
  28.   - 全初期化、表示設定変更
  29. ・任务系统
  30.   - 全初期化、任务状態変更、等级変更
  31. ・精霊系统
  32.   - 精霊加入状態変更、精霊編集
  33. =end
  34. #==============================================================================
  35.  
  36. module DebugPP
  37.   # 項目有効/無効
  38.   SPEC = {
  39.     "开关"     => true,
  40.     "变量"         => true,
  41.     "自动SW"     => true,
  42.     "项目"     => true,             #这是啥
  43.     "武器"         => true,
  44.     "防具"         => true,
  45.     "伙伴"   => true,    #应该没错
  46.     "状态"   => true,
  47.     "技能"       => true,
  48.     "地图移動"      => true,
  49.     "音乐" => true,
  50.     "体系"     => true,     #没见过这玩意啥意思“システム”
  51.     "熟練度"       => true,  # 「熟練度システム」未導入時は無効化される
  52.     "用語辞典"     => true,  # 「用語辞典」未導入時は無効化される
  53.     "世界地图"     => true,  # 「ワールドマップ」未導入時は無効化される
  54.     "任务"     => true,  # 「クエストシステム」未導入時は無効化される
  55.     "精霊"         => true,  # 「精霊システム」未導入時は無効化される       #这些所有意思大概就是这个脚本没有导入的情况下开了也没用。
  56.   }
  57.  
  58.   # MAP移動時の位置(設定無し時は中央)
  59.   MAP = {
  60.    # マップID => [x座標, y座標]
  61.    1 => [5, 5],
  62.    3 => [10, 5]
  63.   }
  64.  
  65.   # ミュージックでRTPも含む
  66.   RTP_MUSIC = true
  67. end
  68.  
  69.  
  70. module DebugPP
  71.   # DebugPP.spec(n)
  72.   def self.spec(n)
  73.     return false if SPEC[n].nil?
  74.     SPEC[n]
  75.   end
  76. end
  77.  
  78.  
  79. class Game_System
  80.   #--------------------------------------------------------------------------
  81.   # ● 公開インスタンス変数
  82.   #--------------------------------------------------------------------------
  83.   attr_writer   :save_count               # セーブ回数
  84. end
  85.  
  86.  
  87. #==============================================================================
  88. # ■ Window_DebugCommand
  89. #==============================================================================
  90. class Window_DebugCommand < Window_Command
  91.   #--------------------------------------------------------------------------
  92.   # ● オブジェクト初期化
  93.   #--------------------------------------------------------------------------
  94.   def initialize(height)
  95.     @window_height = height
  96.     super(0, 0)
  97.   end
  98.   #--------------------------------------------------------------------------
  99.   # ● ウィンドウ高さの取得
  100.   #--------------------------------------------------------------------------
  101.   def window_height
  102.     h = super
  103.     h > @window_height ? @window_height : h
  104.   end
  105.   #--------------------------------------------------------------------------
  106.   # ● 表示行数の取得
  107.   #--------------------------------------------------------------------------
  108.   def visible_line_number
  109.     n = (@window_height - standard_padding * 2) / item_height
  110.     n > item_max ? item_max : n
  111.   end
  112.   #--------------------------------------------------------------------------
  113.   # ● コマンドリストの作成
  114.   #--------------------------------------------------------------------------
  115.   def make_command_list
  116.     add_main_commands
  117.     add_original_commands
  118.     add_command("システム",     :ok, true, system_text)   if DebugPP.spec("システム")
  119.   end
  120.   #--------------------------------------------------------------------------
  121.   # ● 主要コマンドをリストに追加
  122.   #      ハンドラは全て:okで登録する
  123.   #--------------------------------------------------------------------------
  124.   def add_main_commands
  125.     add_command("スイッチ",     :ok, true, switch_text)   if DebugPP.spec("スイッチ")
  126.     add_command("変数",         :ok, true, variable_text) if DebugPP.spec("変数")
  127.     add_command("セルフSW",     :ok, true, self_sw_text)  if DebugPP.spec("セルフSW")
  128.     add_command(Vocab::item,    :ok, true, item_text)     if DebugPP.spec("アイテム")
  129.     add_command(Vocab::weapon,  :ok, true, weapon_text)   if DebugPP.spec("武器")
  130.     add_command(Vocab::armor,   :ok, true, armor_text)    if DebugPP.spec("防具")
  131.     add_command("パーティー",   :ok, true, party_text)    if DebugPP.spec("パーティー")
  132.     add_command(Vocab::status,  :ok, true, actor_text)    if DebugPP.spec("ステータス")
  133.     add_command(Vocab::skill,   :ok, true, skill_text)    if DebugPP.spec("スキル")
  134.     add_command("MAP移動",      :ok, true, map_text)      if DebugPP.spec("MAP移動")
  135.     add_command("ミュージック", :ok, true, music_text)    if DebugPP.spec("ミュージック")
  136.   end
  137.   #--------------------------------------------------------------------------
  138.   # ● 独自コマンドの追加用
  139.   #--------------------------------------------------------------------------
  140.   def add_original_commands
  141.     add_command("熟練度",       :ok, true, expert_text)     if defined?(SysUpdate)  and DebugPP.spec("熟練度")
  142.     add_command("用語辞典",     :ok, true, dictionary_text) if defined?(Dictionary) and DebugPP.spec("用語辞典")
  143.     add_command("World Map",    :ok, true, world_map_text)  if defined?(WorldMap)   and DebugPP.spec("WorldMap")
  144.     add_command("クエスト",     :ok, true, quest_text)      if defined?(Quest)      and DebugPP.spec("クエスト")
  145.     add_command("精霊",         :ok, true, spirit_text)     if defined?(Spirits)    and DebugPP.spec("精霊")
  146.   end
  147.   #--------------------------------------------------------------------------
  148.   # ● 説明文
  149.   #--------------------------------------------------------------------------
  150.   def switch_text
  151.     ["スイッチの状態を変更します。", "C (Enter) : ON / OFF"]
  152.   end
  153.   def variable_text
  154.     ["変数の値を変更します。", "↑ : +1 / ↓ : +1 / ⇔ 桁移動"]
  155.   end
  156.   def self_sw_text
  157.     ["セルフスイッチの状態を変更します。", "C (Enter) : ON / OFF"]
  158.   end
  159.   def item_text
  160.     ["アイテムの所持数を変更します。", "↑ : +1 / ↓ : +1 / ⇔ 桁移動"]
  161.   end
  162.   def weapon_text
  163.     ["武器の所持数を変更します。", "↑ : +1 / ↓ : +1 / ⇔ 桁移動"]
  164.   end
  165.   def armor_text
  166.     ["防具の所持数を変更します。", "↑ : +1 / ↓ : +1 / ⇔ 桁移動"]
  167.   end
  168.   def party_text
  169.     ["加入メンバーを変更します。", "C (Enter) : 加入 / 脱退"]
  170.   end
  171.   def actor_text
  172.     ["アクターのステータスを変更します。", "↑ : +1 / ↓ : +1 / ⇔ 桁移動"]
  173.   end
  174.   def skill_text
  175.     ["アクターの習得スキルを変更します。", "C (Enter) : 習得 / 忘却"]
  176.   end
  177.   def map_text
  178.     ["マップを移動します。", "C (Enter) : 移動"]
  179.   end
  180.   def music_text
  181.     ["音楽を変更します。", "C (Enter) : 再生 / Y : 停止 / X : MAP音復帰"]
  182.   end
  183.   def system_text
  184.     ["その他、色々変更します。", "C (Enter) : 変更"]
  185.   end
  186.   #--------------------------------------------------------------------------
  187.   # ● 説明文(拡張)
  188.   #--------------------------------------------------------------------------
  189.   def expert_text
  190.     ["アクターの熟練度を変更します。", "↑ : +1 / ↓ : +1 / ⇔ 桁移動 / X : 好み変更"]
  191.   end
  192.   def dictionary_text
  193.     ["用語の表示状態を変更します。", "C (Enter) : ON / OFF"]
  194.   end
  195.   def world_map_text
  196.     ["場所の表示状態を変更します。", "X : Region / C (Enter) : Town --> ON / OFF"]
  197.   end
  198.   def quest_text
  199.     ["クエストの状態を変更します。", "C (Enter) : 変更"]
  200.   end
  201.   def spirit_text
  202.     ["精霊の加入状態を変更します。", "C (Enter) : 加入 / 脱退"]
  203.   end
  204.   #--------------------------------------------------------------------------
  205.   # ● ヘルプウィンドウの更新
  206.   #--------------------------------------------------------------------------
  207.   def update_help
  208.     call_handler(:update)
  209.     ext = current_ext
  210.     text = ext.nil? ? "" : (ext[0] + "\n" + ext[1])
  211.     @help_window.set_text(text)
  212.   end
  213. end
  214.  
  215.  
  216. #==============================================================================
  217. # ■ Window_DebugInputNum
  218. #==============================================================================
  219. class Window_DebugInputNum < Window_HorzCommand
  220.   #--------------------------------------------------------------------------
  221.   # ● 公開インスタンス変数
  222.   #--------------------------------------------------------------------------
  223.   attr_reader    :item_window
  224.   attr_accessor  :max
  225.   attr_accessor  :min
  226.   attr_accessor  :sign
  227.   #--------------------------------------------------------------------------
  228.   # ● オブジェクト初期化
  229.   #--------------------------------------------------------------------------
  230.   def initialize(rect, num=0)
  231.     @num_max = 8
  232.     @num = []
  233.     [url=home.php?mod=space&uid=25307]@Max[/url] = 99999999
  234.     @sign = false
  235.     @pm_sign = true
  236.     [url=home.php?mod=space&uid=25749]@min[/url] = 0
  237.     super(rect.x, rect.y)
  238.     area(rect)
  239.     self.num = num
  240.     deactivate.hide
  241.   end
  242.   #--------------------------------------------------------------------------
  243.   # ● エリア変更
  244.   #--------------------------------------------------------------------------
  245.   def area(rect)
  246.     @area = rect
  247.     self.x = @area.x + (@area.width  - window_width ) / 2
  248.     self.y = @area.y + (@area.height - window_height) / 2
  249.     self
  250.   end
  251.   #--------------------------------------------------------------------------
  252.   # ● 項目数変更(Windowサイズ更新)
  253.   #--------------------------------------------------------------------------
  254.   def num_max=(n)
  255.     return if n == @num_max or n == 0
  256.     @num_max = n
  257.     self.x = @area.x + (@area.width  - window_width ) / 2
  258.     self.width = window_width
  259.     create_contents
  260.     clac_maxmin
  261.     self.num = 0
  262.     unselect
  263.   end
  264.   #--------------------------------------------------------------------------
  265.   # ● 数字更新
  266.   #--------------------------------------------------------------------------
  267.   def num=(n)
  268.     @num.clear
  269.     @pm_sign = (n >= 0) if @sign
  270.     n = n.abs
  271.     @num_max.times do |i|
  272.       @num[@num_max-1-i] = n % 10
  273.       n = (n / 10).truncate
  274.     end
  275.     refresh
  276.   end
  277.   #--------------------------------------------------------------------------
  278.   # ● 最大値計算
  279.   #--------------------------------------------------------------------------
  280.   def clac_maxmin
  281.     @max = @min = 0
  282.     @num_max.times {|i| @max += 9 * exp(i)}
  283.   end
  284.   #--------------------------------------------------------------------------
  285.   # ● 10のべき乗計算
  286.   #--------------------------------------------------------------------------
  287.   def exp(n)
  288.     r = 1
  289.     n.times {|i| r *= 10}
  290.     r
  291.   end
  292.   #--------------------------------------------------------------------------
  293.   # ● 数字
  294.   #--------------------------------------------------------------------------
  295.   def num
  296.     r = 0
  297.     @num_max.times {|i| r += @num[@num_max-1-i] * exp(i)}
  298.     r *= -1 if @sign and !@pm_sign
  299.     r
  300.   end
  301.   #--------------------------------------------------------------------------
  302.   # ● 項目の幅を取得
  303.   #--------------------------------------------------------------------------
  304.   def item_width
  305.     15
  306.   end
  307.   #--------------------------------------------------------------------------
  308.   # ● ウィンドウ幅の取得
  309.   #--------------------------------------------------------------------------
  310.   def window_width
  311.     (item_width + spacing) * col_max + standard_padding * 2
  312.   end
  313.   #--------------------------------------------------------------------------
  314.   # ● 桁数の取得
  315.   #--------------------------------------------------------------------------
  316.   def col_max
  317.     @sign ? (@num_max + 1) : @num_max
  318.   end
  319.   #--------------------------------------------------------------------------
  320.   # ● 符号除くindex
  321.   #--------------------------------------------------------------------------
  322.   def s_index(index = @index)
  323.     @sign ? (index-1) : index
  324.   end
  325.   #--------------------------------------------------------------------------
  326.   # ● 横に項目が並ぶときの空白の幅を取得
  327.   #--------------------------------------------------------------------------
  328.   def spacing
  329.     2
  330.   end
  331.   #--------------------------------------------------------------------------
  332.   # ● 終端選択
  333.   #--------------------------------------------------------------------------
  334.   def select_last
  335.     select(col_max - 1)
  336.     self
  337.   end
  338.   #--------------------------------------------------------------------------
  339.   # ● カーソルを下に移動
  340.   #--------------------------------------------------------------------------
  341.   def cursor_down(wrap = false)
  342.     if @sign and @index == 0
  343.       @pm_sign = !@pm_sign
  344.     else
  345.       @num[s_index] = (@num[s_index] + 10 - 1) % 10
  346.     end
  347.     redraw_current_item
  348.     Sound.play_cursor
  349.   end
  350.   #--------------------------------------------------------------------------
  351.   # ● カーソルを上に移動
  352.   #--------------------------------------------------------------------------
  353.   def cursor_up(wrap = false)
  354.     if @sign and @index == 0
  355.       @pm_sign = !@pm_sign
  356.     else
  357.       @num[s_index] = (@num[s_index] + 1) % 10
  358.     end
  359.     redraw_current_item
  360.     Sound.play_cursor
  361.   end
  362.   #--------------------------------------------------------------------------
  363.   # ● コマンドリストの作成
  364.   #--------------------------------------------------------------------------
  365.   def make_command_list
  366.     add_command(0, :sign) if @sign
  367.     @num_max.times {|i| add_command(0, :num)}
  368.   end
  369.   #--------------------------------------------------------------------------
  370.   # ● 選択項目の有効状態を取得
  371.   #--------------------------------------------------------------------------
  372.   def current_item_enabled?
  373.     n = self.num
  374.     n >= @min and n <= @max
  375.   end
  376.   #--------------------------------------------------------------------------
  377.   # ● 背景色 1 の取得
  378.   #--------------------------------------------------------------------------
  379.   def back_color
  380.     Color.new(0, 0, 0, 64)
  381.   end
  382.   #--------------------------------------------------------------------------
  383.   # ● 背景の描画
  384.   #--------------------------------------------------------------------------
  385.   def draw_back(rect)
  386.     contents.fill_rect(rect, back_color)
  387.   end
  388.   #--------------------------------------------------------------------------
  389.   # ● 項目の描画
  390.   #--------------------------------------------------------------------------
  391.   def draw_item(index)
  392.     rect = item_rect(index)
  393.     draw_back(rect)
  394.     change_color(normal_color, command_enabled?(index))
  395.     if @sign and index == 0
  396.       draw_text(rect, (@pm_sign ? " " : "-"), 2)
  397.     else
  398.       draw_text(rect, @num[s_index(index)], 2)
  399.     end
  400.   end
  401.   #--------------------------------------------------------------------------
  402.   # ● アイテムウィンドウの設定
  403.   #--------------------------------------------------------------------------
  404.   def item_window=(item_window)
  405.     @item_window = item_window
  406.     n = item_window.nil? ? 0 : item_window.num_max
  407.     s = item_window.nil? ? false : item_window.sign
  408.     if @sign != s
  409.       @num_max = 0
  410.       @sign = s
  411.     end
  412.     self.num_max = n
  413.     update
  414.   end
  415. end
  416.  
  417.  
  418. #==============================================================================
  419. # ■ Window_DebugBase
  420. #==============================================================================
  421. class Window_DebugBase < Window_Selectable
  422.   #--------------------------------------------------------------------------
  423.   # ● オブジェクト初期化
  424.   #--------------------------------------------------------------------------
  425.   def initialize(rect)
  426.     @max_n = max_n
  427.     super(rect.x, rect.y, rect.width, rect.height)
  428.     refresh
  429.     deactivate.hide
  430.   end
  431.   #--------------------------------------------------------------------------
  432.   # ● 決定やキャンセルなどのハンドリング処理
  433.   #--------------------------------------------------------------------------
  434.   def process_handling
  435.     return unless open? && active
  436.     return process_ok       if ok_enabled?        && Input.trigger?(:C)
  437.     return process_cancel   if cancel_enabled?    && Input.trigger?(:B)
  438.     return process_pagedown if handle?(:pagedown) && Input.trigger?(:R)
  439.     return process_pageup   if handle?(:pageup)   && Input.trigger?(:L)
  440.     return process_a        if handle?(:a)        && Input.trigger?(:A)
  441.     return process_x        if handle?(:x)        && Input.trigger?(:X)
  442.   end
  443.   def process_a
  444.     Sound.play_ok
  445.     call_handler(:a)
  446.   end
  447.   def process_x
  448.     Sound.play_ok
  449.     call_handler(:x)
  450.   end
  451.   #--------------------------------------------------------------------------
  452.   # ● カーソルを右に移動
  453.   #--------------------------------------------------------------------------
  454.   def cursor_right(wrap = false)
  455.     if col_max >= 2 && (index < item_max - 1 || (wrap && horizontal?))
  456.       select((index + 1) % item_max)
  457.     elsif col_max == 1 && index >= 0
  458.       if (index + 100) > (item_max - 1)
  459.         select(item_max - 1)
  460.       else
  461.         select((index + 100) % item_max)
  462.       end
  463.     end
  464.   end
  465.   #--------------------------------------------------------------------------
  466.   # ● カーソルを左に移動
  467.   #--------------------------------------------------------------------------
  468.   def cursor_left(wrap = false)
  469.     if col_max >= 2 && (index > 0 || (wrap && horizontal?))
  470.       select((index - 1 + item_max) % item_max)
  471.     elsif col_max == 1 && index >= 0
  472.       if (index - 100) < 0
  473.         select(0)
  474.       else
  475.         select((index - 100 + item_max) % item_max)
  476.       end
  477.     end
  478.   end
  479.   #--------------------------------------------------------------------------
  480.   # ● 項目数の取得
  481.   #--------------------------------------------------------------------------
  482.   def item_max
  483.     0
  484.   end
  485.   #--------------------------------------------------------------------------
  486.   # ● 選択項目の有効状態を取得
  487.   #--------------------------------------------------------------------------
  488.   def current_item_enabled?
  489.     !citem.nil?
  490.   end
  491.   #--------------------------------------------------------------------------
  492.   # ● IDの取得
  493.   #--------------------------------------------------------------------------
  494.   def id(i)
  495.     i + 1
  496.   end
  497.   def cid; id(@index); end
  498.   #--------------------------------------------------------------------------
  499.   # ● アイテムの取得
  500.   #--------------------------------------------------------------------------
  501.   def item(i)
  502.     nil
  503.   end
  504.   def citem; item(@index); end
  505.   #--------------------------------------------------------------------------
  506.   # ● アイテム名の取得
  507.   #--------------------------------------------------------------------------
  508.   def name(i)
  509.     ""
  510.   end
  511.   def cname; name(@index); end
  512.   #--------------------------------------------------------------------------
  513.   # ● アイテム状態の取得
  514.   #--------------------------------------------------------------------------
  515.   def status(i)
  516.     item(i)
  517.   end
  518.   def cstatus; status(@index); end
  519.   #--------------------------------------------------------------------------
  520.   # ● ステータステキスト
  521.   #--------------------------------------------------------------------------
  522.   def status_text(i)
  523.     status(i) ? "[ON]" : "[OFF]"
  524.   end
  525.   #--------------------------------------------------------------------------
  526.   # ● 名前の描画
  527.   #--------------------------------------------------------------------------
  528.   def draw_index_name(rect, index)
  529.     draw_text(rect, name(index))
  530.   end
  531.   #--------------------------------------------------------------------------
  532.   # ● ステータスの描画
  533.   #--------------------------------------------------------------------------
  534.   def draw_index_status(rect, index)
  535.     draw_text(rect, status_text(index), 2)
  536.   end
  537.   #--------------------------------------------------------------------------
  538.   # ● 項目の描画     id : name
  539.   #--------------------------------------------------------------------------
  540.   def draw_item_id_name(index)
  541.     id_text = sprintf("%04d:", id(index))
  542.     id_width = text_size(id_text).width
  543.     rect = item_rect_for_text(index)
  544.  
  545.     change_color(normal_color)
  546.     draw_text(rect, id_text)
  547.  
  548.     rect.x += id_width
  549.     rect.width -= id_width + 60
  550.     draw_index_name(rect, index)
  551.   end
  552.   #--------------------------------------------------------------------------
  553.   # ● 項目の描画     id : name    [ON/OFF]
  554.   #--------------------------------------------------------------------------
  555.   def draw_item_id_name_sw(index)
  556.     id_text = sprintf("%04d:", id(index))
  557.     id_width = text_size(id_text).width
  558.     rect = item_rect_for_text(index)
  559.  
  560.     change_color(normal_color)
  561.     draw_text(rect, id_text)
  562.  
  563.     rect.x += id_width
  564.     rect.width -= id_width + 60
  565.     draw_index_name(rect, index)
  566.  
  567.     rect.width += 60
  568.     draw_index_status(rect, index)
  569.   end
  570.   #--------------------------------------------------------------------------
  571.   # ● 項目の描画     id : name    num
  572.   #--------------------------------------------------------------------------
  573.   def draw_item_id_name_num(index)
  574.     id_text = sprintf("%04d:", id(index))
  575.     id_width = text_size(id_text).width
  576.     rect = item_rect_for_text(index)
  577.  
  578.     change_color(normal_color)
  579.     draw_text(rect, id_text)
  580.  
  581.     rect.x += id_width
  582.     rect.width -= id_width + 60
  583.     draw_index_name(rect, index)
  584.  
  585.     rect.width += 60
  586.     draw_text(rect, number(index), 2)
  587.   end
  588.   #--------------------------------------------------------------------------
  589.   # ● 数値の最大桁数取得
  590.   #--------------------------------------------------------------------------
  591.   def num_max
  592.     8
  593.   end
  594.   def max_n
  595.     num_max
  596.   end
  597.   #--------------------------------------------------------------------------
  598.   # ● 数値の符号
  599.   #--------------------------------------------------------------------------
  600.   def sign
  601.     false
  602.   end
  603.   #--------------------------------------------------------------------------
  604.   # ● アイテムの変更
  605.   #--------------------------------------------------------------------------
  606.   def change(n=0)
  607.   end
  608.   #--------------------------------------------------------------------------
  609.   # ● OK時の処理
  610.   #--------------------------------------------------------------------------
  611.   def ok
  612.     change
  613.     redraw_current_item
  614.   end
  615.   #--------------------------------------------------------------------------
  616.   # ● 数値の取得/設定
  617.   #--------------------------------------------------------------------------
  618.   def number(i=@index)
  619.     item(i)
  620.   end
  621.   def number=(n)
  622.     change(n)
  623.     redraw_current_item
  624.   end
  625. end
  626.  
  627. #==============================================================================
  628. # ■ Window_DebugBaseCommand
  629. #==============================================================================
  630. class Window_DebugBaseCommand < Window_Command
  631.   #--------------------------------------------------------------------------
  632.   # ● オブジェクト初期化
  633.   #--------------------------------------------------------------------------
  634.   def initialize(rect)
  635.     @area = rect
  636.     super(rect.x, rect.y)
  637.     refresh
  638.     deactivate.hide.unselect
  639.   end
  640.   #--------------------------------------------------------------------------
  641.   # ● ウィンドウ幅の取得
  642.   #--------------------------------------------------------------------------
  643.   def window_width
  644.     @area.width
  645.   end
  646.   #--------------------------------------------------------------------------
  647.   # ● ウィンドウ高さの取得
  648.   #--------------------------------------------------------------------------
  649.   def window_height
  650.     @area.height
  651.   end
  652.   #--------------------------------------------------------------------------
  653.   # ● 決定やキャンセルなどのハンドリング処理
  654.   #--------------------------------------------------------------------------
  655.   def process_handling
  656.     return unless open? && active
  657.     return process_ok       if ok_enabled?        && Input.trigger?(:C)
  658.     return process_cancel   if cancel_enabled?    && Input.trigger?(:B)
  659.     return process_pagedown if handle?(:pagedown) && Input.trigger?(:R)
  660.     return process_pageup   if handle?(:pageup)   && Input.trigger?(:L)
  661.     return process_a        if handle?(:a)        && Input.trigger?(:A)
  662.     return process_x        if handle?(:x)        && Input.trigger?(:X)
  663.   end
  664.   def process_a
  665.     Sound.play_ok
  666.     call_handler(:a)
  667.   end
  668.   def process_x
  669.     Sound.play_ok
  670.     call_handler(:x)
  671.   end
  672.   #--------------------------------------------------------------------------
  673.   # ● カーソルを右に移動
  674.   #--------------------------------------------------------------------------
  675.   def cursor_right(wrap = false)
  676.     if col_max >= 2 && (index < item_max - 1 || (wrap && horizontal?))
  677.       select((index + 1) % item_max)
  678.     elsif col_max == 1 && index >= 0
  679.       if (index + 100) > (item_max - 1)
  680.         select(item_max - 1)
  681.       else
  682.         select((index + 100) % item_max)
  683.       end
  684.     end
  685.   end
  686.   #--------------------------------------------------------------------------
  687.   # ● カーソルを左に移動
  688.   #--------------------------------------------------------------------------
  689.   def cursor_left(wrap = false)
  690.     if col_max >= 2 && (index > 0 || (wrap && horizontal?))
  691.       select((index - 1 + item_max) % item_max)
  692.     elsif col_max == 1 && index >= 0
  693.       if (index - 100) < 0
  694.         select(0)
  695.       else
  696.         select((index - 100 + item_max) % item_max)
  697.       end
  698.     end
  699.   end
  700.   #--------------------------------------------------------------------------
  701.   # ● 数値の最大桁数取得
  702.   #--------------------------------------------------------------------------
  703.   def num_max
  704.     0
  705.   end
  706.   #--------------------------------------------------------------------------
  707.   # ● 数値の符号
  708.   #--------------------------------------------------------------------------
  709.   def sign
  710.     false
  711.   end
  712.   #--------------------------------------------------------------------------
  713.   # ● OK時の処理
  714.   #--------------------------------------------------------------------------
  715.   def ok
  716.     change
  717.     redraw_current_item
  718.   end
  719. end
  720.  
  721.  
  722. #==============================================================================
  723. # ■ Window_DebugBaseHorzCommand
  724. #==============================================================================
  725. class Window_DebugBaseHorzCommand < Window_HorzCommand
  726.   #--------------------------------------------------------------------------
  727.   # ● オブジェクト初期化
  728.   #--------------------------------------------------------------------------
  729.   def initialize(rect)
  730.     @window_width = rect.width
  731.     super(rect.x, rect.y)
  732.     refresh
  733.     deactivate.hide.unselect
  734.   end
  735.   #--------------------------------------------------------------------------
  736.   # ● 桁数の取得
  737.   #--------------------------------------------------------------------------
  738.   def col_max
  739.     item_max
  740.   end
  741.   #--------------------------------------------------------------------------
  742.   # ● ウィンドウ幅の取得
  743.   #--------------------------------------------------------------------------
  744.   def window_width
  745.     @window_width
  746.   end
  747.   #--------------------------------------------------------------------------
  748.   # ● 数値の最大桁数取得
  749.   #--------------------------------------------------------------------------
  750.   def num_max
  751.     0
  752.   end
  753.   #--------------------------------------------------------------------------
  754.   # ● 数値の符号
  755.   #--------------------------------------------------------------------------
  756.   def sign
  757.     false
  758.   end
  759.   #--------------------------------------------------------------------------
  760.   # ● OK時の処理
  761.   #--------------------------------------------------------------------------
  762.   def ok
  763.     change
  764.     redraw_current_item
  765.   end
  766. end
  767.  
  768.  
  769. #==============================================================================
  770. # ■ Window_DebugSwitch
  771. #==============================================================================
  772. class Window_DebugSwitch < Window_DebugBase
  773.   #--------------------------------------------------------------------------
  774.   # ● 項目数の取得
  775.   #--------------------------------------------------------------------------
  776.   def item_max
  777.     $data_system.switches.size-1
  778.   end
  779.   #--------------------------------------------------------------------------
  780.   # ● アイテムの取得
  781.   #--------------------------------------------------------------------------
  782.   def item(i)
  783.     $game_switches[id(i)]
  784.   end
  785.   #--------------------------------------------------------------------------
  786.   # ● アイテム名の取得
  787.   #--------------------------------------------------------------------------
  788.   def name(i)
  789.     $data_system.switches[id(i)]
  790.   end
  791.   #--------------------------------------------------------------------------
  792.   # ● 項目の描画
  793.   #--------------------------------------------------------------------------
  794.   def draw_item(index)
  795.     draw_item_id_name_sw(index)
  796.   end
  797.   #--------------------------------------------------------------------------
  798.   # ● アイテムの変更
  799.   #--------------------------------------------------------------------------
  800.   def change
  801.     $game_switches[cid] = !$game_switches[cid]
  802.   end
  803. end
  804.  
  805.  
  806. #==============================================================================
  807. # ■ Window_DebugVariable
  808. #==============================================================================
  809. class Window_DebugVariable < Window_DebugBase
  810.   #--------------------------------------------------------------------------
  811.   # ● 項目数の取得
  812.   #--------------------------------------------------------------------------
  813.   def item_max
  814.     $data_system.variables.size-1
  815.   end
  816.   #--------------------------------------------------------------------------
  817.   # ● アイテムの取得
  818.   #--------------------------------------------------------------------------
  819.   def item(i)
  820.     $game_variables[id(i)]
  821.   end
  822.   #--------------------------------------------------------------------------
  823.   # ● アイテム名の取得
  824.   #--------------------------------------------------------------------------
  825.   def name(i)
  826.     $data_system.variables[id(i)]
  827.   end
  828.   #--------------------------------------------------------------------------
  829.   # ● 項目の描画
  830.   #--------------------------------------------------------------------------
  831.   def draw_item(index)
  832.     draw_item_id_name_num(index)
  833.   end
  834.   #--------------------------------------------------------------------------
  835.   # ● アイテムの変更
  836.   #--------------------------------------------------------------------------
  837.   def change(n)
  838.     $game_variables[cid] = n
  839.   end
  840.   #--------------------------------------------------------------------------
  841.   # ● 数値のmaxmin値取得
  842.   #--------------------------------------------------------------------------
  843.   def min
  844.     -99999999
  845.   end
  846.   def max
  847.     99999999
  848.   end
  849.   #--------------------------------------------------------------------------
  850.   # ● 数値の符号
  851.   #--------------------------------------------------------------------------
  852.   def sign
  853.     min < 0
  854.   end
  855.   #--------------------------------------------------------------------------
  856.   # ● 数値の符号
  857.   #--------------------------------------------------------------------------
  858.   def sign
  859.     true
  860.   end
  861. end
  862.  
  863.  
  864. #==============================================================================
  865. # ■ Window_DebugMapSelfSw
  866. #==============================================================================
  867. class Window_DebugMapSelfSw < Window_DebugBase
  868.   #--------------------------------------------------------------------------
  869.   # ● オブジェクト初期化
  870.   #--------------------------------------------------------------------------
  871.   def initialize(rect, map_id=$game_map.map_id)
  872.     @map_id = map_id
  873.     @map = load_data(sprintf("Data/Map%03d.rvdata2", @map_id))
  874.     super(rect)
  875.   end
  876.   #--------------------------------------------------------------------------
  877.   # ● 項目数の取得
  878.   #--------------------------------------------------------------------------
  879.   def item_max
  880.     @map.events.size
  881.   end
  882.   #--------------------------------------------------------------------------
  883.   # ● イベントID
  884.   #--------------------------------------------------------------------------
  885.   def id(i)
  886.     @map.events.keys[i]
  887.   end
  888.   #--------------------------------------------------------------------------
  889.   # ● アイテムの取得
  890.   #--------------------------------------------------------------------------
  891.   def item(i)
  892.     @map.events[id(i)]
  893.   end
  894.   #--------------------------------------------------------------------------
  895.   # ● アイテムの取得
  896.   #--------------------------------------------------------------------------
  897.   def name(i)
  898.     @map.events[id(i)].name
  899.   end
  900.   #--------------------------------------------------------------------------
  901.   # ● 項目の描画
  902.   #--------------------------------------------------------------------------
  903.   def draw_item(index)
  904.     draw_item_id_name(index)
  905.   end
  906.   #--------------------------------------------------------------------------
  907.   # ● ヘルプウィンドウの更新
  908.   #--------------------------------------------------------------------------
  909.   def update_help
  910.     @help_window.set_event(@map_id, cid)
  911.   end
  912. end
  913.  
  914. #==============================================================================
  915. # ■ Window_DebugSelfSwitch
  916. #==============================================================================
  917. class Window_DebugSelfSwitch < Window_DebugBaseHorzCommand
  918.   KEY = ["A", "B", "C", "D"]
  919.   #--------------------------------------------------------------------------
  920.   # ● オブジェクト初期化
  921.   #--------------------------------------------------------------------------
  922.   def initialize(rect, map_id=$game_map.map_id, ev_id=1)
  923.     @map_id = map_id
  924.     @ev_id = ev_id
  925.     super(rect)
  926.   end
  927.   #--------------------------------------------------------------------------
  928.   # ● 項目数の取得
  929.   #--------------------------------------------------------------------------
  930.   def item_max
  931.     KEY.size
  932.   end
  933.   #--------------------------------------------------------------------------
  934.   # ● ハッシュキー
  935.   #--------------------------------------------------------------------------
  936.   def key(i)
  937.     [@map_id, @ev_id, KEY[i]]
  938.   end
  939.   #--------------------------------------------------------------------------
  940.   # ● アイテムの取得
  941.   #--------------------------------------------------------------------------
  942.   def item(i)
  943.     $game_self_switches[key(i)]
  944.   end
  945.   #--------------------------------------------------------------------------
  946.   # ● アイテムの変更
  947.   #--------------------------------------------------------------------------
  948.   def change
  949.     k = key(@index)
  950.     $game_self_switches[k] = !$game_self_switches[k]
  951.   end
  952.   #--------------------------------------------------------------------------
  953.   # ● アイテム名の取得
  954.   #--------------------------------------------------------------------------
  955.   def name(i)
  956.     KEY[i]
  957.   end
  958.   #--------------------------------------------------------------------------
  959.   # ● コマンド名の取得
  960.   #--------------------------------------------------------------------------
  961.   def command_name(index)
  962.     @list[index][:name] + (item(index) ? "[ON]" : "[OFF]")
  963.   end
  964.   #--------------------------------------------------------------------------
  965.   # ● コマンドの有効状態を取得
  966.   #--------------------------------------------------------------------------
  967.   def command_enabled?(index)
  968.     item(index)
  969.   end
  970.   #--------------------------------------------------------------------------
  971.   # ● コマンドリストの作成
  972.   #--------------------------------------------------------------------------
  973.   def make_command_list
  974.     item_max.times {|i| add_command(name(i), :ok) }
  975.   end
  976.   #--------------------------------------------------------------------------
  977.   # ● イベントの設定
  978.   #--------------------------------------------------------------------------
  979.   def set_event(map_id, ev_id)
  980.     @map_id = map_id
  981.     @ev_id  = ev_id
  982.     refresh
  983.   end
  984. end
  985.  
  986.  
  987. #==============================================================================
  988. # ■ Window_DebugItem
  989. #==============================================================================
  990. class Window_DebugItem < Window_DebugBase
  991.   #--------------------------------------------------------------------------
  992.   # ● 項目数の取得
  993.   #--------------------------------------------------------------------------
  994.   def item_max
  995.     $data_items.size-1
  996.   end
  997.   #--------------------------------------------------------------------------
  998.   # ● アイテムの取得
  999.   #--------------------------------------------------------------------------
  1000.   def item(i)
  1001.     $data_items[id(i)]
  1002.   end
  1003.   #--------------------------------------------------------------------------
  1004.   # ● アイテムの変更
  1005.   #--------------------------------------------------------------------------
  1006.   def change(n)
  1007.     d = citem
  1008.     n -= $game_party.item_number(d)
  1009.     $game_party.gain_item(d, n)
  1010.   end
  1011.   #--------------------------------------------------------------------------
  1012.   # ● 名前の描画
  1013.   #--------------------------------------------------------------------------
  1014.   def draw_index_name(rect, index)
  1015.     draw_item_name(item(index), rect.x, rect.y)
  1016.   end
  1017.   #--------------------------------------------------------------------------
  1018.   # ● 項目の描画
  1019.   #--------------------------------------------------------------------------
  1020.   def draw_item(index)
  1021.     draw_item_id_name(index)
  1022.     draw_item_number(item_rect_for_text(index), item(index))
  1023.   end
  1024.   #--------------------------------------------------------------------------
  1025.   # ● アイテム個数を描画
  1026.   #--------------------------------------------------------------------------
  1027.   def draw_item_number(rect, item)
  1028.     draw_text(rect, sprintf(":%#{@max_n}d", $game_party.item_number(item)), 2)
  1029.   end
  1030.   #--------------------------------------------------------------------------
  1031.   # ● 数値の最大桁数取得
  1032.   #--------------------------------------------------------------------------
  1033.   def num_max
  1034.     Math.log10(max).to_i + 1
  1035.   end
  1036.   #--------------------------------------------------------------------------
  1037.   # ● 数値のmaxmin値取得
  1038.   #--------------------------------------------------------------------------
  1039.   def min
  1040.     0
  1041.   end
  1042.   def max
  1043.     $game_party.max_item_number(citem)
  1044.   end
  1045.   def max_n
  1046.     m = []
  1047.     0..item_max.times {|i| m.push(Math.log10($game_party.max_item_number(item(i))).to_i + 1)}
  1048.     m.max
  1049.   end
  1050.   #--------------------------------------------------------------------------
  1051.   # ● 数値の取得/設定
  1052.   #--------------------------------------------------------------------------
  1053.   def number
  1054.     $game_party.item_number(citem)
  1055.   end
  1056.   def number=(n)
  1057.     change(n)
  1058.     redraw_current_item
  1059.   end
  1060. end
  1061.  
  1062.  
  1063. #==============================================================================
  1064. # ■ Window_DebugWeapon
  1065. #==============================================================================
  1066. class Window_DebugWeapon < Window_DebugItem
  1067.   #--------------------------------------------------------------------------
  1068.   # ● 項目数の取得
  1069.   #--------------------------------------------------------------------------
  1070.   def item_max
  1071.     $data_weapons.size-1
  1072.   end
  1073.   #--------------------------------------------------------------------------
  1074.   # ● アイテムの取得
  1075.   #--------------------------------------------------------------------------
  1076.   def item(i)
  1077.     $data_weapons[id(i)]
  1078.   end
  1079. end
  1080.  
  1081.  
  1082. #==============================================================================
  1083. # ■ Window_DebugArmor
  1084. #==============================================================================
  1085. class Window_DebugArmor < Window_DebugItem
  1086.   #--------------------------------------------------------------------------
  1087.   # ● 項目数の取得
  1088.   #--------------------------------------------------------------------------
  1089.   def item_max
  1090.     $data_armors.size-1
  1091.   end
  1092.   #--------------------------------------------------------------------------
  1093.   # ● アイテムの取得
  1094.   #--------------------------------------------------------------------------
  1095.   def item(i)
  1096.     $data_armors[id(i)]
  1097.   end
  1098. end
  1099.  
  1100.  
  1101. #==============================================================================
  1102. # ■ Window_DebugParty
  1103. #==============================================================================
  1104. class Window_DebugParty < Window_DebugBase
  1105.   #--------------------------------------------------------------------------
  1106.   # ● 歩行グラフィックの描画
  1107.   #--------------------------------------------------------------------------
  1108.   def draw_line_character(character_name, character_index, x, y, enabled=true)
  1109.     return unless character_name
  1110.     bitmap = Cache.character(character_name)
  1111.     sign = character_name[/^[\!\$]./]
  1112.     if sign && sign.include?('$')
  1113.       cw = bitmap.width / 3
  1114.       ch = bitmap.height / 4
  1115.     else
  1116.       cw = bitmap.width / 12
  1117.       ch = bitmap.height / 8
  1118.     end
  1119.     y += (line_height - ch) / 2 if ch < line_height
  1120.     n = character_index
  1121.     src_rect = Rect.new((n%4*3+1)*cw, (n/4*4)*ch, cw, [ch, line_height].min)
  1122.     contents.blt(x, y, bitmap, src_rect, enabled ? 255 : translucent_alpha)
  1123.     cw
  1124.   end
  1125.   #--------------------------------------------------------------------------
  1126.   # ● アクターの歩行グラフィック描画
  1127.   #--------------------------------------------------------------------------
  1128.   def draw_actor_line_graphic(actor, x, y, enabled=true)
  1129.     draw_line_character(actor.character_name, actor.character_index, x, y, enabled)
  1130.   end
  1131.   #--------------------------------------------------------------------------
  1132.   # ● 項目数の取得<精霊システムあり用>
  1133.   #--------------------------------------------------------------------------
  1134.   def item_max_actors
  1135.     $data_actors.inject(0) {|r, a| r + (a.nil? ? 0 : (Spirits.spirit?(a.id) ? 0 : 1)) }
  1136.   end
  1137.   #--------------------------------------------------------------------------
  1138.   # ● 項目数の取得
  1139.   #--------------------------------------------------------------------------
  1140.   def item_max
  1141.     return item_max_actors if defined?(Spirits)
  1142.     $data_actors.size - 1
  1143.   end
  1144.   #--------------------------------------------------------------------------
  1145.   # ● アクターIDの取得<精霊システムあり用>
  1146.   #--------------------------------------------------------------------------
  1147.   def aid(i)
  1148.     $data_actors.select {|a| !a.nil? and !Spirits.spirit?(a.id)}[i].id
  1149.   end
  1150.   #--------------------------------------------------------------------------
  1151.   # ● アクターIDの取得
  1152.   #--------------------------------------------------------------------------
  1153.   def id(i)
  1154.     return aid(i) if defined?(Spirits)
  1155.     i + 1
  1156.   end
  1157.   #--------------------------------------------------------------------------
  1158.   # ● アイテムの取得
  1159.   #--------------------------------------------------------------------------
  1160.   def item(i)
  1161.     $game_actors[id(i)]
  1162.   end
  1163.   #--------------------------------------------------------------------------
  1164.   # ● アイテムの変更
  1165.   #--------------------------------------------------------------------------
  1166.   def change
  1167.     if status(@index)
  1168.       $game_party.remove_actor(cid)
  1169.     else
  1170.       $game_party.add_actor(cid)
  1171.     end
  1172.   end
  1173.   #--------------------------------------------------------------------------
  1174.   # ● アイテム状態の取得
  1175.   #--------------------------------------------------------------------------
  1176.   def status(i)
  1177.     $game_party.members.include?(item(i))
  1178.   end
  1179.   def cstate; status(@index); end
  1180.   #--------------------------------------------------------------------------
  1181.   # ● ステータステキスト
  1182.   #--------------------------------------------------------------------------
  1183.   def status_text(index)
  1184.     status(index) ? "[加入]" : "[未加入]"
  1185.   end
  1186.   #--------------------------------------------------------------------------
  1187.   # ● 名前の描画
  1188.   #--------------------------------------------------------------------------
  1189.   def draw_index_name(rect, index)
  1190.     draw_actor_line_graphic(item(index), rect.x, rect.y)
  1191.     draw_actor_name(item(index), rect.x + 34, rect.y, rect.width)
  1192.   end
  1193.   #--------------------------------------------------------------------------
  1194.   # ● 項目の描画
  1195.   #--------------------------------------------------------------------------
  1196.   def draw_item(index)
  1197.     draw_item_id_name_sw(index)
  1198.   end
  1199. end
  1200.  
  1201.  
  1202. #==============================================================================
  1203. # ■ Window_DebugActor
  1204. #==============================================================================
  1205. class Window_DebugActor < Window_DebugBase
  1206.   #--------------------------------------------------------------------------
  1207.   # ● オブジェクト初期化
  1208.   #--------------------------------------------------------------------------
  1209.   def initialize(rect)
  1210.     r = rect.dup
  1211.     r.width = 160
  1212.     super(r)
  1213.   end
  1214.   #--------------------------------------------------------------------------
  1215.   # ● 項目数の取得
  1216.   #--------------------------------------------------------------------------
  1217.   def item_max
  1218.     $data_actors.size - 1
  1219.   end
  1220.   #--------------------------------------------------------------------------
  1221.   # ● アイテムの取得
  1222.   #--------------------------------------------------------------------------
  1223.   def item(i)
  1224.     $game_actors[i+1]
  1225.   end
  1226.   #--------------------------------------------------------------------------
  1227.   # ● 項目の描画
  1228.   #--------------------------------------------------------------------------
  1229.   def draw_item(index)
  1230.     actor = item(index)
  1231.     rect = item_rect_for_text(index)
  1232.     if defined?(Spirits) and actor.spirit?
  1233.       draw_spirit_name(actor, rect.x, rect.y, rect.width)
  1234.     else
  1235.       draw_actor_name(actor, rect.x, rect.y, rect.width)
  1236.     end
  1237.   end
  1238.   #--------------------------------------------------------------------------
  1239.   # ● ヘルプウィンドウの更新
  1240.   #--------------------------------------------------------------------------
  1241.   def update_help
  1242.     @help_window.set_actor(citem) unless @index < 0
  1243.   end
  1244. end
  1245.  
  1246.  
  1247.  
  1248. #==============================================================================
  1249. # ■ Window_DebugActorStatus
  1250. #==============================================================================
  1251. class Window_DebugActorStatus < Window_DebugBaseCommand
  1252.   #--------------------------------------------------------------------------
  1253.   # ● オブジェクト初期化
  1254.   #--------------------------------------------------------------------------
  1255.   def initialize(rect)
  1256.     @actor = $game_actors[1]
  1257.     super(rect)
  1258.   end
  1259.   #--------------------------------------------------------------------------
  1260.   # ● アクター設定
  1261.   #--------------------------------------------------------------------------
  1262.   def set_actor(actor)
  1263.     return if @actor == actor
  1264.     @actor = actor
  1265.     refresh
  1266.   end
  1267.   #--------------------------------------------------------------------------
  1268.   # ● コマンドリストの作成
  1269.   #--------------------------------------------------------------------------
  1270.   def make_command_list
  1271.     add_command(Vocab::level,     :ok, true, 2)   # レベル
  1272.     add_command(Vocab::param(0),  :ok, true, 4)   # 最大HP
  1273.     add_command(Vocab::param(1),  :ok, true, 4)   # 最大MP
  1274.     add_command(Vocab::param(2),  :ok, true, 3)   # 攻撃力
  1275.     add_command(Vocab::param(3),  :ok, true, 3)   # 防御力
  1276.     add_command(Vocab::param(4),  :ok, true, 3)   # 魔法力
  1277.     add_command(Vocab::param(5),  :ok, true, 3)   # 魔法防御
  1278.     add_command(Vocab::param(6),  :ok, true, 3)   # 敏捷性
  1279.     add_command(Vocab::param(7),  :ok, true, 3)   # 運
  1280.   end
  1281.   #--------------------------------------------------------------------------
  1282.   # ● 項目の描画
  1283.   #--------------------------------------------------------------------------
  1284.   def draw_item(index)
  1285.     super
  1286.     draw_text(item_rect_for_text(index), status_val(index), 2)
  1287.   end
  1288.   def status_val(index)
  1289.     return 0 if @actor.nil?
  1290.     case index
  1291.     when 0; return @actor.level
  1292.     else;   return @actor.param(index-1)
  1293.     end
  1294.   end
  1295.   #--------------------------------------------------------------------------
  1296.   # ● 数値の最大桁数取得
  1297.   #--------------------------------------------------------------------------
  1298.   def num_max
  1299.     current_ext
  1300.   end
  1301.   #--------------------------------------------------------------------------
  1302.   # ● アイテムの変更
  1303.   #--------------------------------------------------------------------------
  1304.   def change(n=0)
  1305.     case index
  1306.     when 0; @actor.change_level(n, false)
  1307.     else;   @actor.add_param(index-1, n - status_val(index))
  1308.     end
  1309.   end
  1310.   #--------------------------------------------------------------------------
  1311.   # ● 数値の取得/設定
  1312.   #--------------------------------------------------------------------------
  1313.   def number
  1314.     status_val(@index)
  1315.   end
  1316.   def number=(n)
  1317.     change(n)
  1318.     if @index == 0
  1319.       contents.clear
  1320.       draw_all_items
  1321.     else
  1322.       redraw_current_item
  1323.     end
  1324.   end
  1325. end
  1326.  
  1327.  
  1328. #==============================================================================
  1329. # ■ Window_DebugActorSkill
  1330. #==============================================================================
  1331. class Window_DebugActorSkill < Window_DebugActorStatus
  1332.   #--------------------------------------------------------------------------
  1333.   # ● アクター設定
  1334.   #--------------------------------------------------------------------------
  1335.   def set_actor(actor)
  1336.     return if @actor == actor
  1337.     @actor = actor
  1338.     refresh_enabled
  1339.   end
  1340.   #--------------------------------------------------------------------------
  1341.   # ● 半透明描画用のアルファ値を取得
  1342.   #--------------------------------------------------------------------------
  1343.   def translucent_alpha
  1344.     return 80
  1345.   end
  1346.   #--------------------------------------------------------------------------
  1347.   # ● 許可状態だけ変更
  1348.   #--------------------------------------------------------------------------
  1349.   def refresh_enabled
  1350.     item_max.times do |i|
  1351.       next if @actor.nil?
  1352.       enabled = @actor.skill_learn?(item(i))
  1353.       if @list[i][:enabled] != enabled
  1354.         @list[i][:enabled] = enabled
  1355.         redraw_item(i)
  1356.       end
  1357.     end
  1358.   end
  1359.   #--------------------------------------------------------------------------
  1360.   # ● 選択項目の有効状態を取得
  1361.   #--------------------------------------------------------------------------
  1362.   def current_item_enabled?
  1363.     !citem.nil?
  1364.   end
  1365.   #--------------------------------------------------------------------------
  1366.   # ● アイテム取得
  1367.   #--------------------------------------------------------------------------
  1368.   def item(i)
  1369.     $data_skills[i+1]
  1370.   end
  1371.   def citem;  item(@index); end
  1372.   #--------------------------------------------------------------------------
  1373.   # ● コマンドリストの作成
  1374.   #--------------------------------------------------------------------------
  1375.   def make_command_list
  1376.     n = ($data_skills.size - 1)
  1377.     n.times {|i| add_command(item(i).id, :ok, @actor.skill_learn?(item(i)))}
  1378.   end
  1379.   #--------------------------------------------------------------------------
  1380.   # ● 項目の描画
  1381.   #--------------------------------------------------------------------------
  1382.   def draw_item(index)
  1383.     enabled = command_enabled?(index)
  1384.     change_color(normal_color, enabled)
  1385.     rect = item_rect_for_text(index)
  1386.     draw_item_name(item(index), rect.x, rect.y, enabled, rect.width-24)
  1387.   end
  1388.   #--------------------------------------------------------------------------
  1389.   # ● アイテムの変更
  1390.   #--------------------------------------------------------------------------
  1391.   def change
  1392.     if command_enabled?(@index)
  1393.       @actor.forget_skill(citem.id)
  1394.     else
  1395.       @actor.learn_skill(citem.id)
  1396.     end
  1397.     @list[@index][:enabled] = @actor.skill_learn?(citem)
  1398.   end
  1399.   #--------------------------------------------------------------------------
  1400.   # ● OK時の処理
  1401.   #--------------------------------------------------------------------------
  1402.   def ok
  1403.     change
  1404.     redraw_current_item
  1405.   end
  1406. end
  1407.  
  1408.  
  1409. #==============================================================================
  1410. # ■ Window_DebugMap
  1411. #==============================================================================
  1412. class Window_DebugMap < Window_DebugBase
  1413.   #--------------------------------------------------------------------------
  1414.   # ● オブジェクト初期化
  1415.   #--------------------------------------------------------------------------
  1416.   def initialize(rect)
  1417.     @map = $data_mapinfos.sort {|a,b| a[1].order - b[1].order}
  1418.     super(rect)
  1419.   end
  1420.   #--------------------------------------------------------------------------
  1421.   # ● 項目数の取得
  1422.   #--------------------------------------------------------------------------
  1423.   def item_max
  1424.     @map.size
  1425.   end
  1426.   #--------------------------------------------------------------------------
  1427.   # ● マップIDの取得
  1428.   #--------------------------------------------------------------------------
  1429.   def id(i)
  1430.     @map[i][0]
  1431.   end
  1432.   #--------------------------------------------------------------------------
  1433.   # ● アイテムの取得
  1434.   #--------------------------------------------------------------------------
  1435.   def item(i)
  1436.     @map[i][1]
  1437.   end
  1438.   #--------------------------------------------------------------------------
  1439.   # ● アイテム名の取得
  1440.   #--------------------------------------------------------------------------
  1441.   def name(i)
  1442.     item(i).name
  1443.   end
  1444.   #--------------------------------------------------------------------------
  1445.   # ● 項目の描画
  1446.   #--------------------------------------------------------------------------
  1447.   def draw_item(index)
  1448.     draw_item_id_name(index)
  1449.   end
  1450.   #--------------------------------------------------------------------------
  1451.   # ● 決定ハンドラの呼び出し
  1452.   #--------------------------------------------------------------------------
  1453.   def call_ok_handler
  1454.     ok
  1455.     super
  1456.   end
  1457.   #--------------------------------------------------------------------------
  1458.   # ● 移動位置
  1459.   #--------------------------------------------------------------------------
  1460.   def move_point(i)
  1461.     pos = DebugPP::MAP[id(i)]
  1462.     return pos unless pos.nil?
  1463.     data = load_data(sprintf("Data/Map%03d.rvdata2", id(i)))
  1464.     [(data.width / 2).truncate, (data.height / 2).truncate]
  1465.   end
  1466.   #--------------------------------------------------------------------------
  1467.   # ● OK時の処理
  1468.   #--------------------------------------------------------------------------
  1469.   def ok
  1470.     pos = move_point(@index)
  1471.     $game_player.reserve_transfer(cid, pos[0], pos[1], $game_player.direction)
  1472.     $game_temp.fade_type = 1  # 白
  1473.   end
  1474. end
  1475.  
  1476.  
  1477. #==============================================================================
  1478. # ■ Window_DebugMusicCtg
  1479. #==============================================================================
  1480. class Window_DebugMusicCtg < Window_DebugBaseHorzCommand
  1481.   #--------------------------------------------------------------------------
  1482.   # ● コマンドリストの作成
  1483.   #--------------------------------------------------------------------------
  1484.   def make_command_list
  1485.     ["BGM", "BGS", "ME", "SE"].each {|n| add_command(n, :ok) }
  1486.   end
  1487.   #--------------------------------------------------------------------------
  1488.   # ● ヘルプウィンドウの更新
  1489.   #--------------------------------------------------------------------------
  1490.   def update_help
  1491.     @help_window.set_ctg(@index)
  1492.   end
  1493. end
  1494.  
  1495.  
  1496. #==============================================================================
  1497. # ■ Window_DebugMusic
  1498. #==============================================================================
  1499. class Window_DebugMusic < Window_DebugBase
  1500.   BGM=0;BGS=1;ME=2;SE=3
  1501.   #--------------------------------------------------------------------------
  1502.   # ● オブジェクト初期化
  1503.   #--------------------------------------------------------------------------
  1504.   def initialize(rect)
  1505.     @ctg = BGM
  1506.     data_refresh
  1507.     super(rect)
  1508.   end
  1509.   #--------------------------------------------------------------------------
  1510.   # ● データ初期化
  1511.   #--------------------------------------------------------------------------
  1512.   def data_refresh
  1513.     @list = []
  1514.     4.times do |i|
  1515.       @list[i] = rtp_audio(i) + audio_grep(i)
  1516.     end
  1517.   end
  1518.   #--------------------------------------------------------------------------
  1519.   # ● データ初期化
  1520.   #--------------------------------------------------------------------------
  1521.   def set_ctg(ctg)
  1522.     return if @ctg == ctg
  1523.     @ctg = ctg
  1524.     create_contents
  1525.     draw_all_items
  1526.     self.top_row = 0
  1527.     unselect
  1528.   end
  1529.   #--------------------------------------------------------------------------
  1530.   # ● RTP-Audio
  1531.   #--------------------------------------------------------------------------
  1532.   def rtp_audio(i)
  1533.     return [] unless DebugPP::RTP_MUSIC
  1534.     case i
  1535.     when BGM
  1536.       return ["Airship.ogg","Battle1.ogg","Battle2.ogg","Battle3.ogg",
  1537.               "Battle4.ogg","Battle5.ogg","Battle6.ogg","Battle7.ogg",
  1538.               "Battle8.ogg","Battle9.ogg",
  1539.               "Dungeon1.ogg","Dungeon2.ogg","Dungeon3.ogg","Dungeon4.ogg",
  1540.               "Dungeon5.ogg","Dungeon6.ogg","Dungeon7.ogg","Dungeon8.ogg",
  1541.               "Dungeon9.ogg",
  1542.               "Field1.ogg","Field2.ogg","Field3.ogg","Field4.ogg",
  1543.               "Scene1.ogg","Scene2.ogg","Scene3.ogg","Scene4.ogg",
  1544.               "Scene5.ogg","Scene6.ogg","Ship.ogg",
  1545.               "Theme1.ogg","Theme2.ogg","Theme3.ogg","Theme4.ogg","Theme5.ogg",
  1546.               "Town1.ogg","Town2.ogg","Town3.ogg","Town4.ogg","Town5.ogg",
  1547.               "Town6.ogg","Town7.ogg"]
  1548.     when BGS
  1549.       return ["Clock.ogg","Darkness.ogg","Drips.ogg","Fire.ogg","Quake.ogg",
  1550.               "Rain.ogg","River.ogg","Sea.ogg","Storm.ogg","Wind.ogg"]
  1551.     when ME
  1552.       return ["Fanfare1.ogg","Fanfare2.ogg","Fanfare3.ogg","Gag.ogg",
  1553.               "Gameover1.ogg","Gameover2.ogg","Inn.ogg","Item.ogg","Mystery.ogg",
  1554.               "Organ.ogg","Shock.ogg","Victory1.ogg","Victory2.ogg"]
  1555.     when SE
  1556.       return ["Absorb1.ogg","Absorb2.ogg","Applause1.ogg","Applause2.ogg",
  1557.               "Attack1.ogg","Attack2.ogg","Attack3.ogg","Autodoor.ogg",
  1558.               "Barrier.ogg","Battle1.ogg","Battle2.ogg","Battle3.ogg",
  1559.               "Bell1.ogg","Bell2.ogg","Bell3.ogg","Bite.ogg","Blind.ogg",
  1560.               "Blow1.ogg","Blow2.ogg","Blow3.ogg","Blow4.ogg","Blow5.ogg",
  1561.               "Blow6.ogg","Blow7.ogg","Blow8.ogg","Book1.ogg","Book2.ogg",
  1562.               "Bow1.ogg","Bow2.ogg","Bow3.ogg","Bow4.ogg","Break.ogg",
  1563.               "Breath.ogg","Buzzer1.ogg","Buzzer2.ogg",
  1564.               "Cancel1.ogg","Cancel2.ogg","Cat.ogg","Chest.ogg",
  1565.               "Chicken.ogg","Chime1.ogg","Chime2.ogg",
  1566.               "Close1.ogg","Close2.ogg","Close3.ogg","Coin.ogg",
  1567.               "Collapse1.ogg","Collapse2.ogg","Collapse3.ogg","Collapse4.ogg",
  1568.               "Confuse.ogg","Cow.ogg","Crash.ogg","Crossbow.ogg","Crow.ogg",
  1569.               "Cry1.ogg","Cry2.ogg","Cursor1.ogg","Cursor2.ogg",
  1570.               "Damage1.ogg","Damage2.ogg","Damage3.ogg","Damage4.ogg","Damage5.ogg",
  1571.               "Darkness1.ogg","Darkness2.ogg","Darkness3.ogg","Darkness4.ogg",
  1572.               "Darkness5.ogg","Darkness6.ogg","Darkness7.ogg","Darkness8.ogg",
  1573.               "Decision1.ogg","Decision2.ogg","Decision3.ogg",
  1574.               "Devil1.ogg","Devil2.ogg","Devil3.ogg","Disappointment.ogg",
  1575.               "Dive.ogg","Dog.ogg","Down1.ogg","Down2.ogg","Down3.ogg","Down4.ogg",
  1576.               "Earth1.ogg","Earth2.ogg","Earth3.ogg","Earth4.ogg","Earth5.ogg",
  1577.               "Earth6.ogg","Earth7.ogg","Earth8.ogg", "Earth9.ogg",
  1578.               "Equip1.ogg","Equip2.ogg","Equip3.ogg","Evasion1.ogg","Evasion2.ogg",
  1579.               "Explosion1.ogg","Explosion2.ogg","Explosion3.ogg","Explosion4.ogg",
  1580.               "Explosion5.ogg","Explosion6.ogg","Explosion7.ogg","Fall.ogg",
  1581.               "Fire1.ogg","Fire2.ogg","Fire3.ogg","Fire4.ogg","Fire5.ogg",
  1582.               "Fire6.ogg","Fire7.ogg","Fire8.ogg","Fire9.ogg",
  1583.               "Flash1.ogg","Flash2.ogg","Flash3.ogg","Fog1.ogg","Fog2.ogg",
  1584.               "Frog.ogg","Gun1.ogg","Gun2.ogg",
  1585.               "Hammer.ogg","Heal1.ogg","Heal2.ogg","Heal3.ogg","Heal4.ogg",
  1586.               "Heal5.ogg","Heal6.ogg","Heal7.ogg","Horse.ogg",
  1587.               "Ice1.ogg","Ice2.ogg","Ice3.ogg","Ice4.ogg","Ice5.ogg","Ice6.ogg",
  1588.               "Ice7.ogg","Ice8.ogg","Ice9.ogg","Ice10.ogg","Ice11.ogg",
  1589.               "Item1.ogg","Item2.ogg","Item3.ogg","Jump1.ogg","Jump2.ogg",
  1590.               "Key.ogg","Knock.ogg","Laser.ogg","Load.ogg",
  1591.               "Machine.ogg","Magic1.ogg","Magic2.ogg","Magic3.ogg",
  1592.               "Magic4.ogg","Magic5.ogg","Magic6.ogg","Magic7.ogg","Miss.ogg",
  1593.               "Monster1.ogg","Monster2.ogg","Monster3.ogg","Monster4.ogg",
  1594.               "Monster5.ogg","Monster6.ogg","Monster7.ogg","Move.ogg",
  1595.               "Noise.ogg","Open1.ogg","Open2.ogg","Open3.ogg","Open4.ogg","Open5.ogg",
  1596.               "Paralyze1.ogg","Paralyze2.ogg","Paralyze3.ogg","Parry.ogg",
  1597.               "Phone.ogg","Poison.ogg","Pollen.ogg","Powerup.ogg","Push.ogg",
  1598.               "Raise1.ogg","Raise2.ogg","Raise3.ogg","Recovery.ogg",
  1599.               "Reflection.ogg","Resonance.ogg","Run.ogg",
  1600.               "Saint1.ogg","Saint2.ogg","Saint3.ogg","Saint4.ogg","Saint5.ogg",
  1601.               "Saint6.ogg","Saint7.ogg","Saint8.ogg","Saint9.ogg","Sand.ogg",
  1602.               "Save.ogg","Scream.ogg","Sheep.ogg","Shop.ogg",
  1603.               "Shot1.ogg","Shot2.ogg","Shot3.ogg","Silence.ogg",
  1604.               "Skill1.ogg","Skill2.ogg","Skill3.ogg",
  1605.               "Slash1.ogg","Slash2.ogg","Slash3.ogg","Slash4.ogg","Slash5.ogg",
  1606.               "Slash6.ogg","Slash7.ogg","Slash8.ogg","Slash9.ogg",
  1607.               "Slash10.ogg","Slash11.ogg","Slash12.ogg","Sleep.ogg",
  1608.               "Sound1.ogg","Sound2.ogg","Sound3.ogg","Stare.ogg","Starlight.ogg",
  1609.               "Switch1.ogg","Switch2.ogg","Switch3.ogg",
  1610.               "Sword1.ogg","Sword2.ogg","Sword3.ogg","Sword4.ogg","Sword5.ogg",
  1611.               "Teleport.ogg","Thunder1.ogg","Thunder2.ogg","Thunder3.ogg",
  1612.               "Thunder4.ogg","Thunder5.ogg","Thunder6.ogg","Thunder7.ogg",
  1613.               "Thunder8.ogg","Thunder9.ogg","Thunder10.ogg",
  1614.               "Thunder11.ogg","Thunder12.ogg","Twine.ogg",
  1615.               "Up1.ogg","Up2.ogg","Up3.ogg","Up4.ogg",
  1616.               "Water1.ogg","Water2.ogg","Water3.ogg","Water4.ogg",
  1617.               "Water5.ogg","Water6.ogg",
  1618.               "Wind1.ogg","Wind2.ogg","Wind3.ogg","Wind4.ogg","Wind5.ogg",
  1619.               "Wind6.ogg","Wind7.ogg","Wind8.ogg","Wind9.ogg","Wind10.ogg",
  1620.               "Wind11.ogg","Wolf.ogg"]
  1621.     end
  1622.     return []
  1623.   end
  1624.   #--------------------------------------------------------------------------
  1625.   # ● Audioフォルダのパス
  1626.   #--------------------------------------------------------------------------
  1627.   def path(i)
  1628.     case i
  1629.     when BGM; return "Audio/BGM/"
  1630.     when BGS; return "Audio/BGS/"
  1631.     when ME;  return "Audio/ME/"
  1632.     when SE;  return "Audio/SE/"
  1633.     end
  1634.   end
  1635.   def filter(i)
  1636.     case i
  1637.     when BGM; return "*.{ogg,wma,mp3,wav,mid}"
  1638.     when BGS; return "*.{ogg,wma,mp3,wav}"
  1639.     when ME;  return "*.{ogg,wma,mp3,wav,mid}"
  1640.     when SE;  return "*.{ogg,wma,mp3,wav}"
  1641.     end
  1642.   end
  1643.   #--------------------------------------------------------------------------
  1644.   # ● AudioフォルダのGrep
  1645.   #--------------------------------------------------------------------------
  1646.   def audio_grep(i)
  1647.     list = Dir.glob(path(i)+filter(i))
  1648.     file_list = []
  1649.     list.select {|l| !FileTest.directory?(l)}.collect {|l| File.basename(l)}
  1650.   end
  1651.   #--------------------------------------------------------------------------
  1652.   # ● 項目数の取得
  1653.   #--------------------------------------------------------------------------
  1654.   def item_max
  1655.     @list[@ctg].size
  1656.   end
  1657.   #--------------------------------------------------------------------------
  1658.   # ● アイテムの取得
  1659.   #--------------------------------------------------------------------------
  1660.   def item(i)
  1661.     @list[@ctg][i]
  1662.   end
  1663.   def citem; item(@index); end
  1664.   #--------------------------------------------------------------------------
  1665.   # ● 項目の描画
  1666.   #--------------------------------------------------------------------------
  1667.   def draw_item(index)
  1668.     draw_text(item_rect_for_text(index), item(index))
  1669.   end
  1670.   #--------------------------------------------------------------------------
  1671.   # ● 決定やキャンセルなどのハンドリング処理
  1672.   #--------------------------------------------------------------------------
  1673.   def process_handling
  1674.     return unless open? && active
  1675.     super
  1676.     return stop   if Input.trigger?(:Y)
  1677.     return replay if Input.trigger?(:X)
  1678.   end
  1679.   #--------------------------------------------------------------------------
  1680.   # ● 決定ボタンが押されたときの処理
  1681.   #--------------------------------------------------------------------------
  1682.   def process_ok
  1683.     if current_item_enabled?
  1684. #~       Sound.play_ok  # Musicでは鳴らさない
  1685.       Input.update
  1686.       deactivate
  1687.       call_ok_handler
  1688.     else
  1689.       Sound.play_buzzer
  1690.     end
  1691.   end
  1692.   #--------------------------------------------------------------------------
  1693.   # ● OK時の処理
  1694.   #--------------------------------------------------------------------------
  1695.   def ok
  1696.     return if citem.nil?
  1697.     pth = path(@ctg)+citem
  1698.     case @ctg
  1699.     when BGM; Audio.bgm_play(pth)
  1700.     when BGS; Audio.bgs_play(pth)
  1701.     when ME;  Audio.me_play(pth)
  1702.     when SE;  Audio.se_play(pth)
  1703.     end
  1704.   end
  1705.   def stop(i=@ctg)
  1706.     case i
  1707.     when BGM; Audio.bgm_stop
  1708.     when BGS; Audio.bgs_stop
  1709.     when ME;  Audio.me_stop
  1710.     when SE;  Audio.se_stop
  1711.     end
  1712.   end
  1713.   def replay
  1714.     RPG::BGM.last.replay
  1715.     RPG::BGS.last.replay
  1716.   end
  1717. end
  1718.  
  1719.  
  1720. #==============================================================================
  1721. # ■ Window_DebugSystem
  1722. #==============================================================================
  1723. class Window_DebugSystem < Window_DebugBaseCommand
  1724.   #--------------------------------------------------------------------------
  1725.   # ● コマンドリストの作成
  1726.   #--------------------------------------------------------------------------
  1727.   def make_command_list
  1728.     add_main_commands
  1729.     add_original_commands
  1730.   end
  1731.   #--------------------------------------------------------------------------
  1732.   # ● 主要コマンドをリストに追加
  1733.   #--------------------------------------------------------------------------
  1734.   def add_main_commands
  1735.     add_command("お金",             :input)
  1736.     add_command("セーブ回数",       :input)
  1737.     add_command("戦闘回数",         :input)
  1738.     add_command("セーブ禁止",       :ok)
  1739.     add_command("メニュー禁止",     :ok)
  1740.     add_command("エンカウント禁止", :ok)
  1741.     add_command("並び替え禁止",     :ok)
  1742.     add_command("全アイテム入手",   :ok)
  1743.     add_command("解像度",           :ok)
  1744.   end
  1745.   #--------------------------------------------------------------------------
  1746.   # ● 独自コマンドの追加用
  1747.   #--------------------------------------------------------------------------
  1748.   def add_original_commands
  1749.     add_command("用語辞典初期化",        :ok,    true, :dictionary) if defined?(Dictionary)
  1750.     add_command("ワールドマップ初期化",  :ok,    true, :worldmap)   if defined?(WorldMap)
  1751.     add_command("クエストランク",        :input, true, :quest_rank) if defined?(Quest)
  1752.     add_command("クエスト初期化",        :ok,    true, :quest)      if defined?(Quest)
  1753.   end
  1754.   #--------------------------------------------------------------------------
  1755.   # ● 数取得
  1756.   #--------------------------------------------------------------------------
  1757.   def item(index)
  1758.     case index
  1759.     when 0; return $game_party.gold
  1760.     when 1; return $game_system.save_count
  1761.     when 2; return $game_system.battle_count
  1762.     when 3; return $game_system.save_disabled
  1763.     when 4; return $game_system.menu_disabled
  1764.     when 5; return $game_system.encounter_disabled
  1765.     when 6; return $game_system.formation_disabled
  1766.     else
  1767.       case @list[index][:ext]
  1768.       when :quest_rank; return $game_party.quest_rank
  1769.       end
  1770.     end
  1771.     return 0
  1772.   end
  1773.   #--------------------------------------------------------------------------
  1774.   # ● テキスト
  1775.   #--------------------------------------------------------------------------
  1776.   def text(index)
  1777.     case index
  1778.     when 0,1,2;   return item(index)
  1779.     when 3,4,5,6; return item(index) ? "[禁止]" : "[許可]"
  1780.     when 8;       return Graphics.width == 640 ? "640×480" : "544×416"
  1781.     else
  1782.       case @list[index][:ext]
  1783.       when :quest_rank; return Quest::RANK[item(index)] + "(#{item(index)})"
  1784.       end
  1785.     end
  1786.     return ""
  1787.   end
  1788.   #--------------------------------------------------------------------------
  1789.   # ● 項目の描画
  1790.   #--------------------------------------------------------------------------
  1791.   def draw_item(index)
  1792.     super(index)
  1793.     draw_text(item_rect_for_text(index), text(index), 2)
  1794.   end
  1795.   #--------------------------------------------------------------------------
  1796.   # ● 数値の最大桁数取得
  1797.   #--------------------------------------------------------------------------
  1798.   def num_max
  1799.     Math.log10(max).to_i + 1
  1800.   end
  1801.   #--------------------------------------------------------------------------
  1802.   # ● 数値の符号
  1803.   #--------------------------------------------------------------------------
  1804.   def sign
  1805.     false
  1806.   end
  1807.   #--------------------------------------------------------------------------
  1808.   # ● 数値のmaxmin値取得
  1809.   #--------------------------------------------------------------------------
  1810.   def min
  1811.     case @list[@index][:ext]
  1812.     when :quest_rank; return 1
  1813.     end
  1814.     0
  1815.   end
  1816.   def max
  1817.     case @index
  1818.     when 0
  1819.       return $game_party.max_gold
  1820.     else
  1821.       case @list[@index][:ext]
  1822.       when :quest_rank; return 10
  1823.       end
  1824.     end
  1825.     99999999
  1826.   end
  1827.   #--------------------------------------------------------------------------
  1828.   # ● アイテムの変更
  1829.   #--------------------------------------------------------------------------
  1830.   def change(n=0)
  1831.     case @index
  1832.     when 0; $game_party.gain_gold(n - $game_party.gold)
  1833.     when 1; $game_system.save_count         = n
  1834.     when 2; $game_system.battle_count       = n
  1835.     when 3; $game_system.save_disabled      = n
  1836.     when 4; $game_system.menu_disabled      = n
  1837.     when 5; $game_system.encounter_disabled = n
  1838.     when 6; $game_system.formation_disabled = n
  1839.     when 7; all_item
  1840.     when 8; resize_screen
  1841.     else
  1842.       case @list[@index][:ext]
  1843.       when :dictionary; $game_system.dictionary.reset
  1844.       when :worldmap;   $game_system.worldmap.reset
  1845.       when :quest_rank; $game_party.quest_rank = n
  1846.       when :quest;      $game_system.quest.reset
  1847.       end
  1848.     end
  1849.   end
  1850.   #--------------------------------------------------------------------------
  1851.   # ● OK時の処理
  1852.   #--------------------------------------------------------------------------
  1853.   def ok
  1854.     change(!number)
  1855.     redraw_current_item
  1856.   end
  1857.   #--------------------------------------------------------------------------
  1858.   # ● 数値の取得/設定
  1859.   #--------------------------------------------------------------------------
  1860.   def number
  1861.     item(@index)
  1862.   end
  1863.   def number=(n)
  1864.     change(n)
  1865.     redraw_current_item
  1866.   end
  1867.   #--------------------------------------------------------------------------
  1868.   # ● OK時の処理 : all item
  1869.   #--------------------------------------------------------------------------
  1870.   def all_item
  1871.     n = $data_items.size - 1
  1872.     n.times {|i| $game_party.gain_item($data_items[i+1], 1)}
  1873.     n = $data_weapons.size - 1
  1874.     n.times {|i| $game_party.gain_item($data_weapons[i+1], 1)}
  1875.     n = $data_armors.size - 1
  1876.     n.times {|i| $game_party.gain_item($data_armors[i+1], 1)}
  1877.   end
  1878.   #--------------------------------------------------------------------------
  1879.   # ● OK時の処理 : win_resize
  1880.   #--------------------------------------------------------------------------
  1881.   def resize_screen
  1882.     if Graphics.width == 640
  1883.       Graphics.resize_screen(544, 416)
  1884.     else
  1885.       Graphics.resize_screen(640, 480)
  1886.     end
  1887.     call_handler(:exit)
  1888.   end
  1889. end
  1890.  
  1891.  
  1892. #==============================================================================
  1893. # ■ Window_DebugActorExpert
  1894. #==============================================================================
  1895. class Window_DebugActorExpert < Window_DebugActorStatus
  1896.   #--------------------------------------------------------------------------
  1897.   # ● コマンドリストの作成
  1898.   #--------------------------------------------------------------------------
  1899.   def make_command_list
  1900.     SysUpdate::ELEMENTS.each {|e| add_command(e, :ok, true, 2)}
  1901.   end
  1902.   #--------------------------------------------------------------------------
  1903.   # ● 項目の描画
  1904.   #--------------------------------------------------------------------------
  1905.   def draw_item(index)
  1906.     element_id = command_name(index)
  1907.     rect = item_rect_for_text(index)
  1908.     draw_attr_icon_pm(@actor, element_id, rect.x, rect.y)
  1909.     rect.x     += 26
  1910.     rect.width -= 26
  1911.     draw_text(rect, SysUpdate.attr_name(element_id))
  1912.     attr = @actor.attr[element_id]
  1913.     draw_text(rect, attr.lv_limit, 2)
  1914.     rect.width -= 30
  1915.     draw_text(rect, "/", 2)
  1916.     rect.width -= 20
  1917.     draw_text(rect, attr.level, 2)
  1918.   end
  1919.   #--------------------------------------------------------------------------
  1920.   # ● 数値の最大桁数取得
  1921.   #--------------------------------------------------------------------------
  1922.   def num_max
  1923.     2
  1924.   end
  1925.   #--------------------------------------------------------------------------
  1926.   # ● 数値の最大値取得
  1927.   #--------------------------------------------------------------------------
  1928.   def min
  1929.     1
  1930.   end
  1931.   def max
  1932.     @actor.attr[command_name(@index)].lv_limit
  1933.   end
  1934.   #--------------------------------------------------------------------------
  1935.   # ● アイテムの変更
  1936.   #--------------------------------------------------------------------------
  1937.   def change(n)
  1938.     @actor.attr[command_name(@index)].level = n
  1939.   end
  1940.   #--------------------------------------------------------------------------
  1941.   # ● 数値の取得/設定
  1942.   #--------------------------------------------------------------------------
  1943.   def number
  1944.     @actor.attr[command_name(@index)].level
  1945.   end
  1946.   def number=(n)
  1947.     change(n)
  1948.     redraw_current_item
  1949.   end
  1950.   #--------------------------------------------------------------------------
  1951.   # ● 得意状態変更
  1952.   #--------------------------------------------------------------------------
  1953.   def change_taste
  1954.     attr = @actor.attr[command_name(@index)]
  1955.     attr.taste = (attr.taste + 1) % 3
  1956.     redraw_current_item
  1957.   end
  1958. end
  1959.  
  1960.  
  1961. #==============================================================================
  1962. # ■ Window_DebugDictCtg
  1963. #==============================================================================
  1964. class Window_DebugDictCtg < Window_DebugBase
  1965.   #--------------------------------------------------------------------------
  1966.   # ● オブジェクト初期化
  1967.   #--------------------------------------------------------------------------
  1968.   def initialize(rect)
  1969.     r = rect.dup
  1970.     r.width = 120
  1971.     super(r)
  1972.   end
  1973.   #--------------------------------------------------------------------------
  1974.   # ● 項目数の取得
  1975.   #--------------------------------------------------------------------------
  1976.   def item_max
  1977.     $game_system.dictionary.size
  1978.   end
  1979.   #--------------------------------------------------------------------------
  1980.   # ● 用語カテゴリIDの取得
  1981.   #--------------------------------------------------------------------------
  1982.   def id(i)
  1983.     $game_system.dictionary.keys[i]
  1984.   end
  1985.   #--------------------------------------------------------------------------
  1986.   # ● アイテムの取得
  1987.   #--------------------------------------------------------------------------
  1988.   def item(i)
  1989.     $game_system.dictionary[id(i)]
  1990.   end
  1991.   #--------------------------------------------------------------------------
  1992.   # ● 項目の描画
  1993.   #--------------------------------------------------------------------------
  1994.   def draw_item(index)
  1995.     draw_text(item_rect_for_text(index), item(index).name)
  1996.   end
  1997.   #--------------------------------------------------------------------------
  1998.   # ● ヘルプウィンドウの更新
  1999.   #--------------------------------------------------------------------------
  2000.   def update_help
  2001.     @help_window.set_ctg(cid)
  2002.   end
  2003. end
  2004.  
  2005.  
  2006.  
  2007. #==============================================================================
  2008. # ■ Window_DebugDictionary
  2009. #==============================================================================
  2010. class Window_DebugDictionary < Window_DebugBase
  2011.   #--------------------------------------------------------------------------
  2012.   # ● オブジェクト初期化
  2013.   #--------------------------------------------------------------------------
  2014.   def initialize(rect)
  2015.     @ctg = $game_system.dictionary.keys[0]
  2016.     super
  2017.   end
  2018.   #--------------------------------------------------------------------------
  2019.   # ● カテゴリ設定
  2020.   #--------------------------------------------------------------------------
  2021.   def set_ctg(ctg)
  2022.     return if @ctg == ctg
  2023.     @ctg = ctg
  2024.     create_contents
  2025.     refresh
  2026.     self.top_row = 0
  2027.     unselect
  2028.   end
  2029.   #--------------------------------------------------------------------------
  2030.   # ● 項目数の取得
  2031.   #--------------------------------------------------------------------------
  2032.   def item_max
  2033.     $game_system.dictionary[@ctg].size
  2034.   end
  2035.   #--------------------------------------------------------------------------
  2036.   # ● 用語IDの取得
  2037.   #--------------------------------------------------------------------------
  2038.   def id(i)
  2039.     $game_system.dictionary[@ctg].keys[i]
  2040.   end
  2041.   #--------------------------------------------------------------------------
  2042.   # ● アイテムの取得
  2043.   #--------------------------------------------------------------------------
  2044.   def item(i)
  2045.     $game_system.dictionary[@ctg][id(i)]
  2046.   end
  2047.   #--------------------------------------------------------------------------
  2048.   # ● アイテム名の取得
  2049.   #--------------------------------------------------------------------------
  2050.   def name(i)
  2051.     item(i).name.split(/\\n/)[0]
  2052.   end
  2053.   #--------------------------------------------------------------------------
  2054.   # ● アイテム状態の取得
  2055.   #--------------------------------------------------------------------------
  2056.   def status(i)
  2057.     item(i).show_flg
  2058.   end
  2059.   #--------------------------------------------------------------------------
  2060.   # ● 項目の描画
  2061.   #--------------------------------------------------------------------------
  2062.   def draw_item(index)
  2063.     draw_item_id_name_sw(index)
  2064.   end
  2065.   #--------------------------------------------------------------------------
  2066.   # ● アイテムの変更
  2067.   #--------------------------------------------------------------------------
  2068.   def change(n=0)
  2069.     $game_system.dictionary[@ctg][cid].show_flg = !citem.show_flg
  2070.   end
  2071. end
  2072.  
  2073.  
  2074. #==============================================================================
  2075. # ■ Window_DebugWorldRegion
  2076. #==============================================================================
  2077. class Window_DebugWorldRegion < Window_DebugBase
  2078.   #--------------------------------------------------------------------------
  2079.   # ● オブジェクト初期化
  2080.   #--------------------------------------------------------------------------
  2081.   def initialize(rect)
  2082.     r = rect.dup
  2083.     r.height /= 2
  2084.     super(r)
  2085.   end
  2086.   #--------------------------------------------------------------------------
  2087.   # ● 項目数の取得
  2088.   #--------------------------------------------------------------------------
  2089.   def item_max
  2090.     WorldMap::REGION.size
  2091.   end
  2092.   #--------------------------------------------------------------------------
  2093.   # ● 用語カテゴリIDの取得
  2094.   #--------------------------------------------------------------------------
  2095.   def id(i)
  2096.     $game_system.worldmap.ids[i]
  2097.   end
  2098.   #--------------------------------------------------------------------------
  2099.   # ● アイテムの取得
  2100.   #--------------------------------------------------------------------------
  2101.   def item(i)
  2102.     $game_system.worldmap[id(i)]
  2103.   end
  2104.   #--------------------------------------------------------------------------
  2105.   # ● アイテム名の取得
  2106.   #--------------------------------------------------------------------------
  2107.   def name(i)
  2108.     item(i).region_name
  2109.   end
  2110.   #--------------------------------------------------------------------------
  2111.   # ● アイテム状態の取得
  2112.   #--------------------------------------------------------------------------
  2113.   def status(i)
  2114.     item(i).visible
  2115.   end
  2116.   #--------------------------------------------------------------------------
  2117.   # ● 項目の描画
  2118.   #--------------------------------------------------------------------------
  2119.   def draw_item(index)
  2120.     draw_item_id_name_sw(index)
  2121.   end
  2122.   #--------------------------------------------------------------------------
  2123.   # ● ヘルプウィンドウの更新
  2124.   #--------------------------------------------------------------------------
  2125.   def update_help
  2126.     @help_window.set_ctg(cid) unless @index < 0
  2127.   end
  2128.   #--------------------------------------------------------------------------
  2129.   # ● アイテムの変更
  2130.   #--------------------------------------------------------------------------
  2131.   def change(n=0)
  2132.     $game_system.worldmap[cid].visible = !cstatus
  2133.   end
  2134. end
  2135.  
  2136.  
  2137.  
  2138. #==============================================================================
  2139. # ■ Window_DebugWorldTown
  2140. #==============================================================================
  2141. class Window_DebugWorldTown < Window_DebugBase
  2142.   #--------------------------------------------------------------------------
  2143.   # ● オブジェクト初期化
  2144.   #--------------------------------------------------------------------------
  2145.   def initialize(rect)
  2146.     @ctg = $game_system.worldmap.ids[0]
  2147.     super(rect)
  2148.   end
  2149.   #--------------------------------------------------------------------------
  2150.   # ● カテゴリ設定
  2151.   #--------------------------------------------------------------------------
  2152.   def set_ctg(ctg)
  2153.     return if @ctg == ctg
  2154.     @ctg = ctg
  2155.     create_contents
  2156.     refresh
  2157.     self.top_row = 0
  2158.     unselect
  2159.   end
  2160.   #--------------------------------------------------------------------------
  2161.   # ● 項目数の取得
  2162.   #--------------------------------------------------------------------------
  2163.   def item_max
  2164.     $game_system.worldmap[@ctg].ids.size
  2165.   end
  2166.   #--------------------------------------------------------------------------
  2167.   # ● タウンIDの取得
  2168.   #--------------------------------------------------------------------------
  2169.   def id(i)
  2170.     $game_system.worldmap[@ctg].ids[i]
  2171.   end
  2172.   #--------------------------------------------------------------------------
  2173.   # ● アイテムの取得
  2174.   #--------------------------------------------------------------------------
  2175.   def item(i)
  2176.     $game_system.worldmap[@ctg][id(i)]
  2177.   end
  2178.   #--------------------------------------------------------------------------
  2179.   # ● アイテム名の取得
  2180.   #--------------------------------------------------------------------------
  2181.   def name(i)
  2182.     item(i).town_name
  2183.   end
  2184.   #--------------------------------------------------------------------------
  2185.   # ● アイテム状態の取得
  2186.   #--------------------------------------------------------------------------
  2187.   def status(i)
  2188.     item(i).visible
  2189.   end
  2190.   #--------------------------------------------------------------------------
  2191.   # ● 項目の描画
  2192.   #--------------------------------------------------------------------------
  2193.   def draw_item(index)
  2194.     draw_item_id_name_sw(index)
  2195.   end
  2196.   #--------------------------------------------------------------------------
  2197.   # ● アイテムの変更
  2198.   #--------------------------------------------------------------------------
  2199.   def change(n=0)
  2200.     $game_system.worldmap[@ctg][cid].visible = !cstatus
  2201.   end
  2202. end
  2203.  
  2204.  
  2205. #==============================================================================
  2206. # ■ Window_DebugQuestCtg
  2207. #==============================================================================
  2208. class Window_DebugQuestCtg < Window_DebugBaseHorzCommand
  2209.   #--------------------------------------------------------------------------
  2210.   # ● コマンドリストの作成
  2211.   #--------------------------------------------------------------------------
  2212.   def make_command_list
  2213.     ["イベントクエスト", "ギルドクエスト"].each {|n| add_command(n, :ok) }
  2214.   end
  2215.   #--------------------------------------------------------------------------
  2216.   # ● ヘルプウィンドウの更新
  2217.   #--------------------------------------------------------------------------
  2218.   def update_help
  2219.     @help_window.set_ctg(@index)
  2220.   end
  2221. end
  2222.  
  2223.  
  2224. #==============================================================================
  2225. # ■ Window_DebugQuest
  2226. #==============================================================================
  2227. class Window_DebugQuest < Window_DebugBase
  2228.   #--------------------------------------------------------------------------
  2229.   # ● オブジェクト初期化
  2230.   #--------------------------------------------------------------------------
  2231.   def initialize(rect)
  2232.     @ctg = 0
  2233.     data_refresh
  2234.     super(rect)
  2235.   end
  2236.   #--------------------------------------------------------------------------
  2237.   # ● カテゴリデータ集計
  2238.   #--------------------------------------------------------------------------
  2239.   def data_refresh
  2240.     @commands = []
  2241.     $game_system.quest.ids.each do |id|
  2242.       data = $game_system.quest[id]
  2243.       case @ctg
  2244.       when 0; @commands.push(data) if !data.enable
  2245.       when 1; @commands.push(data) if data.enable
  2246.       end
  2247.     end
  2248.   end
  2249.   #--------------------------------------------------------------------------
  2250.   # ● カテゴリ設定
  2251.   #--------------------------------------------------------------------------
  2252.   def set_ctg(ctg)
  2253.     return if @ctg == ctg
  2254.     @ctg = ctg
  2255.     data_refresh
  2256.     create_contents
  2257.     refresh
  2258.     self.top_row = 0
  2259.     unselect
  2260.   end
  2261.   #--------------------------------------------------------------------------
  2262.   # ● 項目数の取得
  2263.   #--------------------------------------------------------------------------
  2264.   def item_max
  2265.     @commands.size
  2266.   end
  2267.   #--------------------------------------------------------------------------
  2268.   # ● クエストIDの取得
  2269.   #--------------------------------------------------------------------------
  2270.   def id(i)
  2271.     @commands[i].id
  2272.   end
  2273.   #--------------------------------------------------------------------------
  2274.   # ● アイテムの取得
  2275.   #--------------------------------------------------------------------------
  2276.   def item(i)
  2277.     @commands[i]
  2278.   end
  2279.   #--------------------------------------------------------------------------
  2280.   # ● アイテム名の取得
  2281.   #--------------------------------------------------------------------------
  2282.   def name(i)
  2283.     Quest.conv_text(item(i).name)
  2284.   end
  2285.   #--------------------------------------------------------------------------
  2286.   # ● ステータステキスト
  2287.   #--------------------------------------------------------------------------
  2288.   def status_text(index)
  2289.     quest = item(index)
  2290.     quest.playing ? "[進行中(開始)]" :
  2291.         quest.clear ?   "[クリア済み]" :
  2292.              quest.fail ?    "[失敗]": "[未開始]"
  2293.   end
  2294.   #--------------------------------------------------------------------------
  2295.   # ● 項目の描画
  2296.   #--------------------------------------------------------------------------
  2297.   def draw_item(index)
  2298.     draw_item_id_name_sw(index)
  2299.   end
  2300.   #--------------------------------------------------------------------------
  2301.   # ● ヘルプウィンドウの更新
  2302.   #--------------------------------------------------------------------------
  2303.   def update_help
  2304.     @help_window.set_id(cid)
  2305.   end
  2306.   #--------------------------------------------------------------------------
  2307.   # ● OK時の処理
  2308.   #--------------------------------------------------------------------------
  2309.   def ok
  2310.     redraw_current_item
  2311.     @help_window.refresh
  2312.   end
  2313. end
  2314.  
  2315.  
  2316. #==============================================================================
  2317. # ■ Window_DebugQuestStatus
  2318. #==============================================================================
  2319. class Window_DebugQuestStatus < Window_DebugBaseHorzCommand
  2320.   #--------------------------------------------------------------------------
  2321.   # ● オブジェクト初期化
  2322.   #--------------------------------------------------------------------------
  2323.   def initialize(rect)
  2324.     @id = nil
  2325.     super(rect)
  2326.   end
  2327.   #--------------------------------------------------------------------------
  2328.   # ● クエストID設定
  2329.   #--------------------------------------------------------------------------
  2330.   def set_id(id)
  2331.     return if @id == id
  2332.     @id = id
  2333.     return contents.clear if id.nil?
  2334.     refresh
  2335.   end
  2336.   #--------------------------------------------------------------------------
  2337.   # ● コマンド名の取得
  2338.   #--------------------------------------------------------------------------
  2339.   def command_name(index)
  2340.     super + (command_enabled?(index) ? "[ON]" : "[OFF]")
  2341.   end
  2342.   #--------------------------------------------------------------------------
  2343.   # ● コマンドの有効状態を取得
  2344.   #--------------------------------------------------------------------------
  2345.   def command_enabled?(index)
  2346.     return false if @id.nil?
  2347.     case index
  2348.     when 0; return $game_system.quest[@id].visible
  2349.     when 1; return $game_system.quest[@id].view_res
  2350.     when 2; return $game_system.quest[@id].view_cond
  2351.     end
  2352.   end
  2353.   #--------------------------------------------------------------------------
  2354.   # ● コマンドリストの作成
  2355.   #--------------------------------------------------------------------------
  2356.   def make_command_list
  2357.     add_command("一覧", :ok)
  2358.     add_command("報酬", :ok)
  2359.     add_command("進捗", :ok)
  2360.   end
  2361. end
  2362.  
  2363.  
  2364. #==============================================================================
  2365. # ■ Window_DebugQuestCmd
  2366. #==============================================================================
  2367. class Window_DebugQuestCmd < Window_DebugBase
  2368.   #--------------------------------------------------------------------------
  2369.   # ● オブジェクト初期化
  2370.   #--------------------------------------------------------------------------
  2371.   def initialize(rect)
  2372.     @commands = [
  2373.       "進捗中(開始)", "クリア済み", "失敗",
  2374.       "表示切替", "報酬表示切替", "進捗表示切替",
  2375.       "リセット"
  2376.     ]
  2377.     rect.width = 160
  2378.     rect.x = Graphics.width - rect.width
  2379.     super(rect)
  2380.   end
  2381.   #--------------------------------------------------------------------------
  2382.   # ● ウィンドウの表示
  2383.   #--------------------------------------------------------------------------
  2384.   def show
  2385. #~     self.visible = true
  2386.     self
  2387.   end
  2388.   #--------------------------------------------------------------------------
  2389.   # ● ウィンドウの非表示
  2390.   #--------------------------------------------------------------------------
  2391.   def hide
  2392. #~     self.visible = false
  2393.     self
  2394.   end
  2395.   #--------------------------------------------------------------------------
  2396.   # ● ウィンドウのアクティブ化
  2397.   #--------------------------------------------------------------------------
  2398.   def activate
  2399.     self.visible = true
  2400.     self.active = true
  2401.     self
  2402.   end
  2403.   #--------------------------------------------------------------------------
  2404.   # ● ウィンドウの非アクティブ化
  2405.   #--------------------------------------------------------------------------
  2406.   def deactivate
  2407.     self.visible = false
  2408.     self.active = false
  2409.     self
  2410.   end
  2411.   #--------------------------------------------------------------------------
  2412.   # ● 項目数の取得
  2413.   #--------------------------------------------------------------------------
  2414.   def item_max
  2415.     @commands.size
  2416.   end
  2417.   #--------------------------------------------------------------------------
  2418.   # ● アイテムの取得
  2419.   #--------------------------------------------------------------------------
  2420.   def item(i)
  2421.     @commands[i]
  2422.   end
  2423.   #--------------------------------------------------------------------------
  2424.   # ● 項目の描画
  2425.   #--------------------------------------------------------------------------
  2426.   def draw_item(index)
  2427.     draw_text(item_rect_for_text(index), item(index))
  2428.   end
  2429.   #--------------------------------------------------------------------------
  2430.   # ● ヘルプウィンドウの更新
  2431.   #--------------------------------------------------------------------------
  2432.   def update_help
  2433.     # 何もしない
  2434.   end
  2435.   #--------------------------------------------------------------------------
  2436.   # ● OK時の処理
  2437.   #--------------------------------------------------------------------------
  2438.   def ok
  2439.     case @index
  2440.     when 0; @help_window.citem.quest_start
  2441.     when 1; @help_window.citem.quest_clear(true, false)  # 強制
  2442.     when 2; @help_window.citem.quest_fail(true, false)   # 強制
  2443.     when 3; @help_window.citem.visible   = !@help_window.citem.visible
  2444.     when 4; @help_window.citem.view_res  = !@help_window.citem.view_res
  2445.     when 5; @help_window.citem.view_cond = !@help_window.citem.view_cond
  2446.     when 6; @help_window.citem.reset
  2447.     end
  2448.     hide
  2449.     @help_window.activate.ok
  2450.   end
  2451. end
  2452.  
  2453.  
  2454. #==============================================================================
  2455. # ■ Window_DebugSpirit
  2456. #==============================================================================
  2457. class Window_DebugSpirit < Window_DebugBase
  2458.   #--------------------------------------------------------------------------
  2459.   # ● 項目数の取得
  2460.   #--------------------------------------------------------------------------
  2461.   def item_max
  2462.     Spirits::SPIRIT_ACTOR.size
  2463.   end
  2464.   #--------------------------------------------------------------------------
  2465.   # ● 精霊IDの取得
  2466.   #--------------------------------------------------------------------------
  2467.   def id(i)
  2468.     Spirits::SPIRIT_ACTOR.keys[i]
  2469.   end
  2470.   #--------------------------------------------------------------------------
  2471.   # ● アクターIDの取得
  2472.   #--------------------------------------------------------------------------
  2473.   def aid(i)
  2474.     Spirits.actor_id(id(i))
  2475.   end
  2476.   #--------------------------------------------------------------------------
  2477.   # ● アイテムの取得
  2478.   #--------------------------------------------------------------------------
  2479.   def item(i)
  2480.     $game_actors[aid(i)]
  2481.   end
  2482.   #--------------------------------------------------------------------------
  2483.   # ● アイテムの変更
  2484.   #--------------------------------------------------------------------------
  2485.   def change
  2486.     if status(@index)
  2487.       $game_party.remove_spirit(cid)
  2488.     else
  2489.       $game_party.add_spirit(cid)
  2490.     end
  2491.   end
  2492.   #--------------------------------------------------------------------------
  2493.   # ● アイテム状態の取得
  2494.   #--------------------------------------------------------------------------
  2495.   def status(i)
  2496.     $game_party.include_spirit?(id(i))
  2497.   end
  2498.   #--------------------------------------------------------------------------
  2499.   # ● ステータステキスト
  2500.   #--------------------------------------------------------------------------
  2501.   def status_text(i)
  2502.     status(i) ? "[加入]" : "[未加入]"
  2503.   end
  2504.   #--------------------------------------------------------------------------
  2505.   # ● 名前の描画
  2506.   #--------------------------------------------------------------------------
  2507.   def draw_index_name(rect, index)
  2508.     draw_actor_line_graphic(item(index), rect.x, rect.y)
  2509.     draw_spirit_name(item(index), rect.x + 34, rect.y)
  2510.   end
  2511.   #--------------------------------------------------------------------------
  2512.   # ● 項目の描画
  2513.   #--------------------------------------------------------------------------
  2514.   def draw_item(index)
  2515.     draw_item_id_name_sw(index)
  2516.   end
  2517. end
  2518.  
  2519.  
  2520. #==============================================================================
  2521. # ■ Scene_Debug
  2522. #------------------------------------------------------------------------------
  2523. #  デバッグ画面の処理を行うクラスです。
  2524. #==============================================================================
  2525.  
  2526. class Scene_Debug < Scene_MenuBase
  2527.   #--------------------------------------------------------------------------
  2528.   # ● 開始処理
  2529.   #--------------------------------------------------------------------------
  2530.   def start
  2531.     super
  2532.     init_sub_windows
  2533.     create_help_window
  2534.     create_cmd_window
  2535.     create_number_window
  2536.     create_main_windows
  2537.     create_original_windows
  2538.     create_system_window   if DebugPP.spec("システム")
  2539.     @sub[@cmd_window.index].each {|w| w.show}
  2540.   end
  2541.   #--------------------------------------------------------------------------
  2542.   # ● 主要コマンド用ウィンドウを生成
  2543.   #--------------------------------------------------------------------------
  2544.   def create_main_windows
  2545.     create_switch_window   if DebugPP.spec("スイッチ")
  2546.     create_variable_window if DebugPP.spec("変数")
  2547.     create_selfsw_window   if DebugPP.spec("セルフSW")
  2548.     create_item_window     if DebugPP.spec("アイテム")
  2549.     create_weapon_window   if DebugPP.spec("武器")
  2550.     create_armor_window    if DebugPP.spec("防具")
  2551.     create_party_window    if DebugPP.spec("パーティー")
  2552.     create_actor_window    if DebugPP.spec("ステータス")
  2553.     create_skill_window    if DebugPP.spec("スキル")
  2554.     create_map_window      if DebugPP.spec("MAP移動")
  2555.     create_music_window    if DebugPP.spec("ミュージック")
  2556.   end
  2557.   #--------------------------------------------------------------------------
  2558.   # ● オリジナルコマンド用ウィンドウを生成
  2559.   #--------------------------------------------------------------------------
  2560.   def create_original_windows
  2561.     create_expert_window   if defined?(SysUpdate)  and DebugPP.spec("熟練度")
  2562.     create_dict_window     if defined?(Dictionary) and DebugPP.spec("用語辞典")
  2563.     create_worldmap_window if defined?(WorldMap)   and DebugPP.spec("WorldMap")
  2564.     create_quest_window    if defined?(Quest)      and DebugPP.spec("クエスト")
  2565.     create_spirit_window   if defined?(Spirits)    and DebugPP.spec("精霊")
  2566.   end
  2567.   #--------------------------------------------------------------------------
  2568.   # ● 終了処理
  2569.   #--------------------------------------------------------------------------
  2570.   def terminate
  2571.     super
  2572.     #$game_map.refresh
  2573.   end
  2574.   #--------------------------------------------------------------------------
  2575.   # ● 子Window情報の初期化
  2576.   #--------------------------------------------------------------------------
  2577.   def init_sub_windows
  2578.     @sub = []
  2579.     @sub_i = 0
  2580.   end
  2581.   #--------------------------------------------------------------------------
  2582.   # ● ヘルプウィンドウの作成
  2583.   #--------------------------------------------------------------------------
  2584.   def create_help_window
  2585.     @help_window = Window_Help.new
  2586.     @help_window.y = Graphics.height - @help_window.height
  2587.   end
  2588.   #--------------------------------------------------------------------------
  2589.   # ● コマンドウィンドウの作成
  2590.   #--------------------------------------------------------------------------
  2591.   def create_cmd_window
  2592.     @cmd_window = Window_DebugCommand.new(@help_window.y)
  2593.     @cmd_window.set_handler(:ok,     method(:enable_sub_window))
  2594.     @cmd_window.set_handler(:cancel, method(:return_scene))
  2595.     @cmd_window.set_handler(:update, method(:change_sub_window))
  2596.     @cmd_window.help_window = @help_window
  2597.   end
  2598.   #--------------------------------------------------------------------------
  2599.   # ● コマンド・ヘルプ以外のエリア
  2600.   #--------------------------------------------------------------------------
  2601.   def area
  2602.     Rect.new(@cmd_window.width, 0, Graphics.width - @cmd_window.width, @help_window.y)
  2603.   end
  2604.   #--------------------------------------------------------------------------
  2605.   # ● 子Window参照
  2606.   #--------------------------------------------------------------------------
  2607.   def sub
  2608.     @sub[@cmd_window.index][@sub_i]
  2609.   end
  2610.   #--------------------------------------------------------------------------
  2611.   # ● 子Window領域
  2612.   #--------------------------------------------------------------------------
  2613.   def sub_area
  2614.     w = sub
  2615.     Rect.new(w.x, w.y, w.width, w.height)
  2616.   end
  2617.   #--------------------------------------------------------------------------
  2618.   # ● 子Window差し替え
  2619.   #--------------------------------------------------------------------------
  2620.   def change_sub_window
  2621.     @sub.size.times do |i|
  2622.       i == @cmd_window.index ? @sub[i].each {|w| w.show} :
  2623.                                @sub[i].each {|w| w.hide}
  2624.     end
  2625.   end
  2626.   #--------------------------------------------------------------------------
  2627.   # ● 子Window有効化
  2628.   #--------------------------------------------------------------------------
  2629.   def enable_sub_window
  2630.     sub.activate.select(0)
  2631.     @num_window.item_window = sub
  2632.   end
  2633.   #--------------------------------------------------------------------------
  2634.   # ● 子Window無効化(all)
  2635.   #--------------------------------------------------------------------------
  2636.   def disable_sub_window
  2637.     @sub[@cmd_window.index].each {|w| w.deactivate.unselect}
  2638.     @num_window.item_window = nil
  2639.   end
  2640.   #--------------------------------------------------------------------------
  2641.   # ● 子WindowのOK処理
  2642.   #--------------------------------------------------------------------------
  2643.   def ok_sub_window
  2644.     sub.activate.ok
  2645.   end
  2646.   #--------------------------------------------------------------------------
  2647.   # ● 子WindowのOK処理(前の子Windowへ)
  2648.   #--------------------------------------------------------------------------
  2649.   def ok_prev_sub_window
  2650.     sub.ok
  2651.     prev_sub_window
  2652.   end
  2653.   #--------------------------------------------------------------------------
  2654.   # ● 子WindowのOK処理(次の子Windowへ)
  2655.   #--------------------------------------------------------------------------
  2656.   def next_sub_window
  2657.     sub.deactivate
  2658.     @sub_i += 1
  2659.     sub.activate
  2660.     sub.select(0) if sub.index < 0
  2661.   end
  2662.   #--------------------------------------------------------------------------
  2663.   # ● 子WindowのOK処理(前の子Windowへ)
  2664.   #--------------------------------------------------------------------------
  2665.   def prev_sub_window
  2666.     sub.deactivate
  2667.     @sub_i -= 1
  2668.     sub.activate
  2669.     sub.select(0) if sub.index < 0
  2670.   end
  2671.   #--------------------------------------------------------------------------
  2672.   # ● 子WindowのCancel処理
  2673.   #--------------------------------------------------------------------------
  2674.   def cancel_sub_window
  2675.     disable_sub_window
  2676.     @cmd_window.activate
  2677.   end
  2678.   #--------------------------------------------------------------------------
  2679.   # ● 数値ウィンドウの作成
  2680.   #--------------------------------------------------------------------------
  2681.   def create_number_window
  2682.     @num_window = Window_DebugInputNum.new(area)
  2683.     @num_window.z = 1000
  2684.     @num_window.set_handler(:ok,     method(:ok_num_window))
  2685.     @num_window.set_handler(:cancel, method(:cancel_num_window))
  2686.   end
  2687.   #--------------------------------------------------------------------------
  2688.   # ● 数値Windowの有効化
  2689.   #--------------------------------------------------------------------------
  2690.   def enable_num_window
  2691.     @num_window.show.activate.select_last.num = sub.number
  2692.   end
  2693.   #--------------------------------------------------------------------------
  2694.   # ● 数値Windowの有効化<resize>
  2695.   #--------------------------------------------------------------------------
  2696.   def enable_num_window_resize
  2697.     @num_window.show.activate.area(sub_area).sign = sub.sign
  2698.     @num_window.show.activate.area(sub_area).num_max = sub.num_max
  2699.     @num_window.select_last.num = sub.number
  2700.   end
  2701.   #--------------------------------------------------------------------------
  2702.   # ● 数値Windowの有効化<resize & maxmin>
  2703.   #--------------------------------------------------------------------------
  2704.   def enable_num_window_resize_maxmin
  2705.     @num_window.show.activate.area(sub_area).sign = sub.sign
  2706.     @num_window.show.activate.area(sub_area).num_max = sub.num_max
  2707.     @num_window.select_last.max = sub.max
  2708.     @num_window.select_last.min = sub.min
  2709.     @num_window.select_last.num = sub.number
  2710.   end
  2711.   #--------------------------------------------------------------------------
  2712.   # ● 数値Window無効化
  2713.   #--------------------------------------------------------------------------
  2714.   def disable_num_window
  2715.     @num_window.hide.deactivate.area(area)
  2716.   end
  2717.   #--------------------------------------------------------------------------
  2718.   # ● 数値WindowのOK処理
  2719.   #--------------------------------------------------------------------------
  2720.   def ok_num_window
  2721.     sub.number = @num_window.num
  2722.     sub.activate
  2723.     disable_num_window
  2724.   end
  2725.   #--------------------------------------------------------------------------
  2726.   # ● 数値WindowのCancel処理
  2727.   #--------------------------------------------------------------------------
  2728.   def cancel_num_window
  2729.     disable_num_window
  2730.     sub.activate
  2731.   end
  2732.   #--------------------------------------------------------------------------
  2733.   # ● スイッチWindow作成
  2734.   #--------------------------------------------------------------------------
  2735.   def create_switch_window
  2736.     @switch_window = Window_DebugSwitch.new(area)
  2737.     @switch_window.set_handler(:ok,     method(:ok_sub_window))
  2738.     @switch_window.set_handler(:cancel, method(:cancel_sub_window))
  2739.     @sub.push([@switch_window])
  2740.   end
  2741.   #--------------------------------------------------------------------------
  2742.   # ● 変数Window作成
  2743.   #--------------------------------------------------------------------------
  2744.   def create_variable_window
  2745.     @variable_window = Window_DebugVariable.new(area)
  2746.     @variable_window.set_handler(:ok,     method(:enable_num_window_resize_maxmin))
  2747.     @variable_window.set_handler(:cancel, method(:cancel_sub_window))
  2748.     @sub.push([@variable_window])
  2749.   end
  2750.   #--------------------------------------------------------------------------
  2751.   # ● セルフスイッチWindow作成
  2752.   #--------------------------------------------------------------------------
  2753.   def create_selfsw_window
  2754.     rect = area
  2755.     @selfsw_window = Window_DebugSelfSwitch.new(rect)
  2756.     rect.height = rect.height - @selfsw_window.height
  2757.     @selfsw_window.y = rect.height
  2758.     @selfsw_window.set_handler(:ok,     method(:ok_sub_window))
  2759.     @selfsw_window.set_handler(:cancel, method(:prev_sub_window))
  2760.  
  2761.     @ss_map_window = Window_DebugMapSelfSw.new(rect)
  2762.     @ss_map_window.set_handler(:ok,     method(:next_sub_window))
  2763.     @ss_map_window.set_handler(:cancel, method(:cancel_sub_window))
  2764.     @ss_map_window.help_window = @selfsw_window
  2765.  
  2766.     @sub.push([@ss_map_window, @selfsw_window])
  2767.   end
  2768.   #--------------------------------------------------------------------------
  2769.   # ● アイテムWindow作成
  2770.   #--------------------------------------------------------------------------
  2771.   def create_item_window
  2772.     @item_window = Window_DebugItem.new(area)
  2773.     @item_window.set_handler(:ok,     method(:enable_num_window_resize_maxmin))
  2774.     @item_window.set_handler(:cancel, method(:cancel_sub_window))
  2775.     @sub.push([@item_window])
  2776.   end
  2777.   #--------------------------------------------------------------------------
  2778.   # ● 武器Window作成
  2779.   #--------------------------------------------------------------------------
  2780.   def create_weapon_window
  2781.     @weapon_window = Window_DebugWeapon.new(area)
  2782.     @weapon_window.set_handler(:ok,     method(:enable_num_window_resize_maxmin))
  2783.     @weapon_window.set_handler(:cancel, method(:cancel_sub_window))
  2784.     @sub.push([@weapon_window])
  2785.   end
  2786.   #--------------------------------------------------------------------------
  2787.   # ● 防具Window作成
  2788.   #--------------------------------------------------------------------------
  2789.   def create_armor_window
  2790.     @armor_window = Window_DebugArmor.new(area)
  2791.     @armor_window.set_handler(:ok,     method(:enable_num_window_resize_maxmin))
  2792.     @armor_window.set_handler(:cancel, method(:cancel_sub_window))
  2793.     @sub.push([@armor_window])
  2794.   end
  2795.   #--------------------------------------------------------------------------
  2796.   # ● パーティーWindow作成
  2797.   #--------------------------------------------------------------------------
  2798.   def create_party_window
  2799.     @party_window = Window_DebugParty.new(area)
  2800.     @party_window.set_handler(:ok,     method(:ok_sub_window))
  2801.     @party_window.set_handler(:cancel, method(:cancel_sub_window))
  2802.     @sub.push([@party_window])
  2803.   end
  2804.   #--------------------------------------------------------------------------
  2805.   # ● アクターステータスWindow作成
  2806.   #--------------------------------------------------------------------------
  2807.   def create_actor_window
  2808.     rect = area
  2809.     @actor_window = Window_DebugActor.new(rect)
  2810.     @actor_window.set_handler(:ok,     method(:next_sub_window))
  2811.     @actor_window.set_handler(:cancel, method(:cancel_sub_window))
  2812.  
  2813.     rect.x     += @actor_window.width
  2814.     rect.width -= @actor_window.width
  2815.     @actor_st_window = Window_DebugActorStatus.new(rect)
  2816.     @actor_st_window.set_handler(:ok,     method(:enable_num_window_resize))
  2817.     @actor_st_window.set_handler(:cancel, method(:prev_sub_window))
  2818.  
  2819.     @actor_window.help_window = @actor_st_window
  2820.     @sub.push([@actor_window, @actor_st_window])
  2821.   end
  2822.   #--------------------------------------------------------------------------
  2823.   # ● スキルWindow作成
  2824.   #--------------------------------------------------------------------------
  2825.   def create_skill_window
  2826.     rect = area
  2827.     @skill_window = Window_DebugActor.new(rect)
  2828.     @skill_window.set_handler(:ok,     method(:next_sub_window))
  2829.     @skill_window.set_handler(:cancel, method(:cancel_sub_window))
  2830.  
  2831.     rect.x     += @skill_window.width
  2832.     rect.width -= @skill_window.width
  2833.     @skills_window = Window_DebugActorSkill.new(rect)
  2834.     @skills_window.set_handler(:ok,     method(:ok_sub_window))
  2835.     @skills_window.set_handler(:cancel, method(:prev_sub_window))
  2836.  
  2837.     @skill_window.help_window = @skills_window
  2838.     @sub.push([@skill_window, @skills_window])
  2839.   end
  2840.   #--------------------------------------------------------------------------
  2841.   # ● MapWindow作成
  2842.   #--------------------------------------------------------------------------
  2843.   def create_map_window
  2844.     @map_window = Window_DebugMap.new(area)
  2845.     @map_window.set_handler(:ok,     method(:return_scene))
  2846.     @map_window.set_handler(:cancel, method(:cancel_sub_window))
  2847.     @sub.push([@map_window])
  2848.   end
  2849.   #--------------------------------------------------------------------------
  2850.   # ● ミュージックWindow作成
  2851.   #--------------------------------------------------------------------------
  2852.   def create_music_window
  2853.     rect = area
  2854.     @music_ctg_window = Window_DebugMusicCtg.new(rect)
  2855.     rect.y      += @music_ctg_window.height
  2856.     rect.height -= @music_ctg_window.height
  2857.     @music_ctg_window.set_handler(:ok,     method(:next_sub_window))
  2858.     @music_ctg_window.set_handler(:cancel, method(:cancel_sub_window))
  2859.  
  2860.     @mugic_window = Window_DebugMusic.new(rect)
  2861.     @mugic_window.set_handler(:ok,     method(:ok_sub_window))
  2862.     @mugic_window.set_handler(:cancel, method(:prev_sub_window))
  2863.     @music_ctg_window.help_window = @mugic_window
  2864.  
  2865.     @sub.push([@music_ctg_window, @mugic_window])
  2866.   end
  2867.   #--------------------------------------------------------------------------
  2868.   # ● システムWindow作成
  2869.   #--------------------------------------------------------------------------
  2870.   def create_system_window
  2871.     @system_window = Window_DebugSystem.new(area)
  2872.     @system_window.set_handler(:ok,     method(:ok_sub_window))
  2873.     @system_window.set_handler(:input,  method(:enable_num_window_resize_maxmin))
  2874.     @system_window.set_handler(:cancel, method(:cancel_sub_window))
  2875.     @system_window.set_handler(:exit,   method(:return_scene))
  2876.     @sub.push([@system_window])
  2877.   end
  2878.   #--------------------------------------------------------------------------
  2879.   # ● 熟練度Window作成
  2880.   #--------------------------------------------------------------------------
  2881.   def create_expert_window
  2882.     rect = area
  2883.     @exp_act_window = Window_DebugActor.new(rect)
  2884.     @exp_act_window.set_handler(:ok,     method(:next_sub_window))
  2885.     @exp_act_window.set_handler(:cancel, method(:cancel_sub_window))
  2886.  
  2887.     rect.x     += @exp_act_window.width
  2888.     rect.width -= @exp_act_window.width
  2889.     @expert_window = Window_DebugActorExpert.new(rect)
  2890.     @expert_window.set_handler(:ok,     method(:enable_num_window_resize_maxmin))
  2891.     @expert_window.set_handler(:cancel, method(:prev_sub_window))
  2892.     @expert_window.set_handler(:x,      method(:change_taste))
  2893.  
  2894.     @exp_act_window.help_window = @expert_window
  2895.     @sub.push([@exp_act_window, @expert_window])
  2896.   end
  2897.   def change_taste
  2898.     sub.change_taste
  2899.   end
  2900.   #--------------------------------------------------------------------------
  2901.   # ● 用語辞典Window作成
  2902.   #--------------------------------------------------------------------------
  2903.   def create_dict_window
  2904.     rect = area
  2905.     @dict_ctg_window = Window_DebugDictCtg.new(rect)
  2906.     @dict_ctg_window.set_handler(:ok,     method(:next_sub_window))
  2907.     @dict_ctg_window.set_handler(:cancel, method(:cancel_sub_window))
  2908.  
  2909.     rect.x     += @dict_ctg_window.width
  2910.     rect.width -= @dict_ctg_window.width
  2911.     @dictionary_window = Window_DebugDictionary.new(rect)
  2912.     @dictionary_window.set_handler(:ok,     method(:ok_sub_window))
  2913.     @dictionary_window.set_handler(:cancel, method(:prev_sub_window))
  2914.  
  2915.     @dict_ctg_window.help_window = @dictionary_window
  2916.     @sub.push([@dict_ctg_window, @dictionary_window])
  2917.   end
  2918.   #--------------------------------------------------------------------------
  2919.   # ● ワールドマップWindow作成
  2920.   #--------------------------------------------------------------------------
  2921.   def create_worldmap_window
  2922.     rect = area
  2923.     @wd_region_window = Window_DebugWorldRegion.new(rect)
  2924.     @wd_region_window.set_handler(:ok,     method(:next_sub_window))
  2925.     @wd_region_window.set_handler(:cancel, method(:cancel_sub_window))
  2926.     @wd_region_window.set_handler(:x,      method(:ok_sub_window))
  2927.  
  2928.     rect.y      += @wd_region_window.height
  2929.     rect.height -= @wd_region_window.height
  2930.     @wd_town_window = Window_DebugWorldTown.new(rect)
  2931.     @wd_town_window.set_handler(:ok,     method(:ok_sub_window))
  2932.     @wd_town_window.set_handler(:cancel, method(:prev_sub_window))
  2933.  
  2934.     @wd_region_window.help_window = @wd_town_window
  2935.     @sub.push([@wd_region_window, @wd_town_window])
  2936.   end
  2937.   #--------------------------------------------------------------------------
  2938.   # ● クエストWindow作成
  2939.   #--------------------------------------------------------------------------
  2940.   def create_quest_window
  2941.     rect = area
  2942.     @qt_ctg_window = Window_DebugQuestCtg.new(rect)
  2943.     @qt_ctg_window.set_handler(:ok,     method(:next_sub_window))
  2944.     @qt_ctg_window.set_handler(:cancel, method(:cancel_sub_window))
  2945.  
  2946.     rect.y      += @qt_ctg_window.height
  2947.     rect.height -= @qt_ctg_window.height
  2948.     @qt_st_window = Window_DebugQuestStatus.new(rect)
  2949.     @qt_st_window.y = rect.y + rect.height - @qt_st_window.height
  2950.  
  2951.     rect.height -= @qt_st_window.height
  2952.     @quest_window = Window_DebugQuest.new(rect)
  2953.     @quest_window.set_handler(:ok,     method(:next_sub_window))
  2954.     @quest_window.set_handler(:cancel, method(:prev_sub_window))
  2955.  
  2956.     @qt_cmd_window = Window_DebugQuestCmd.new(rect)
  2957.     @qt_cmd_window.set_handler(:ok,     method(:ok_prev_sub_window))
  2958.     @qt_cmd_window.set_handler(:cancel, method(:prev_sub_window))
  2959.  
  2960.     @qt_ctg_window.help_window = @quest_window
  2961.     @quest_window.help_window = @qt_st_window
  2962.     @qt_cmd_window.help_window = @quest_window
  2963.     @sub.push([@qt_ctg_window, @quest_window, @qt_cmd_window, @qt_st_window])
  2964.   end
  2965.   #--------------------------------------------------------------------------
  2966.   # ● 精霊Window作成
  2967.   #--------------------------------------------------------------------------
  2968.   def create_spirit_window
  2969.     @spirit_window = Window_DebugSpirit.new(area)
  2970.     @spirit_window.set_handler(:ok,     method(:ok_sub_window))
  2971.     @spirit_window.set_handler(:cancel, method(:cancel_sub_window))
  2972.     @sub.push([@spirit_window])
  2973.   end
  2974. end

Lv5.捕梦者 (暗夜天使)

只有笨蛋才会看到

梦石
1
星屑
20935
在线时间
9332 小时
注册时间
2012-6-19
帖子
7106

开拓者短篇九导演组冠军

2
发表于 2014-8-22 16:44:20 | 只看该作者
本帖最后由 喵呜喵5 于 2014-8-22 16:48 编辑

不丢原脚本地址看着你的翻译猜意思简直…………

http://www4.plala.or.jp/findias/ ... debug_pp/index.html
  1. #==============================================================================
  2. # ■ VXAce-RGSS-44 デバッグ++ [Ver.1.1.0]             by Claimh
  3. #------------------------------------------------------------------------------
  4. =begin
  5. 调试画面增加更多功能

  6. [追加功能]
  7. ・当前地图上全部事件的独立开关操作
  8. ・物品/武器/防具持有数改变
  9. ・队伍改变
  10. ・修改角色
  11.   - 修改角色能力状态
  12.   - 掌握/遗忘技能
  13. ・地图移动(可以指定移动位置)
  14. ・音乐播放(BGM/BGS/ME/SE)
  15. ・其他功能
  16.   - 金钱、存档次数、战斗次数修改
  17.   - 禁止存档、禁止菜单、禁止遇敌、禁止整队
  18.   - 修改天气
  19.   - 修改分辨率

  20. [与作者其他脚本的联动]
  21. ・熟練度システム
  22.   - 熟練度レベル変更、得意属性・不得意属性の操作
  23. ・用語辞典
  24.   - 全初期化、表示設定変更
  25. ・ワールドマップ
  26.   - 全初期化、表示設定変更
  27. ・クエストシステム
  28.   - 全初期化、クエスト状態変更、クエストランク変更
  29. ・精霊システム
  30.   - 精霊の加入状態の変更、精霊のステータス編集
  31. =end
复制代码

点评

QWQ  发表于 2014-8-23 09:51
明明就是演员→_→  发表于 2014-8-22 20:20
23333日语只会一点点基本上就是看汉字猜=w=  发表于 2014-8-22 16:46
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
75
在线时间
404 小时
注册时间
2014-3-30
帖子
86
3
发表于 2014-8-23 00:07:00 | 只看该作者
本帖最后由 一摸多汁 于 2014-8-23 00:11 编辑

アクター就是Actor 就是数据库里那些角色 除非不接触RM,不然怎么会翻译成演员


不过某种意义上,那些家伙们的确算是演员了 各种串场

点评

唔。。。这样啊谢大大指教=w=  发表于 2014-8-23 09:51
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-4-24 03:28

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表