Przemyslaw1101
Member
- Joined
- Feb 16, 2017
- Messages
- 53
- Solutions
- 2
- Reaction score
- 9
Hey all, i dont know how to create script that adds DOT condiction to weapon.
Can someone help me with that? I mean - Axe with bleeding DOT (that scales by skills/level/atk by default like other weapons i made)
I searched a whole forum and I found outdated/not working etc. scrtips.
Here is this axe script without DOT: (TFS 1.3)
Can someone help me with that? I mean - Axe with bleeding DOT (that scales by skills/level/atk by default like other weapons i made)
I searched a whole forum and I found outdated/not working etc. scrtips.
Here is this axe script without DOT: (TFS 1.3)
Lua:
local combat = Combat()
combat:setParameter(COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
combat:setParameter(COMBAT_PARAM_BLOCKARMOR, true)
combat:setParameter(COMBAT_PARAM_BLOCKSHIELD, true)
function onGetFormulaValues(player, skill, attack, factor)
local min = (player:getLevel() / 3) + ((skill / 2) * (attack * 2) * 0.05) + 15
local max = (player:getLevel() / 3) + ((skill / 2) * (attack * 2) * 0.06) + 25
return -min, -max
end
combat:setCallback(CALLBACK_PARAM_SKILLVALUE, "onGetFormulaValues")
function onUseWeapon(creature, variant)
return combat:execute(creature, variant)
end