if $ukra_system == nil $ukra_system = {} end $ukra_system[6] = true #============================================================================== # ○ 超速攻 #============================================================================== module UKRA_006 #------------------------------------------------------------------------- # 正規表現 #------------------------------------------------------------------------- SUPERHASTE = /\\superhaste/i GUARDTIME = /\\guardtiming/i FASTRUSH = /\\fastrush/i LASTACTION = /\\lastaction/i #------------------------------------------------------------------------- # ○ 超速攻:防御行動が行われるよりも速く行動します。 #------------------------------------------------------------------------- def superhaste n = false @note.gsub(/#{SUPERHASTE}/) do n = true end return n end #------------------------------------------------------------------------- # ○ 防御タイミング攻撃:防御と同じ優先度で行動します。 #------------------------------------------------------------------------- def guardtiming n = false @note.gsub(/#{GUARDTIME}/) do n = true end return n end #------------------------------------------------------------------------- # ○ ファストラッシュ:「ターン内先制」効果と同じ優先度で行動します。 #------------------------------------------------------------------------- def fastrush n = false @note.gsub(/#{FASTRUSH}/) do n = true end return n end #------------------------------------------------------------------------- # ○ ラストアクション:ターン内で最も遅く行動します。 #------------------------------------------------------------------------- def lastaction n = false @note.gsub(/#{LASTACTION}/) do n = true end return n end end class RPG::UsableItem < RPG::BaseItem include UKRA_006 end class Game_BattleAction #-------------------------------------------------------------------------- # ○ 超速攻判定 #-------------------------------------------------------------------------- def superhaste? for obj in [skill, item].compact return true if obj.superhaste end return false end #-------------------------------------------------------------------------- # ○ 防御タイミング行動判定 #-------------------------------------------------------------------------- def guardtiming? for obj in [skill, item].compact return true if obj.guardtiming end return false end #-------------------------------------------------------------------------- # ○ 電光石火判定 #-------------------------------------------------------------------------- def fastrush? for obj in [skill, item].compact return true if obj.fastrush end return false end #-------------------------------------------------------------------------- # ○ ラストアクション判定 #-------------------------------------------------------------------------- def lastaction? for obj in [skill, item].compact return true if obj.lastaction end return false end #-------------------------------------------------------------------------- # ● 行動スピードの決定 #-------------------------------------------------------------------------- alias ukra006_ba_make_speed make_speed def make_speed ukra006_ba_make_speed @speed += 3000 if superhaste? @speed += 2000 if guardtiming? @speed += 1000 if fastrush? @speed = 0 if lastaction? end end