CommonFun

calcDamage / calcBuff explorer

2 formulas listed.

CommonFun.calcBuff_360160 mapped buffs · 5 skills
function CommonFun.calcBuff_360(srcUser, targetUser, a, b, c, d, lv)
  if srcUser == nil or targetUser == nil then
    return 0
  end
  local BlindAtk = srcUser:GetProperty("BlindAtk")
  local BlindDef2 = targetUser:GetProperty("BlindDef")
  local BlindDam = 1 + BlindAtk - BlindDef2
  if BlindDam <= 0 then
    BlindDam = 0
  end
  local StateAtk = srcUser:GetProperty("StateAtk")
  local StateDef2 = targetUser:GetProperty("StateDef")
  local StateDam = (1 + StateAtk) * (1 - StateDef2)
  if StateDam <= 0 then
    StateDam = 0
  end
  local A = 0
  local Num1 = srcUser:GetRunePoint(41006)
  local SkillAttr = srcUser:GetCurSkillAtkAttr()
  if SkillAttr == 4 then
    A = (lv * a + b) * BlindDam * StateDam * Num1
  end
  if A <= 0 then
    return 0
  end
  return A
end
CommonFun.calcBuff_360020 mapped buffs · 1 skills
function CommonFun.calcBuff_3600(srcUser, targetUser, a, b, c, d, lv)
  if srcUser == nil or targetUser == nil then
    return 0
  end
  local skilllv_1 = srcUser:GetLernedSkillLevel(103180)
  local SlowAtk = srcUser:GetProperty("SlowAtk")
  local SlowDef2 = targetUser:GetProperty("SlowDef")
  local SlowDam = 1 + SlowAtk - SlowDef2
  if SlowDam <= 0 then
    SlowDam = 0
  end
  local StateAtk = srcUser:GetProperty("StateAtk")
  local StateDef2 = targetUser:GetProperty("StateDef")
  local StateDam = (1 + StateAtk) * (1 - StateDef2)
  if StateDam <= 0 then
    StateDam = 0
  end
  local A = (skilllv_1 * a + b) * SlowDam * StateDam * CommonFun.calcAttrSlowRate(srcUser, targetUser)
  if A <= 0 then
    return 0
  end
  return A
end