pros-plan-for-elves/Scripts/_.32.rb

74 lines
3 KiB
Ruby
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#==============================================================================
#◆VXAce用 Ys_封印されたコマンドの非表示
#------------------------------------------------------------------------------
#【最終更新日時】 2013/07/12
#【作者】杉村 祐介
#【サイト】http://hgfactory2011.blog.fc2.com/
#==============================================================================
#
# 【用途】
# イベントや装備などで封印された「たたかう」「ぼうぎょ」コマンドや、
# 個別のスキルをグレー表示でなく完全削除します。
# このスクリプトを導入後、対象キャラのコマンド封印を選んで下さい。
#
#==============================================================================
#==============================================================================
# ■ Window_ActorCommand
#------------------------------------------------------------------------------
#  バトル画面で、アクターの行動を選択するウィンドウです。
#==============================================================================
class Window_ActorCommand < Window_Command
#--------------------------------------------------------------------------
# ● コマンドリストの作成
#--------------------------------------------------------------------------
def make_command_list
return unless @actor
add_attack_command
add_skill_commands
add_guard_command
add_item_command
end
#--------------------------------------------------------------------------
# ● 攻撃コマンドをリストに追加
#--------------------------------------------------------------------------
def add_attack_command
if @actor.attack_usable?
add_command(Vocab::attack, :attack, @actor.attack_usable?)
end
end
#--------------------------------------------------------------------------
# ● スキルコマンドをリストに追加
#--------------------------------------------------------------------------
def add_skill_commands
@actor.added_skill_types.sort.each do |stype_id|
if @actor.skill_type_sealed?(stype_id)
else
name = $data_system.skill_types[stype_id]
add_command(name, :skill, true, stype_id)
end
end
end
#@actor.skill_type_sealed?(stype_id)
#--------------------------------------------------------------------------
# ● 防御コマンドをリストに追加
#--------------------------------------------------------------------------
def add_guard_command
if @actor.guard_usable?
add_command(Vocab::guard, :guard, @actor.guard_usable?)
end
end
end
class Window_SkillList < Window_Selectable
#--------------------------------------------------------------------------
# ● スキルリストの作成
#--------------------------------------------------------------------------
def make_item_list
@data = @actor ? @actor.skills.select {|skill| include?(skill) && !@actor.skill_sealed?(skill.id) } : []
end
end