Project1
标题:
如何制造一个禁止在战斗中使用物品的状态
[打印本页]
作者:
pinko
时间:
2009-8-19 07:42
标题:
如何制造一个禁止在战斗中使用物品的状态
就类似于无法使用魔法一样。
作者:
「旅」
时间:
2009-8-19 09:08
class Scene_Battle
alias lv07_update_phase3_basic_command update_phase3_basic_command
def update_phase3_basic_command
if Input.trigger?(Input::C) and @jionglansan
case @actor_command_window.index
when 3
$game_system.se_play($data_system.buzzer_se)
return
end
end
lv07_update_phase3_basic_command
return if @active_battler == nil or @active_battler.states == []
$jionglansan = true
for i in @active_battler.states
if $data_states[i].name.include?("☆不可物品")
@actor_command_window.draw_item(3, Color.new(255, 255, 255, 128))
$jionglansan = false
@jionglansan = true
return
else
@jionglansan = false
@actor_command_window.draw_item(3, Color.new(255, 255, 255, 255))
end
end
$jionglansan = false
end
alias lv07_phase3_next_actor phase3_next_actor
def phase3_next_actor
lv07_phase3_next_actor
@jionglansan = false
@actor_command_window.draw_item(3, Color.new(255, 255, 255, 255))
end
end
module RPG
class State
def name
if @name.include?("☆不可物品") and !$jionglansan
return @name.split("☆不可物品")[0]
else
return @name
end
end
end
end
复制代码
只要在状态名加上 ☆不可物品 就可以了~~~
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1