
Dunk Slamming
Lv 1Attack
Deals (M.Atk1000%) wind M.Dmg to the target
Range: 6
Formula
1function CommonFun.calcDamage_9005(srcUser, targetUser, params, damageParam, logger)
2 local Str = srcUser:GetProperty("Str")
3 local Dex = srcUser:GetProperty("Dex")
4 local Luk = srcUser:GetProperty("Luk")
5 local Atk = srcUser:GetProperty("Atk")
6 local AtkPer = srcUser:GetProperty("AtkPer")
7 local DamIncrease = srcUser:GetProperty("DamIncrease")
8 local BaseLv = srcUser.BaseLv
9 local IgnoreDef = 0
10 local IgnoreDef1 = srcUser:GetProperty("IgnoreDef")
11 local IgnoreDef2 = srcUser:GetProperty("IgnoreEquipDef")
12 if targetUser.boss or targetUser.mini then
13 IgnoreDef = IgnoreDef1
14 else
15 IgnoreDef = IgnoreDef1 + IgnoreDef2
16 end
17 if 1 <= IgnoreDef then
18 IgnoreDef = 1
19 end
20 local Refine = srcUser:GetProperty("Refine")
21 local count = params.hitedCount
22 if count <= 1 then
23 count = 1
24 end
25 local Def2 = targetUser:GetProperty("Def")
26 local DefPer2 = targetUser:GetProperty("DefPer")
27 local Vit2 = targetUser:GetProperty("Vit")
28 local VitPer2 = targetUser:GetProperty("VitPer")
29 local DamReduc2 = CommonFun.calcDamReDuc(srcUser, targetUser)
30 local RefineDamReduc = CommonFun.calcRefineDamReduc(srcUser, targetUser)
31 local damChangePer = damageParam.damChangePer
32 local raceparam = CommonFun.CalcRaceParam(srcUser, targetUser, params, damageParam, logger)
33 local bodyparam = CommonFun.CalcBodyParam(srcUser, targetUser, params, damageParam, logger)
34 local elementparam = CommonFun.CalcElementParam(srcUser, targetUser, params, damageParam, logger)
35 local bossparam = CommonFun.CalcBossParam(srcUser, targetUser, params, damageParam, logger)
36 local raceparam2 = CommonFun.CalcRaceParam2(srcUser, targetUser, params, damageParam, logger)
37 local bodyparam2 = CommonFun.CalcBodyParam2(srcUser, targetUser, params, damageParam, logger)
38 local elementparam2 = CommonFun.CalcElementParam2(srcUser, targetUser, params, damageParam, logger)
39 local bossparam2 = CommonFun.CalcBossParam2(srcUser, targetUser, params, damageParam, logger)
40 local BaseAtk = Str * 2 + math.floor(Str * Str / 100) + math.floor(Dex / 5) + math.floor(Luk / 5)
41 local AtkFinal = ((Atk - BaseAtk) * (1 + AtkPer) * CommonFun.ShapeCorrection(srcUser, targetUser) * bodyparam * elementparam * elementparam2 + BaseAtk) * raceparam * bossparam * bossparam2
42 local DefReduc = CommonFun.CalcDef(srcUser, targetUser)
43 local A = ((AtkFinal * DefReduc * (1 - DamReduc2) + Refine) * damChangePer * (1 - RefineDamReduc) * (1 + DamIncrease) - Vit2 * (1 + VitPer2)) / count
44 if A <= 1 then
45 return 1, CommonFun.DamageType.Normal_Sp
46 end
47 return A, CommonFun.DamageType.Normal_Sp
48endPreserved HTML snapshot from ROM Handbook
