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

Project1

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

[已经解决] 关于fuki脚本的显示问题

[复制链接]

Lv1.梦旅人

梦石
0
星屑
50
在线时间
37 小时
注册时间
2009-10-4
帖子
45
跳转到指定楼层
1
发表于 2012-6-17 13:02:36 | 只看该作者 |只看大图 回帖奖励 |倒序浏览 |阅读模式
这个脚本显示时会显示不全,请问要怎么改?
  1. #==============================================================================
  2. #    Fuki对话框优化版 v6
  3. #    原版作者:by パラ犬(日)
  4. #    汉化修正:by 66RPG.com
  5. #------------------------------------------------------------------------------
  6. #    2006年01月 汉化修改 by bbschat
  7. #    2007年02月 脚本更新 by KKME
  8. #    2007年07月 脚本更新 by 绫晓露雪萌
  9. #    2010年05月 脚本优化 by Linki Shy
  10. #    2011年10月 阴影修正 by 各种压力的猫君
  11. #    2011年11月 脚本增强 by 各种压力的猫君
  12. #==============================================================================
  13. #
  14. # 【脚本功能】
  15. #
  16. #   1. 此脚本主要是解决了在1.03版XP上的方块问题,以及增加了一些功能
  17. #
  18. #   2. 人名美化使用方法与以前一样
  19. #
  20. #   3. 默认人物头像在左边显示
  21. #      如果需要右边显示,在输入的名称之后加"@r"即可
  22. #      例: "阿尔西斯@r:"(注意必须小写)
  23. #
  24. #   4. 在对话中更改字体的方法:
  25. #       \f[X]:更改字号为X
  26. #
  27. #   5. 在对话中显示(技能 物品 武器 防具 人物)图标和名称的方法:
  28. #       \s[X]: 显示第X号技能图标和名称
  29. #       \i[X]: 显示第X号物品图标和名称
  30. #       \w[X]: 显示第X号武器图标和名称
  31. #       \a[X]: 显示第X号防具图标和名称
  32. #       \r[X]: 显示第X号人物图标和名称
  33. #
  34. #   6. 在对话中更改文字不透明度的方法:
  35. #       \o[X]: 把文字不透明度更改为X (取值范围为0~255)
  36. #   
  37. #   7. 在对话中关闭或开启拟声音效的方法:
  38. #       \q:默认开启时,执行一次关闭,再执行一次则开启
  39. #
  40. #   8. 如果需要自定义字体颜色,
  41. #       可以打开"Graphics/Windowskins"目录下的"Window.png"文件查看
  42. #       使用方法与VX类似
  43. #
  44. #   9. 追加了不为瞬间显示时确定键快速显示的功能
  45. #
  46. #  10. $mes_id = 0          代表本事件
  47. #      $mes_id = -1         代表主角
  48. #      $mes_id = 其他数值   代表事件编号
  49. #      $mes_id = nil        代表不使用fuki形式
  50. #
  51. #
  52. # 【素材要求】
  53. #
  54. #   1. 要求所有半身像朝向一致(默认是正面偏右)
  55. #
  56. #==============================================================================

  57. #==============================================================================
  58. # ■ Fuki_v6_Setup
  59. #------------------------------------------------------------------------------
  60. #    Fuki对话框优化版 v6 参数设置
  61. #==============================================================================

  62. module Fuki_v6_Setup
  63.    
  64.   #--------------------------------------------------------------------------
  65.   # ● 外观
  66.   #--------------------------------------------------------------------------
  67.   
  68.     # 窗口透明度
  69.     FUKI_OPACITY = 255         # 呼出对话框
  70.     MES_OPACITY  = 160         # 默认信息窗口
  71.    
  72.     # 角色高度尺寸
  73.     CHARACTOR_HEIGHT = 50
  74.    
  75.     # 呼出对话框的相对位置(纵坐标)
  76.     POP_SHIFT_TOP = 0          # 表示位置为上的时候
  77.     POP_SHIFT_UNDER = -4       # 表示位置为下的时候
  78.    
  79.     # 信息的表示速度(数字越小速度越快,0为瞬间表示)
  80.     # 游戏中可以随时用数字代入 $MES_SPEED 来改变消息表示速度。
  81.     MES_SPEED = 1
  82.    
  83.     # 名称修饰符(一对)(此处参考 沉影不器 的VX版对话框加强)
  84.     NAME_SYMBOL = "【】"
  85.    
  86.     # 名称颜色
  87.     NAME_COLOR = 7
  88.   
  89.   #--------------------------------------------------------------------------
  90.   # ● 功能( true / false )
  91.   #--------------------------------------------------------------------------
  92.    
  93.     # 是否显示尾巴
  94.     TAIL_SHOW = true
  95.    
  96.     # 是否播放打字音效
  97.     $play_voice = true
  98.    
  99.     # $MES_SPEED不为0时,是否可以用确定键快速显示对话
  100.     ENABLE_SKIP = true

  101.     # 窗口表示时是否根据画面大小自动改变窗口出现的位置
  102.     POS_FIX = true
  103.    
  104.   #--------------------------------------------------------------------------
  105.   # ● 字体
  106.   #--------------------------------------------------------------------------
  107.   
  108.     # 预设字体组
  109.     FONT_ARRAY = ["黑体", "宋体", "仿宋"]
  110.    
  111.     # 默认字号【已知BUG,当默认字号不为20时会导致各种奇怪问题……暂未修正】
  112.     MES_FONT_SIZE = 20
  113.    
  114.     # 默认字体颜色
  115.     FUKI_COLOR = Color.new(0, 0, 0, 255)
  116.   
  117.   #--------------------------------------------------------------------------
  118.   # ● 目录
  119.   #--------------------------------------------------------------------------
  120.   
  121.     # 呼出对话框用Skin名称(自动在 Graphics\Windowskins 内搜索)
  122.     FUKI_SKIN_NAME = "Window"
  123.    
  124.     # 设定头像图片保存目录
  125.     FACE_PIC_DIR = "Graphics/Faces/"

  126.   #--------------------------------------------------------------------------
  127.   # ● 头像对应表
  128.   #--------------------------------------------------------------------------
  129.   #    如果不想使用角色名字直接作为头像文件名
  130.   #    可在这里重新设定角色名字与文件名的对应关系
  131.   #
  132.   #  (这功能怎么用我自己也没搞明白……大家无视吧 by 各种压力的猫君)
  133.   #--------------------------------------------------------------------------
  134.   
  135.     NAME_TABLE = {"玩家"=>"维斯特"}
  136.    
  137. end
  138. #==============================================================================
  139.   
  140. "┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓"
  141. "┃        自定义内容到此结束,以下内容切勿随意修改        ┃"
  142. "┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛"

  143. #==============================================================================
  144. # ● 初始化全局变量并定义chat方法
  145. #==============================================================================
  146. $mes_id   = nil
  147. $mes_name = ""
  148. def chat(id = nil,name = "")
  149.   $mes_id = id
  150.   $mes_name = name
  151. end

  152. #==============================================================================
  153. # ■ Game_Temp
  154. #==============================================================================

  155. class Game_Temp
  156.   #--------------------------------------------------------------------------
  157.   # ● 定义实例变量
  158.   #--------------------------------------------------------------------------
  159.   attr_accessor:namebmp      # 记录角色名字和头像文件名对应关系
  160.   #--------------------------------------------------------------------------
  161.   # ● 初始化对像
  162.   #--------------------------------------------------------------------------
  163.   alias initialize_fuki initialize
  164.   def initialize
  165.     initialize_fuki
  166.     @namebmp = Fuki_v6_Setup::NAME_TABLE
  167.   end
  168. end

  169. #==============================================================================
  170. # ■ Window_InputNumber
  171. #==============================================================================

  172. class Window_InputNumber < Window_Base
  173.   #--------------------------------------------------------------------------
  174.   # ● 初始化对像
  175.   #     digits_max : 位数
  176.   #--------------------------------------------------------------------------
  177.   def initialize(digits_max)
  178.     @digits_max = digits_max
  179.     @number = 0
  180.     # 从数字的幅度计算(假定与 0~9 等幅)光标的幅度
  181.     dummy_bitmap = Bitmap.new(Fuki_v6_Setup::MES_FONT_SIZE, Fuki_v6_Setup::MES_FONT_SIZE)
  182.     @cursor_width = dummy_bitmap.text_size("0").width + 8
  183.     dummy_bitmap.dispose
  184.     super(0, 0, @cursor_width * @digits_max + 32, 64)
  185.     self.contents = Bitmap.new(width - 32, height - 32)
  186.     self.contents.font.size = Fuki_v6_Setup::MES_FONT_SIZE
  187.     self.contents.font.color = Fuki_v6_Setup::FUKI_COLOR
  188.     self.z += 9999
  189.     self.opacity = 0
  190.     @index = 0
  191.     refresh
  192.     update_cursor_rect
  193.   end
  194.   #--------------------------------------------------------------------------
  195.   # ● 更新光标矩形
  196.   #--------------------------------------------------------------------------
  197.   def update_cursor_rect
  198.     self.cursor_rect.set(@index * @cursor_width-4, 0, @cursor_width, Fuki_v6_Setup::MES_FONT_SIZE + 4)
  199.   end
  200.   #--------------------------------------------------------------------------
  201.   # ● 刷新
  202.   #--------------------------------------------------------------------------
  203.   def refresh
  204.     self.contents.clear
  205.     s = sprintf("%0*d", @digits_max, @number)
  206.     for i in 0...@digits_max
  207.       self.contents.draw_text(i * @cursor_width, 0, 24, Fuki_v6_Setup::MES_FONT_SIZE + 4, s[i,1])
  208.     end
  209.   end
  210. end

  211. #==============================================================================
  212. # ■ Window_Message
  213. #==============================================================================

  214. class Window_Message < Window_Selectable
  215.   
  216.   #--------------------------------------------------------------------------
  217.   # ● 初始化状态
  218.   #--------------------------------------------------------------------------
  219.   def initialize
  220.     super(80, 304, 480, 160)
  221.     self.contents = Bitmap.new(width - 32, height - 32)
  222.     self.contents.font.color = text_color(0)
  223.     self.visible = false
  224.     self.z = 9998
  225.     @fade_in = false
  226.     @fade_out = false
  227.     @contents_showing = false
  228.     @cursor_width = 0
  229.     self.active = false
  230.     self.index = -1
  231.     @w = 0
  232.     @h = 0
  233.     @wait = 0
  234.     @dx = 0
  235.     @dy = 0
  236.     $MES_SPEED = Fuki_v6_Setup::MES_SPEED
  237.     #------------------------
  238.     # ★ 特殊时期中断标志
  239.     #------------------------
  240.     @no_term_stop = false
  241.     @save_x = 0
  242.     @save_y = 0
  243.     @old_text_info = []
  244.     @show_right = false
  245.     @show_name  = false
  246.     @face_width = 0
  247.   end
  248.   #--------------------------------------------------------------------------
  249.   # ○ 决定窗口尺寸并生成窗口
  250.   #--------------------------------------------------------------------------
  251.   def refresh_create
  252.     unless @no_term_stop
  253.       @pic_skin.dispose if @pic_skin != nil
  254.       if $game_temp.message_text.include?(":")
  255.         if $game_temp.message_text.include?("@r")
  256.           @show_right = true
  257.           $game_temp.message_text.sub!(/\@r/, "")
  258.         end
  259.         @show_name = true
  260.         # 添加名称修饰符
  261.         unless Fuki_v6_Setup::NAME_SYMBOL.empty?
  262.           $game_temp.message_text = '\c[' + Fuki_v6_Setup::NAME_COLOR.to_s + ']' + Fuki_v6_Setup::NAME_SYMBOL[0,Fuki_v6_Setup::NAME_SYMBOL.size/2] + $game_temp.message_text
  263.           $game_temp.message_text.sub!(/\:/, Fuki_v6_Setup::NAME_SYMBOL[Fuki_v6_Setup::NAME_SYMBOL.size/2,Fuki_v6_Setup::NAME_SYMBOL.size/2] + '\c[0]')
  264.         end
  265.       end
  266.       self.contents.clear
  267.       self.contents.font.color = normal_color
  268.       # 取得窗口尺寸
  269.       get_windowsize
  270.       w = @w + 40#邦修改
  271.       h = @h * (self.contents.font.size + 4) + 30
  272.       h = 64 if h < 64
  273.       # 生成呼出窗口
  274.       set_fukidasi(self.x, self.y, w, h)
  275.       draw_msg_face
  276.       create_backbmp
  277.     end
  278.     # 初始化信息表示使用的变量
  279.     @dx = @save_x
  280.     @dx += @face_width unless @show_right
  281.     @dy = @save_y
  282.     @cursor_width = 0
  283.     @contents_drawing = true
  284.     # 瞬间表示的情况下
  285.     if $MES_SPEED == 0
  286.       # 循环信息描绘处理
  287.       while $game_temp.message_text != ""
  288.         draw_massage
  289.       end
  290.       draw_opt_text
  291.       @contents_showing_end = true
  292.       @contents_drawing = false
  293.     else
  294.       # 一个一个描绘文字
  295.       refresh_drawtext
  296.     end
  297.   end
  298.   #--------------------------------------------------------------------------
  299.   # ○ 一个一个描绘文字
  300.   #--------------------------------------------------------------------------
  301.   def refresh_drawtext
  302.     # 当按下确定键的时候直接显示剩余的全部文字
  303.     if Input.trigger?(Input::C) and Fuki_v6_Setup::ENABLE_SKIP
  304.       # 循环信息描绘处理
  305.       while $game_temp.message_text != ""
  306.         draw_massage
  307.       end
  308.       draw_opt_text
  309.       @contents_showing_end = true
  310.       @contents_drawing = false
  311.     elsif $game_temp.message_text != ""
  312.       if @wait > 0
  313.         @wait -= 1
  314.       elsif @wait == 0
  315.         # 描绘处理
  316.         draw_massage
  317.         @wait = $MES_SPEED
  318.       end
  319.     else
  320.       draw_opt_text
  321.       @contents_showing_end = true
  322.       @contents_drawing = false
  323.     end
  324.   end
  325.   #--------------------------------------------------------------------------
  326.   # ○ 取得窗口尺寸
  327.   #--------------------------------------------------------------------------
  328.   def get_windowsize
  329.     get_face_width($mes_name)
  330.     x = y = 0
  331.     @h = @w = 0
  332.     @cursor_width = 0
  333.     # 有选择项的话,处理字的缩进
  334.     if $game_temp.choice_start == 0
  335.       x = 16
  336.     end
  337.     # 有等待显示的文字的情况下
  338.     if $game_temp.message_text != nil
  339.     text = $game_temp.message_text.clone
  340.       # 限制文字处理
  341.       begin
  342.         last_text = text.clone
  343.         text.gsub!(/\\[Vv]\[([0-9]+)\]/) { $game_variables[$1.to_i] }
  344.       end until text == last_text
  345.       text.gsub!(/\\[Nn]\[([0-9]+)\]/) do
  346.         $game_actors[$1.to_i] != nil ? $game_actors[$1.to_i].name : ""
  347.       end
  348.       text.gsub!(/\\\\/)                 { "\x00" }
  349.       text.gsub!(/\\[Cc]\[([0-9]+)\]/)   { "\x01" }
  350.       text.gsub!(/\\[Gg]/)               { "\x02" }
  351.       text.gsub!(/\\[Ss]\[([0-9]+)\]/)   { "\x03" + $data_skills[$1.to_i].name }
  352.       text.gsub!(/\\[Ii]\[([0-9]+)\]/)   { "\x04" + $data_items[$1.to_i].name }
  353.       text.gsub!(/\\[Ww]\[([0-9]+)\]/)   { "\x05" + $data_weapons[$1.to_i].name }
  354.       text.gsub!(/\\[Aa]\[([0-9]+)\]/)   { "\x06" + $data_armors[$1.to_i].name }
  355.       text.gsub!(/\\[Rr]\[([0-9]+)\]/)   { "\x10" + $game_actors[$1.to_i].name }
  356.       # c 获取 1 个字 (如果不能取得文字就循环)
  357.       while ((c = text.slice!(/./m)) != nil)
  358.         if c == "\x00"
  359.           c = "\\"
  360.         end
  361.         if c == "\x01" or c == "\x02"
  362.           next
  363.         end
  364.         if c == "\x03" or c == "\x04" or c == "\x05" or c == "\x06" or c == "\x010"
  365.           c = "   "
  366.         end
  367.         if c == "\n"
  368.           # y 累加 1
  369.           y += 1
  370.           # 取得纵横尺寸
  371.           @h = y
  372.           @w = x > @w ? x : @w
  373.           if y >= $game_temp.choice_start
  374.             @w = x + Fuki_v6_Setup::MES_FONT_SIZE > @w ? x + Fuki_v6_Setup::MES_FONT_SIZE : @w
  375.           end
  376.           x = 0
  377.           x = Fuki_v6_Setup::MES_FONT_SIZE if y >= $game_temp.choice_start
  378.           # 下面的文字
  379.           next
  380.         end
  381.         # x 为要描绘文字的宽度加法运算
  382.         x += self.contents.text_size(c).width
  383.       end
  384.     end
  385.     # 输入数值的情况
  386.     if $game_temp.num_input_variable_id > 0
  387.       digits_max = $game_temp.num_input_digits_max
  388.       number = $game_variables[$game_temp.num_input_variable_id]
  389.       @h += 1
  390.       x = digits_max * self.contents.font.size + 16
  391.       @w = x > @w ? x : @w
  392.     end
  393.     @w += @face_width
  394.     @w = 128 if @w < 128
  395.   end
  396.   #--------------------------------------------------------------------------
  397.   # ○ 描绘信息处理
  398.   #--------------------------------------------------------------------------
  399.   def draw_massage
  400.     # 有等待显示的文字的情况下
  401.     if $game_temp.message_text != nil or @old_text_info != nil
  402.       text = $game_temp.message_text
  403.       # 限制文字处理
  404.       begin
  405.         last_text = text.clone
  406.         text.gsub!(/\\[Vv]\[([0-9]+)\]/) { $game_variables[$1.to_i] }
  407.       end until text == last_text
  408.       text.gsub!(/\\[Nn]\[([0-9]+)\]/) do
  409.         $game_actors[$1.to_i] != nil ? $game_actors[$1.to_i].name : ""
  410.       end
  411.       text.gsub!(/\\\\/)                 { "\x00" }
  412.       text.gsub!(/\\[Cc]\[([0-9]+)\]/)   { "\x01[#{$1}]" }
  413.       text.gsub!(/\\[Gg]/)               { "\x02" }
  414.       text.gsub!(/\\[Ss]\[([0-9]+)\]/)   { "\x03[#{$1}]" }
  415.       text.gsub!(/\\[Ii]\[([0-9]+)\]/)   { "\x04[#{$1}]" }
  416.       text.gsub!(/\\[Ww]\[([0-9]+)\]/)   { "\x05[#{$1}]" }
  417.       text.gsub!(/\\[Aa]\[([0-9]+)\]/)   { "\x06[#{$1}]" }
  418.       text.gsub!(/\\[Oo]\[([0-9]+)\]/)   { "\x07[#{$1}]" }
  419.       text.gsub!(/\\[Qq]/)               { "\x08" }
  420.       text.gsub!(/\\[Ff]\[([0-9]+)\]/)   { "\x09[#{$1}]" }
  421.       text.gsub!(/\\[Rr]\[([0-9]+)\]/)   { "\x10[#{$1}]" }
  422.       # c 获取 1 个字
  423.       c = text.slice!(/./m)
  424.       # 默认对话框采用默认颜色
  425.       self.contents.font.color = normal_color if $mes_id == nil
  426.       # 选择项的情况
  427.       if @dy >= $game_temp.choice_start
  428.         # 处理字的缩进
  429.         @dx = Fuki_v6_Setup::MES_FONT_SIZE
  430.         @dx += @face_width unless @show_right
  431.         @dx += Fuki_v6_Setup::MES_FONT_SIZE if @show_name
  432.         # 描绘文字
  433.         self.contents.draw_text(@dx, 24 * @dy, 24, 24, c)
  434.         # x 为要描绘文字宽度的加法运算
  435.         @dx += self.contents.text_size(c).width
  436.         # 循环
  437.         while ((c = text.slice!(/./m)) != "\n")
  438.           # 描绘文字
  439.           self.contents.draw_text(@dx, 24 * @dy, 24, 24, c)
  440.           # x 为要描绘文字宽度的加法运算
  441.           @dx += self.contents.text_size(c).width
  442.         end
  443.         if c == "\n"
  444.           # 更新光标宽度
  445.           @cursor_width = [@cursor_width, @dx - @face_width].max
  446.           # dy 累加 1
  447.           @dy += 1
  448.         end
  449.         return
  450.       end
  451.       case c
  452.       when "\x00"
  453.         c = "\\"            
  454.       when "\x01"                  
  455.         text.sub!(/\[([0-9]+)\]/, "")
  456.         color = $1.to_i
  457.         self.contents.font.color = text_color(color)
  458.       when "\x02"
  459.         @contents_showing_end = true
  460.         @contents_drawing = false
  461.         terminate_messageX
  462.         @save_x = @dx
  463.         @save_y = @dy
  464.       when "\x03"
  465.         text.sub!(/\[([0-9]+)\]/, "")
  466.         last_character
  467.         draw_icon($data_skills[$1.to_i], 4 + @dx, 24 * @dy)
  468.         @dx += self.contents.text_size("   ").width
  469.       when "\x04"
  470.         text.sub!(/\[([0-9]+)\]/, "")
  471.         last_character
  472.         draw_icon($data_items[$1.to_i], 4 + @dx, 24 * @dy)
  473.         @dx += self.contents.text_size("   ").width
  474.       when "\x05"
  475.         text.sub!(/\[([0-9]+)\]/, "")
  476.         last_character
  477.         draw_icon($data_weapons[$1.to_i], 4 + @dx, 24 * @dy)
  478.         @dx += self.contents.text_size("   ").width
  479.       when "\x06"
  480.         text.sub!(/\[([0-9]+)\]/, "")
  481.         last_character
  482.         draw_icon($data_armors[$1.to_i], 4 + @dx, 24 * @dy)
  483.         @dx += self.contents.text_size("   ").width
  484.       when "\x07"
  485.         text.sub!(/\[([0-9]+)\]/, "")
  486.         self.contents.font.color.alpha = $1.to_i
  487.       when "\x08"
  488.         text.sub!(/\[([0-9]+)\]/, "")
  489.         $play_voice = !$play_voice
  490.       when "\x09"
  491.         text.sub!(/\[([0-9]+)\]/, "")
  492.         self.contents.font.name = Fuki_v6_Setup::FONT_ARRAY[$1.to_i]
  493.       when "\x10"
  494.         text.sub!(/\[([0-9]+)\]/, "")
  495.         last_character
  496.         draw_actor_graphic($game_actors[$1.to_i], 4 + @dx, 24 * @dy)
  497.         @dx += self.contents.text_size("   ").width
  498.       when "\n"
  499.         @dy += 1
  500.         @dx = 0
  501.         @dx += @face_width unless @show_right
  502.         @dx += Fuki_v6_Setup::MES_FONT_SIZE if @show_name
  503.         last_character
  504.       else
  505.         last_character
  506.         size_zy = 6  # 设定文字动态增大幅度
  507.         if c != nil
  508.           self.contents.font.size = Fuki_v6_Setup::MES_FONT_SIZE
  509.           font_size = self.contents.font.size += size_zy
  510.           @old_text_info.push(@dx , @dy , font_size, self.contents.font.color.clone, c)
  511.           self.contents.draw_text(4 + @dx, (font_size + 4 - size_zy) * @dy - size_zy / 2, font_size, font_size, c)
  512.           self.contents.font.size -= size_zy
  513.           Audio.se_play("Audio/SE/Voice", 90, 100) if $play_voice and c != " "
  514.           @dx += self.contents.text_size(c).width
  515.         end
  516.       end
  517.     end
  518.   end
  519.   #--------------------------------------------------------------------------
  520.   # ○ 完成上一个字符的描绘
  521.   #--------------------------------------------------------------------------
  522.   def last_character
  523.     size_zy = 6  # 设定文字动态增大幅度
  524.     unless @old_text_info == []
  525.       self.contents.fill_rect (4 + @old_text_info[0], (@old_text_info[2]+ 4 - size_zy) * @old_text_info[1] - size_zy / 2, @old_text_info[2], @old_text_info[2], Color.new(0,0,0,0))
  526.       color = self.contents.font.color.clone
  527.       self.contents.font.color = @old_text_info[3].clone
  528.       self.contents.font.size = @old_text_info[2] -= size_zy
  529.       self.contents.draw_text(4 + @old_text_info[0], (@old_text_info[2] + 4) * @old_text_info[1], @old_text_info[2], @old_text_info[2], @old_text_info[4])
  530.       self.contents.font.color = color
  531.       @old_text_info = []
  532.     end
  533.   end
  534.   #--------------------------------------------------------------------------
  535.   # ○ 选择项和输入数值的情况下
  536.   #--------------------------------------------------------------------------
  537.   def draw_opt_text
  538.     # 选择项的情况下
  539.     if $game_temp.choice_max > 0
  540.       @item_max = $game_temp.choice_max
  541.       self.active = true
  542.       self.index = 0
  543.     end
  544.     # 输入数值的情况下
  545.     if $game_temp.num_input_variable_id > 0
  546.       digits_max = $game_temp.num_input_digits_max
  547.       number = $game_variables[$game_temp.num_input_variable_id]
  548.       @input_number_window = Window_InputNumber.new(digits_max)
  549.       @input_number_window.number = number
  550.       @input_number_window.x = self.x + @face_width + Fuki_v6_Setup::MES_FONT_SIZE + 8
  551.       @input_number_window.y = self.y + $game_temp.num_input_start * (Fuki_v6_Setup::MES_FONT_SIZE + 2)
  552.     end
  553.   end
  554.   #--------------------------------------------------------------------------
  555.   # ○ 生成背景图片
  556.   #--------------------------------------------------------------------------
  557.   def create_backbmp
  558.     @pic_skin.dispose if @pic_skin != nil
  559.     @pic_skin = Sprite.new
  560.     @pic_skin.opacity = 0 unless @no_term_stop
  561.     @pic_skin.bitmap = Bitmap.new(self.width + 32, self.height + 32)
  562.     @pic_skin.x = self.x + 2
  563.     @pic_skin.y = self.y + 2
  564.     @pic_skin.z = self.z
  565.     bitmap = RPG::Cache.windowskin(Fuki_v6_Setup::FUKI_SKIN_NAME)
  566.     rect = Rect.new(0, 0, 32, 32)
  567.     @pic_skin.bitmap.blt(0, 0, bitmap, rect)
  568.     rect = Rect.new(96, 0, 32, 32)
  569.     @pic_skin.bitmap.blt(self.width-32, 0, bitmap, rect)
  570.     rect = Rect.new(0, 96, 32, 32)
  571.     @pic_skin.bitmap.blt(0, self.height-32, bitmap, rect)
  572.     rect = Rect.new(96, 96, 32, 32)
  573.     @pic_skin.bitmap.blt(self.width-32, self.height-32, bitmap, rect)
  574.     rect = Rect.new(0, 32, 32, 32)
  575.     @pic_skin.bitmap.stretch_blt(Rect.new(0, 32, 32, self.height - 64), bitmap, rect)
  576.     rect = Rect.new(96, 32, 32, 32)
  577.     @pic_skin.bitmap.stretch_blt(Rect.new(self.width-32,32,32,self.height-64), bitmap, rect)
  578.     rect = Rect.new(32, 0, 32, 32)
  579.     @pic_skin.bitmap.stretch_blt(Rect.new(32,0,self.width-64,self.height-32), bitmap, rect)
  580.     # 如果尾巴在底端的话,更改底边描绘方式以修正阴影
  581.     if @message_position == 0 and @tale != nil
  582.       # 乱七八糟的三个计算变量
  583.       above_tale_x = @tale.x - self.x + 14
  584.       above_tale_width1 = @tale.x - self.x - 16 - 2
  585.       above_tale_width2 = self.width - above_tale_width1 - 32 - 64
  586.       # 中部(尾巴上方)
  587.       rect = Rect.new(32, 96, 32, 16)
  588.       @pic_skin.bitmap.stretch_blt(Rect.new(above_tale_x , self.height-32, 32, 24), bitmap, rect)
  589.       # 左半部
  590.       rect = Rect.new(32, 96, 32, 32)
  591.       @pic_skin.bitmap.stretch_blt(Rect.new(32, self.height-32, above_tale_width1, 32), bitmap, rect)
  592.       # 右半部
  593.       @pic_skin.bitmap.stretch_blt(Rect.new(32+above_tale_x, self.height-32, above_tale_width2, 32), bitmap, rect)
  594.       bitmap.dispose
  595.     else # 除此之外的情况保留原来的底边描绘方式
  596.       rect = Rect.new(32, 96, 32, 32)
  597.       @pic_skin.bitmap.stretch_blt(Rect.new(32,self.height-32,self.width-64,32), bitmap, rect)
  598.       bitmap.dispose
  599.     end
  600.   end
  601.   #--------------------------------------------------------------------------
  602.   # ○ 设置呼出对话框
  603.   #--------------------------------------------------------------------------
  604.   def set_fukidasi(x, y, width, height)
  605.     begin
  606.       self.pause = false # 不显示暂停标志
  607.       pos = get_fuki_pos(width, height) # 取得对话框位置
  608.       x = pos[0]
  609.       y = pos[1]
  610.       self.windowskin = RPG::Cache.windowskin($game_system.windowskin_name)
  611.       self.x = x
  612.       self.y = y
  613.       self.height = height
  614.       self.width = width
  615.       unless @no_term_stop
  616.         self.contents.dispose
  617.         self.contents = Bitmap.new(width - 32, height - 32)
  618.         self.back_opacity = Fuki_v6_Setup::FUKI_OPACITY
  619.         self.contents.clear
  620.         self.contents.font.color = Color.new(0, 0, 0, 255)
  621.         self.contents.font.size = Fuki_v6_Setup::MES_FONT_SIZE
  622.       end
  623.       if $game_system.message_frame == 0
  624.         tale_pos = get_tale_pos
  625.         @tale = Sprite.new
  626.         @tale.bitmap = Bitmap.new(64, 32)
  627.         if Fuki_v6_Setup::TAIL_SHOW
  628.           case @message_position
  629.           when 0  # 上
  630.             bitmap = RPG::Cache.windowskin(Fuki_v6_Setup::FUKI_SKIN_NAME)
  631.             rect = Rect.new(32, 32, 64, 32)
  632.             @tale.bitmap.blt(0, 0, bitmap, rect)
  633.             bitmap.dispose
  634.             @tale.x = tale_pos[0]
  635.             @tale.x += 8 if @tale.x < 64
  636.             if @tale.x > 640 - 64
  637.               @tale.mirror = true
  638.               @tale.x -= 64
  639.             end
  640.             @tale.y = tale_pos[1]
  641.             @tale.z = self.z + 1
  642.           when 1  # 中
  643.             @tale.dispose
  644.             @tale = nil
  645.           when 2  # 下
  646.             bitmap = RPG::Cache.windowskin(Fuki_v6_Setup::FUKI_SKIN_NAME)
  647.             rect = Rect.new(32, 64, 64, 32)
  648.             @tale.bitmap.blt(0, 0, bitmap, rect)
  649.             bitmap.dispose
  650.             @tale.x = tale_pos[0]
  651.             @tale.x += 8 if @tale.x < 64
  652.             if @tale.x > 640 - 64
  653.               @tale.mirror = true
  654.               @tale.x -= 64
  655.             end
  656.             @tale.y = tale_pos[1]
  657.             @tale.z = self.z# + 1
  658.           end
  659.         end
  660.       end
  661.     rescue
  662.       del_fukidasi
  663.       reset_window(width, height)
  664.     end
  665.   end
  666.   #--------------------------------------------------------------------------
  667.   # ○ 计算呼出对话框的位置
  668.   #--------------------------------------------------------------------------
  669.   def get_fuki_pos(width, height)
  670.     # 取得角色
  671.     @character = get_character($mes_id)
  672.     if @character == nil
  673.       # 角色不存在的情况下使用默认信息框
  674.       
  675.       del_fukidasi
  676.       reset_window(width, height)
  677.       return
  678.     end
  679.     # 处理坐标
  680.     x = (@character.real_x - $game_map.display_x + 64) * 32 / 128 - (width / 2)
  681.     # 为尽量显示在画面内而移动横坐标
  682.     if x + width > 640
  683.       x = 640 - width
  684.     elsif x < 0
  685.       x = 0
  686.     end
  687.     # 决定窗口位置
  688.     case $game_system.message_position
  689.     when 0  # 上
  690.       y = (@character.real_y - $game_map.display_y + 64) * 32 / 128 - height - Fuki_v6_Setup::CHARACTOR_HEIGHT + Fuki_v6_Setup::POP_SHIFT_TOP
  691.     when 1  # 中
  692.       x = (640 - width) / 2
  693.       y = (480 - height) / 2
  694.     when 2  # 下
  695.       y =  (@character.real_y - $game_map.display_y + 64) * 32 / 128 + 32 + Fuki_v6_Setup::POP_SHIFT_UNDER
  696.     end
  697.     # 纪录文章显示位置
  698.     @message_position = $game_system.message_position
  699.     if Fuki_v6_Setup::POS_FIX
  700.       case @message_position
  701.       when 0  # 上
  702.         if y <= 0
  703.           @message_position = 2
  704.           y =  (@character.real_y - $game_map.display_y + 64) * 32 / 128 + 32 + Fuki_v6_Setup::POP_SHIFT_UNDER
  705.         end
  706.       when 2  # 下
  707.         if y + height >= 480
  708.           @message_position = 0
  709.           y = (@character.real_y - $game_map.display_y + 64) * 32 / 128 - height - Fuki_v6_Setup::CHARACTOR_HEIGHT + Fuki_v6_Setup::POP_SHIFT_TOP
  710.         end
  711.       end
  712.     end
  713.     return [x, y]
  714.   end
  715.   #--------------------------------------------------------------------------
  716.   # ○ 计算尾部图标的位置
  717.   #--------------------------------------------------------------------------
  718.   def get_tale_pos
  719.     case @message_position
  720.     when 0  # 上
  721.       # 处理坐标
  722.       x = ( @character.real_x - $game_map.display_x + 64 ) * 32 / 128 - 8
  723.       y = self.y + self.height - 6
  724.     when 1  # 中
  725.       x = nil
  726.       y = nil
  727.     when 2  # 下
  728.       # 处理坐标
  729.       x = ( @character.real_x - $game_map.display_x + 64 ) * 32 / 128 - 8
  730.       y = self.y - 18
  731.     end
  732.     return [x, y]
  733.   end
  734.   #--------------------------------------------------------------------------
  735.   # ○ 设置角色半身像窗口
  736.   #--------------------------------------------------------------------------
  737.   def draw_msg_face
  738.     @face_sprite.dispose if @face_sprite != nil
  739.     # $mes_name为空时不显示
  740.     if $mes_name == nil or $mes_name == ""
  741.       return
  742.     else
  743.       # 设定变量
  744.       mes_name = $mes_name
  745.       if $game_temp.namebmp[mes_name] == nil
  746.         sFile = Fuki_v6_Setup::FACE_PIC_DIR + mes_name
  747.       else
  748.         sFile = Fuki_v6_Setup::FACE_PIC_DIR + $game_temp.namebmp[mes_name]
  749.       end
  750.       bitmap = Bitmap.new(sFile)
  751.       @pic_width = bitmap.width
  752.       @pic_height = bitmap.height
  753.       @face_sprite = Sprite.new
  754.       @face_sprite.x = self.x + 26
  755.       @face_sprite.x = self.x + self.width - @pic_width - 26 if @show_right
  756.       @face_sprite.y = self.y + self.height - @pic_height - 6
  757.       @face_sprite.bitmap = bitmap
  758.       @face_sprite.z = self.z + 3
  759.       @face_sprite.mirror = @show_right
  760.       @face_sprite.opacity = 0
  761.     end
  762.   end
  763.   #--------------------------------------------------------------------------
  764.   # ○ 释放呼出对话框
  765.   #--------------------------------------------------------------------------
  766.   def del_fukidasi
  767.     self.opacity = 0
  768.     self.x = 80
  769.     self.width = 480
  770.     self.height = 160
  771.     self.contents.dispose
  772.     self.contents = Bitmap.new(width - 32, height - 32)
  773.     self.pause = true
  774.     if @tale != nil
  775.       @tale.dispose
  776.       @tale = nil
  777.     end
  778.   end
  779.   #--------------------------------------------------------------------------
  780.   # ○ 取得角色
  781.   #     parameter : 参数
  782.   #--------------------------------------------------------------------------
  783.   def get_character(parameter)
  784.     # 参数分歧
  785.     case parameter
  786.     when nil
  787.       return events == nil
  788.     when -1  # 玩家
  789.       return $game_player
  790.     when 0   # 该事件
  791.       events = $game_map.events
  792.       # 循环 (地图事件)
  793.       for event in $game_map.events.values
  794.         # 如果找到了启动中的事件
  795.         if event.starting
  796.           @event_id = event.id
  797.         end
  798.       end
  799.       return events == nil ? nil : events[@event_id]
  800.     else     # 特定事件
  801.       events = $game_map.events
  802.       return events == nil ? nil : events[parameter]
  803.     end
  804.   end
  805.   #--------------------------------------------------------------------------
  806.   # ● 设定窗口位置和不透明度
  807.   #--------------------------------------------------------------------------
  808.   def reset_window(width = nil, height = nil)
  809.     if $game_temp.in_battle
  810.       self.y = 16
  811.     else
  812.       case $game_system.message_position
  813.       when 0  # 上
  814.         self.y = 16
  815.       when 1  # 中
  816.         if height != nil and width != nil
  817.           self.y = (480 - height) / 2 - 32
  818.           self.x = (640 - width) / 2
  819.           self.width = width
  820.           self.height = height
  821.           self.contents.dispose
  822.           self.contents = Bitmap.new(width - 32, height - 32)
  823.         else
  824.           self.y = 160
  825.         end
  826.       when 2  # 下
  827.         self.y = 304
  828.       end
  829.     end
  830.     self.opacity = 0
  831.     self.back_opacity = Fuki_v6_Setup::MES_OPACITY
  832.   end
  833.   #--------------------------------------------------------------------------
  834.   # ● 刷新画面
  835.   #--------------------------------------------------------------------------
  836.   def update
  837.     if $tale_need_dispose
  838.       del_fukidasi
  839.       $tale_need_dispose = false
  840.     end
  841.     super
  842.     update_fuki                 # 呼出模式下跟随事件移动
  843.     if @fade_in                 # 渐变的情况下
  844.       self.contents_opacity += 24
  845.       @pic_skin.opacity += 20
  846.       if @tale != nil
  847.         @face_sprite.opacity += 24 if @face_sprite != nil and !@face_sprite.disposed?
  848.         @tale.opacity += 20
  849.       end
  850.       @input_number_window.contents_opacity += 24 if @input_number_window != nil
  851.       @fade_in = false if self.contents_opacity == 255
  852.       return
  853.     end
  854.     if @contents_drawing        # 显示信息中的情况下
  855.       refresh_drawtext
  856.       return
  857.     end
  858.     update_input_number_window  # 输入数值的情况下
  859.     if @contents_showing_end    # 显示信息结束的情况下
  860.       if $game_temp.choice_max == 0 and @tale == nil
  861.         self.pause = true
  862.       else
  863.         self.pause = false
  864.       end
  865.       update_choose
  866.       return
  867.     end
  868.     if @fade_out == false and $game_temp.message_text != nil # 在渐变以外的状态下
  869.       @contents_showing = true
  870.       $game_temp.message_window_showing = true
  871.       reset_window
  872.       refresh_create
  873.       if @no_term_stop
  874.         self.visible = true        
  875.       else
  876.         @tale.opacity = 0 if @tale != nil
  877.         Graphics.frame_reset
  878.         self.visible = true
  879.         self.contents_opacity = 0
  880.         @input_number_window.contents_opacity = 0 if @input_number_window != nil
  881.         @fade_in = true
  882.       end
  883.       return
  884.     end
  885.     unless @no_term_stop # 没有可以显示的信息、但是窗口为可见的情况下
  886.       if self.visible
  887.         @fade_out = true
  888.         self.opacity -= 48
  889.         @face_sprite.opacity -= 48 if @face_sprite != nil and !@face_sprite.disposed?
  890.         @pic_skin.opacity -= 48 if @pic_skin != nil and !@pic_skin.disposed?
  891.         @tale.opacity -= 48 if @tale != nil and [email protected]?
  892.         if (@face_sprite == nil) or @face_sprite.disposed? or (@face_sprite.opacity == 0)
  893.           self.visible = false
  894.           @face_sprite.dispose if @face_sprite != nil
  895.           @pic_skin.dispose
  896.           @fade_out = false
  897.           $game_temp.message_window_showing = false
  898.         end
  899.         return
  900.       end
  901.     else
  902.       $game_temp.message_window_showing = false   
  903.     end
  904.   end
  905.   #--------------------------------------------------------------------------
  906.   # ● 释放
  907.   #--------------------------------------------------------------------------
  908.   def dispose
  909.     terminate_message
  910.     $game_temp.message_window_showing = false
  911.     @input_number_window.dispose if @input_number_window != nil
  912.     super
  913.   end
  914.   #--------------------------------------------------------------------------
  915.   # ● 信息结束处理
  916.   #--------------------------------------------------------------------------
  917.   def terminate_message
  918.     self.active = false
  919.     self.pause = false
  920.     self.index = -1
  921.     self.contents.clear
  922.     # 清除显示中标志
  923.     @contents_showing = false
  924.     @contents_showing_end = false
  925.     $mes_name = ""
  926.     # 呼叫信息调用
  927.     $game_temp.message_proc.call if $game_temp.message_proc != nil
  928.     # 清除文章、选择项、输入数值的相关变量
  929.     $game_temp.message_text = nil
  930.     $game_temp.message_proc = nil
  931.     $game_temp.choice_start = 99
  932.     $game_temp.choice_max = 0
  933.     $game_temp.choice_cancel_type = 0
  934.     $game_temp.choice_proc = nil
  935.     $game_temp.num_input_start = 99
  936.     $game_temp.num_input_variable_id = 0
  937.     $game_temp.num_input_digits_max = 0
  938.     # 释放金钱窗口
  939.     if @gold_window != nil
  940.       @gold_window.dispose
  941.       @gold_window = nil
  942.     end
  943.     @no_term_stop = false
  944.     @save_x = 0
  945.     @save_y = 0
  946.     @show_right = false
  947.     @show_name  = false
  948.     @face_width = 0
  949.     $tale_need_dispose = true if @tale != nil
  950.   end
  951.   #--------------------------------------------------------------------------
  952.   # ● ★信息结束处理★
  953.   #--------------------------------------------------------------------------
  954.   def terminate_messageX
  955.     self.active = false
  956.     self.pause = false
  957.     self.index = -1
  958.     # 清除显示中标志
  959.     @contents_showing = false
  960.     @contents_showing_end = false
  961.     # 呼叫信息调用
  962.     $game_temp.message_proc.call if $game_temp.message_proc != nil
  963.     # 清除文章、选择项、输入数值的相关变量
  964.     $game_temp.message_text = nil
  965.     $game_temp.message_proc = nil
  966.     @no_term_stop = true
  967.     @show_right = false
  968.     @show_name  = false
  969.     @face_width = 0
  970.   end
  971.   #--------------------------------------------------------------------------
  972.   # ● 刷新光标矩形
  973.   #--------------------------------------------------------------------------
  974.   def update_cursor_rect
  975.     if @index >= 0
  976.       n = $game_temp.choice_start + @index
  977.       self.cursor_rect.set(Fuki_v6_Setup::MES_FONT_SIZE / 2, n * (Fuki_v6_Setup::MES_FONT_SIZE + 4), @cursor_width, Fuki_v6_Setup::MES_FONT_SIZE + 4)
  978.       self.cursor_rect.x += @face_width unless @show_right
  979.       self.cursor_rect.x += Fuki_v6_Setup::MES_FONT_SIZE / 2 if @show_name
  980.     else
  981.       self.cursor_rect.empty
  982.     end
  983.   end
  984.   #--------------------------------------------------------------------------
  985.   # ● 获取文字颜色色
  986.   #     n : 文字颜色编号 (0~31)
  987.   #--------------------------------------------------------------------------
  988.   def text_color(n)
  989.     return normal_color if n > 31
  990.     x = (n % 8) * 16
  991.     y = 128 + (n / 8) * 16
  992.     return RPG::Cache.windowskin(Fuki_v6_Setup::FUKI_SKIN_NAME).get_pixel(x, y)
  993.   end
  994.   #--------------------------------------------------------------------------
  995.   # ● 取得普通文字色
  996.   #--------------------------------------------------------------------------
  997.   def normal_color
  998.     nil_color = Color.new(0,0,0,255)
  999.     return Fuki_v6_Setup::FUKI_COLOR if Fuki_v6_Setup::FUKI_COLOR != nil_color
  1000.     return nil_color
  1001.   end
  1002.   #--------------------------------------------------------------------------
  1003.   # ● 获取头像宽度
  1004.   #--------------------------------------------------------------------------
  1005.   def get_face_width(face_name)
  1006.     return if $mes_name == ""
  1007.     filename = Fuki_v6_Setup::FACE_PIC_DIR + face_name
  1008.     bitmap = Bitmap.new(filename)
  1009.     @face_width = bitmap.width + Fuki_v6_Setup::MES_FONT_SIZE
  1010.     bitmap.dispose
  1011.   end
  1012.   #--------------------------------------------------------------------------
  1013.   # ● 描绘物品
  1014.   #     item : 物品
  1015.   #--------------------------------------------------------------------------
  1016.   def draw_icon(item, x, y)
  1017.     return if item == nil
  1018.     bitmap = RPG::Cache.icon(item.icon_name)
  1019.     self.contents.blt(x + 4, y, bitmap, Rect.new(0, 0, 24, 24))
  1020.     color = self.contents.font.color.clone
  1021.     self.contents.font.color = text_color(1)
  1022.     self.contents.draw_text(x + 28, y, self.contents.text_size(item.name).width + 5, 24, item.name)
  1023.     self.contents.font.color = color
  1024.     @dx += self.contents.text_size(item.name).width
  1025.   end
  1026.   #--------------------------------------------------------------------------
  1027.   # ● 图形的描绘
  1028.   #     actor : 角色
  1029.   #     x     : 描画目标 X 坐标
  1030.   #     y     : 描画目标 Y 坐标
  1031.   #--------------------------------------------------------------------------
  1032.   def draw_actor_graphic(actor, x, y)
  1033.     bitmap = RPG::Cache.character(actor.character_name, actor.character_hue)
  1034.     cw = bitmap.width / 4
  1035.     ch = bitmap.height / 4
  1036.     src_rect = Rect.new(0, 0, cw, ch)
  1037.     self.contents.blt(x, y - 4, bitmap, src_rect)
  1038.     color = self.contents.font.color.clone
  1039.     self.contents.font.color = text_color(1)
  1040.     self.contents.draw_text(x + 32, y, self.contents.text_size(actor.name).width + 5, 24, actor.name)
  1041.     self.contents.font.color = color
  1042.     @dx += self.contents.text_size(actor.name).width
  1043.   end
  1044.   #--------------------------------------------------------------------------
  1045.   # ● 刷新呼出对话框
  1046.   #--------------------------------------------------------------------------
  1047.   def update_fuki
  1048.     if @tale != nil
  1049.       pos = get_fuki_pos(self.width, self.height)
  1050.       self.x = pos[0]
  1051.       self.y = pos[1]
  1052.       tale_pos = get_tale_pos
  1053.       @tale.mirror = false
  1054.       @tale.x = tale_pos[0]
  1055.       @tale.x += 8 if @tale.x < 64
  1056.       if @tale.x > 640 - 64
  1057.         @tale.mirror = true
  1058.         @tale.x -= 64
  1059.       end
  1060.       @tale.y = tale_pos[1]
  1061.       @pic_skin.x = self.x + 2
  1062.       @pic_skin.y = self.y + 2
  1063.       if @face_sprite != nil and !@face_sprite.disposed?
  1064.         @face_sprite.x = self.x + 26
  1065.         @face_sprite.x = self.x + self.width - @pic_width - 26 if @show_right
  1066.         @face_sprite.y = self.y + self.height - @pic_height - 6
  1067.       end
  1068.     end
  1069.   end
  1070.   #--------------------------------------------------------------------------
  1071.   # ● 刷新数字输入框
  1072.   #--------------------------------------------------------------------------
  1073.   def update_input_number_window
  1074.     if @input_number_window != nil
  1075.       @input_number_window.update
  1076.       # 确定
  1077.       if Input.trigger?(Input::C)
  1078.         $game_system.se_play($data_system.decision_se)
  1079.         $game_variables[$game_temp.num_input_variable_id] = @input_number_window.number
  1080.         # 释放输入数值窗口
  1081.         @input_number_window.dispose
  1082.         @input_number_window = nil
  1083.         $game_map.need_refresh = true
  1084.         terminate_message
  1085.       end
  1086.       return
  1087.     end
  1088.   end
  1089.   #--------------------------------------------------------------------------
  1090.   # ● 刷新选择输入
  1091.   #--------------------------------------------------------------------------
  1092.   def update_choose
  1093.     if Input.trigger?(Input::B)
  1094.       if $game_temp.choice_max > 0 and $game_temp.choice_cancel_type > 0
  1095.         $game_system.se_play($data_system.cancel_se)
  1096.         $game_temp.choice_proc.call($game_temp.choice_cancel_type - 1)
  1097.         terminate_message
  1098.       end
  1099.     end
  1100.     if Input.trigger?(Input::C)
  1101.       if $game_temp.choice_max > 0
  1102.         $game_system.se_play($data_system.decision_se)
  1103.         $game_temp.choice_proc.call(self.index)
  1104.       end
  1105.       terminate_message
  1106.     end
  1107.   end
  1108. end
复制代码

Lv3.寻梦者

梦石
0
星屑
3795
在线时间
1578 小时
注册时间
2006-5-5
帖子
2742
2
发表于 2012-6-17 13:39:29 | 只看该作者
最简单的方法是每行别打那么多字。
第二个解决方法就是修改定义,没记错的话是以下两处
  1. self.x = 80
  2. #   self.width = 480
  3. #   self.height = 160
  4. # 还有
  5. #        self.x = 80
  6. #        if @face_file == nil
  7. #         self.width = 480
复制代码
步兵中尉
回复

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
50
在线时间
37 小时
注册时间
2009-10-4
帖子
45
3
 楼主| 发表于 2012-6-17 14:17:16 | 只看该作者
本帖最后由 zdb123 于 2012-6-17 14:17 编辑
步兵中尉 发表于 2012-6-17 13:39
最简单的方法是每行别打那么多字。
第二个解决方法就是修改定义,没记错的话是以下两处 ...


额 是把哪里换成哪里?@步兵中尉
回复

使用道具 举报

Lv3.寻梦者

梦石
0
星屑
1840
在线时间
1482 小时
注册时间
2010-10-22
帖子
1026
4
发表于 2012-6-17 14:48:15 | 只看该作者
这个问题我也遇到了,一般来说如果在对话发生时按确定键按得太急的话就有可能会出现这个问题,个人表示即便是增加对话框的宽度也不能完全解决,目前的解决方法是在每行字的后面加几个空格。

  1.       # 取得窗口尺寸
  2.       get_windowsize
  3.       w = @w + 45
  4.       h = @h * (self.contents.font.size + 4) + 36
复制代码

点评

额 谢谢你的启发 我吧w=@w+45换成 +60了 修复了 谢谢  发表于 2012-6-17 15:59
【2022.06.03】原本以为已经不可能再找回来的东西重新找回来了,原本一直念念不忘的坑终于再一次拿起铲子了。一别竟近10年,你好,我的世界我的梦。
回复

使用道具 举报

Lv3.寻梦者

梦石
0
星屑
3795
在线时间
1578 小时
注册时间
2006-5-5
帖子
2742
5
发表于 2012-6-17 15:03:19 | 只看该作者
779~781行啊!
第一个是横坐标,第二个是对话框宽度,第三个是高度
步兵中尉
回复

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
50
在线时间
37 小时
注册时间
2009-10-4
帖子
45
6
 楼主| 发表于 2012-6-17 15:56:07 | 只看该作者
步兵中尉 发表于 2012-6-17 15:03
779~781行啊!
第一个是横坐标,第二个是对话框宽度,第三个是高度

一样没用额 只有$mes_id = nil 时修改 $mes_id 不等于 nil  时不修改

点评

我也用过+60,只是觉得太长不大好看,呵呵。  发表于 2012-6-17 16:03
回复

使用道具 举报

头像被屏蔽

Lv1.梦旅人 (禁止发言)

梦石
0
星屑
45
在线时间
0 小时
注册时间
2012-6-18
帖子
66
7
发表于 2012-6-18 01:16:21 | 只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
回复

使用道具 举报

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

本版积分规则

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

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

GMT+8, 2024-6-16 08:18

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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