adiktuzmiko icon

Slip Damage EX Draft Fix

adiktuzmiko | PRO | 12/17/15 04:22:29 AM UTC | 0 ⭐ | 251 👁️ | Never ⏰ | []
Ruby |

1.16 KB

|

None

|

0 👍

/

0 👎

  #Draft of possible fix for battler transformation problem
  #Put this below the original script
 
  #--------------------------------------------------------------------------
  # ? Overwrite method: regenerate_hp_battle
  #--------------------------------------------------------------------------
  def regenerate_hp_battle
    damage = 0
    if actor?
      for equip in equips
        next if equip.nil?
        b = self
        damage += eval(equip.slip_hp_prog_eval) unless equip.slip_hp_prog_eval.nil?
      end
      for state in states
        next if state.nil?
        clear_slip_states if @state_cause == nil
        damage += @slip_hp_damage[state.id]
        a = @state_cause[state.id]
        b = self
        damage += eval(state.slip_hp_prog_eval) unless state.slip_hp_prog_eval.nil?
      end
    elsif enemy?
      for state in states
        next if state.nil?
        clear_slip_states if @state_cause == nil
        damage += @slip_hp_damage[state.id]
        a = @state_cause[state.id]
        b = self
        damage += eval(state.slip_hp_prog_eval) unless state.slip_hp_prog_eval.nil?
      end
    end
    return damage
  end

Comments