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

Project1

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

[已经解决] 有没有办法像逆转裁判一样在事件中途打开道具栏?

[复制链接]

Lv1.梦旅人

梦石
0
星屑
50
在线时间
160 小时
注册时间
2011-3-26
帖子
25
跳转到指定楼层
1
发表于 2013-1-6 09:58:44 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

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

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

x
我试过用并行处理实现“当XX键被按下时,打开道具栏”。但是这样并不能像是逆转裁判一样在会话的途中打开道具栏。
请问有没有更好的方法能实现逆转裁判一样的功能?

Lv2.观梦者 (暗夜天使)

梦石
0
星屑
266
在线时间
2355 小时
注册时间
2009-3-13
帖子
2309

贵宾

2
发表于 2013-1-6 10:52:15 | 只看该作者
事件——信息——物品选择处理,默认的只能选择重要物品,使用时请确保可以选择重要物品在菜单中
是可以使用的(即使使用后也没有什么效果)。

评分

参与人数 1梦石 +1 收起 理由
迷糊的安安 + 1 认可答案 附赠66RPG提供的精美好人卡一张^^.

查看全部评分

回复 支持 反对

使用道具 举报

Lv5.捕梦者 (暗夜天使)

只有笨蛋才会看到

梦石
1
星屑
21095
在线时间
9345 小时
注册时间
2012-6-19
帖子
7107

开拓者短篇九导演组冠军

3
发表于 2013-1-26 20:31:19 | 只看该作者
本帖最后由 喵呜喵5 于 2014-8-1 18:29 编辑
  1. #===================================
  2. # by bStefan aka. regendo
  3. # by request from AABattery
  4. # : [url]http://www.rpgmakervxace.net/index.php?/user/608-aabattery/[/url]
  5. # please give credit if used
  6. # for use with RMVX ACE
  7. #===================================
  8. # Call Scene_Menu while a message
  9. # : is being displayed
  10. #===================================
  11. # implement over Main
  12. #===================================
  13. # customize:
  14. # : add Scenes you don't want the
  15. # : script to happen to NOCALLMENU
  16. # : (like Scene_Battle, which would
  17. # : be really annoying)
  18. #===================================

  19. module Regendo
  20.   
  21.   unless @scripts
  22.     @scripts = Hash.new
  23.     def self.contains?(key)
  24.       @scripts[key] == true
  25.     end
  26.   end
  27.   @scripts["Menu_during_Message"] = true
  28.   
  29.   module Menu_during_Message
  30.    
  31.     #=======
  32.     #CONFIG
  33.     #=======
  34.     NOCALLMENU = [Scene_Battle] #scenes in which call_menu shall not work.
  35.         BUTTON = Input::B #which button will trigger the menu?
  36.   end
  37. end
  38.   
  39. class Window_Message < Window_Base
  40.   BUTTON = Regendo::Menu_during_Message::BUTTON
  41.   NOCALLMENU = Regendo::Menu_during_Message::NOCALLMENU
  42.   alias update_old update
  43.   def update
  44.     update_old
  45.     call_menu if Input.trigger?(BUTTON) && !forbidden_scene_by_regendo
  46.   end
  47.   
  48.   def call_menu
  49.     Sound.play_ok
  50.     SceneManager.call(Scene_Menu)
  51.     Window_MenuCommand::init_command_position
  52.   end
  53.   
  54.   def input_pause
  55.     self.pause = true
  56.     wait(10)
  57.         case BUTTON
  58.         when Input::B
  59.           Fiber.yield until Input.trigger?(:C)
  60.         when Input::C
  61.           Fiber.yield until Input.trigger?(:B)
  62.         else
  63.       Fiber.yield until Input.trigger?(:B) || Input.trigger?(:C)
  64.         end
  65.     Input.update
  66.     self.pause = false
  67.   end
  68.   
  69.   def forbidden_scene_by_regendo
  70.     if NOCALLMENU
  71.       a = NOCALLMENU.any? do |scene|
  72.         SceneManager.scene_is?(scene)
  73.       end
  74.       a
  75.     else
  76.       false
  77.     end
  78.   end
  79. end
复制代码
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
95
在线时间
211 小时
注册时间
2011-8-16
帖子
300
4
发表于 2013-1-26 21:13:42 | 只看该作者
好无聊
  1. #===============翻译=================
  2. #来自:bStefan aka. regendo
  3. #来自:request from AABattery
  4. #网址:http://www.rpgmakervxace.net/index.php?/user/608-aabattery/
  5. #如果你用VX ACE使用该脚本请给好评
  6. #==================================================
  7. # 当信息框显示的时候呼叫菜单
  8. #==================================================
  9. # 作用于Main后
  10. #==================================================
  11. # 定制:
  12. # :在你不想添加场景的时候
  13. # :脚本发生无法呼叫菜单的时候
  14. # :比如场景战斗, 那真让人讨厌)
  15. #==================================================
  16. module Regendo
  17.    unless @scripts
  18.     @scripts = Hash.new
  19.     def self.contains?(key)
  20.       @scripts[key] == true
  21.     end
  22.   end
  23.   @scripts["Menu_during_Message"] = true
  24.    module Menu_during_Message

  25. #==================================================
  26. #配置
  27. #==================================================
  28.     NOCALLMENU = [Scene_Battle] #scenes in which call_menu shall not work.
  29.         BUTTON = Input::B #which button will trigger the menu?
  30.   end
  31. end
  32. #==================================================
  33. #Window_Message
  34. #==================================================
  35. class Window_Message < Window_Base
  36.   BUTTON = Regendo::Menu_during_Message::BUTTON
  37.   NOCALLMENU = Regendo::Menu_during_Message::NOCALLMENU
  38.   alias update_old update
  39. #----------------------------------------------------------------------------------------------------
  40. #刷新
  41. #----------------------------------------------------------------------------------------------------
  42.   def update
  43.     update_old
  44.     call_menu if Input.trigger?(BUTTON) && !forbidden_scene_by_regendo
  45.   end
  46. #----------------------------------------------------------------------------------------------------
  47. #呼叫菜单
  48. #----------------------------------------------------------------------------------------------------  
  49.   def call_menu
  50.     Sound.play_ok
  51.     SceneManager.call(Scene_Menu)
  52.     Window_MenuCommand::init_command_position
  53.   end
  54. #----------------------------------------------------------------------------------------------------
  55. #暂停显示
  56. #----------------------------------------------------------------------------------------------------  
  57.   def input_pause
  58.     self.pause = true
  59.     wait(10)
  60.         case BUTTON
  61.         when Input::B
  62.           Fiber.yield until Input.trigger?(:C)
  63.         when Input::C
  64.           Fiber.yield until Input.trigger?(:B)
  65.         else
  66.       Fiber.yield until Input.trigger?(:B) || Input.trigger?(:C)
  67.         end
  68.     Input.update
  69.     self.pause = false
  70.   end
  71. #----------------------------------------------------------------------------------------------------
  72. #??被禁止的场景
  73. #----------------------------------------------------------------------------------------------------  
  74.   def forbidden_scene_by_regendo
  75.     if NOCALLMENU
  76.       a = NOCALLMENU.any? do |scene|
  77.         SceneManager.scene_is?(scene)
  78.       end
  79.       a
  80.     else
  81.       false
  82.     end
  83.   end
  84. end
复制代码
RPGMaker 脚本/学习交流群:143356012
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
170
在线时间
227 小时
注册时间
2011-5-19
帖子
736
5
发表于 2013-1-27 11:57:36 | 只看该作者
脚本看不懂……
但沙发的说法是木有错滴……
(神马?你想用回复药?我不会……)

评分

参与人数 1星屑 -20 收起 理由
Mic_洛洛 -20 你不会?于是就来灌水了?

查看全部评分

休息中……
回复 支持 反对

使用道具 举报

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

本版积分规则

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

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

GMT+8, 2024-5-31 02:21

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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