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

Project1

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

[已经解决] 显示LOGO与FUKI极度简化版的问题

[复制链接]

Lv3.寻梦者

梦石
0
星屑
2383
在线时间
647 小时
注册时间
2013-8-11
帖子
858
跳转到指定楼层
1
发表于 2014-7-11 13:59:42 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

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

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

x
又遇到麻烦了_(:з」∠)_
发现有“显示LOGO”脚本在FUKI就不起效果了怎么回事Orz
RUBY 代码复制
  1. #==============================================================================
  2. # 本脚本来自[url]www.66RPG.com[/url],使用和转载请保留此信息
  3. #==============================================================================
  4.  
  5. #--------------------------------------------------------------------------
  6. # 开始菜单前加入图片
  7. # 作者 : 擇
  8. #--------------------------------------------------------------------------
  9.  
  10. class Scene_logo
  11.   #--------------------------------------------------------------------------
  12.   # ● 住处理
  13.   #--------------------------------------------------------------------------
  14.   def main
  15.     # 播放LOGO音效
  16.     Audio.se_play("Audio/SE/001-System01.ogg")
  17.     # 生成标题图形
  18.     @sprite = Sprite.new
  19.     @sprite.bitmap = RPG::Cache.title("Logo合并")
  20.     # 生成位置为画面中央
  21.     @sprite.x = (640 - @sprite.bitmap.width) / 2
  22.     @sprite.y = (480 - @sprite.bitmap.height) / 2
  23.     # 透明度(0为完全透明)
  24.     @sprite.opacity = 255
  25.     # 执行过渡
  26.     Graphics.transition
  27.     # 主循环
  28.     loop do
  29.       # 刷新游戏画面
  30.       Graphics.update
  31.       # 刷新输入信息
  32.       Input.update
  33.       # 刷新画面
  34.       update
  35.       # 如果画面被切换就中断循环
  36.       if $scene != self
  37.         break
  38.       end
  39.     end
  40.     # 装备过渡
  41.     Graphics.freeze
  42.     # 释放标题图形
  43.     @sprite.bitmap.dispose
  44.     @sprite.dispose
  45.   end
  46.   #--------------------------------------------------------------------------
  47.   # ● 刷新画面
  48.   #--------------------------------------------------------------------------
  49.   def update
  50.     # 按下 A,B,C,下,上,左,右 键的情况下
  51.     if Input.trigger?(Input::A)
  52.       refresh
  53.     end
  54.     if Input.trigger?(Input::B)
  55.       refresh
  56.     end
  57.     if Input.trigger?(Input::C)
  58.       refresh
  59.     end
  60.     if Input.trigger?(Input::DOWN)
  61.       refresh
  62.     end
  63.     if Input.trigger?(Input::UP)
  64.       refresh
  65.     end
  66.     if Input.trigger?(Input::RIGHT)
  67.       refresh
  68.     end
  69.     if Input.trigger?(Input::LEFT)
  70.       refresh
  71.     end
  72.     def refresh
  73.       $scene = Scene_Title.new
  74.       Audio.se_stop
  75.     end
  76.   end
  77. end
  78. #==============================================================================
  79. # ■ Main
  80. #------------------------------------------------------------------------------
  81. #  各定义结束后、从这里开始实际处理。
  82. #==============================================================================
  83. begin
  84.   # 准备过渡
  85.   # 设置系统默认字体
  86.   Font.default_name = (["黑体"])
  87.   Graphics.freeze
  88.   # 生成场景对像 (标题画面)
  89.   $scene = Scene_logo.new
  90.   # $scene 为有效的情况下调用 main 过程
  91.   while $scene != nil
  92.     $scene.main
  93.   end
  94.   # 淡入淡出
  95.   Graphics.transition(90)
  96.   rescue Errno::ENOENT
  97.   # 补充 Errn:ENOENT 以外错误
  98.   # 无法打开文件的情况下、显示信息后结束
  99.   filename = $!.message.sub("No such file or directory - ", "")
  100.   print("找不到文件 #{filename}。 ")
  101. end
  102.  
  103.  
  104. #==============================================================================
  105. # 本脚本来自[url]www.66RPG.com[/url],使用和转载请保留此信息
  106. #==============================================================================



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

然后真切地等待帮助...=w=

评分

参与人数 1星屑 +35 收起 理由
︶ㄣ牛排ぶ + 35 手动认可奖励

查看全部评分


Engine:RPG Maker XP
Ability:

帅的人在默默填坑,而丑的人在疯狂灌水。

Lv1.梦旅人

梦石
0
星屑
58
在线时间
85 小时
注册时间
2014-1-31
帖子
854
2
发表于 2014-7-11 14:02:14 | 只看该作者
本帖最后由 SherryX 于 2014-7-11 14:09 编辑

脚本我果断是有的,不过不是一个作者。作者禁止2次发布,那我只好私下发了。

点评

刚搜了一下FUKI脚本修改了Scene_Map的main方法,并且替代了Window_Message,所以可能会带来冲突。  发表于 2014-7-11 14:13
谢谢了 我还是想知道问题出在哪里...实在不行...到时候再说吧_(:з」∠)_  发表于 2014-7-11 14:11
或许你试试我的脚本看看FUKI的效果还有没有?  发表于 2014-7-11 14:11
我又没说没有= =,就是两个脚本放一起,FUKI脚本就没效果了  发表于 2014-7-11 14:08
显示LOGO脚本我有可以给你...  发表于 2014-7-11 14:07
回复 支持 反对

使用道具 举报

Lv2.观梦者

虚構歪曲

梦石
0
星屑
339
在线时间
1197 小时
注册时间
2010-12-18
帖子
3928

贵宾

3
发表于 2014-7-17 12:23:01 | 只看该作者
UI> 请把 logo 脚本置于 fuki 下端,不过这玩意写法也是蛋疼无比。你说没事偏要搞个画面类还要改初始画面类干啥。

点评

就是放置于下端的_(:з」∠)_,不过还是没用,已经没事了,用事件解决了  发表于 2014-7-17 13:41

评分

参与人数 2星屑 +130 收起 理由
︶ㄣ牛排ぶ + 100 认可答案
进击の虎叔 + 30 认可答案

查看全部评分

回复 支持 反对

使用道具 举报

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

本版积分规则

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

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

GMT+8, 2024-9-21 22:34

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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