soulsaga 发表于 2021-9-1 16:35
不懂..确定键无效做什么用?
taeckle 发表于 2021-9-1 16:38
好吧,我们换一个结果:
如果在某个Scene_XXX场景中(比如Scene_Battle)的当前界面只要有显示文章对话框( ...
class << Input alias scene_trigger? trigger? def trigger?(key=0) if $scene.is_a?(Scene_Battle) a=$scene.instance_variable_get("@message_window") return false if a and key==Input::C and a and a.visible end scene_trigger?(key) end end
taeckle 发表于 2021-9-1 18:50
大神请问下你上面代码里的这句class
soulsaga 发表于 2021-9-1 18:57
这个是我问其他大神知道的..
ruby 中的 class
if !@message_window.visible and Input.trigger?(Input::F9)
# 强制行动的角色存在、
# 并且战斗事件正在执行的情况下
if $game_temp.forcing_battler == nil and
$game_system.battle_interpreter.running?
return
end
# 我不确定你的快捷键用来做什么,但是按插在这里是相对靠谱的选择
# 回合分支
case @phase
when 1 # 自由战斗回合
欢迎光临 Project1 (https://rpg.blue/) | Powered by Discuz! X3.1 |