• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

error in damage condition

czouski

Banned User
Joined
Nov 2, 2024
Messages
168
Solutions
1
Reaction score
62
local combat = Combat()
combat:setParameter(COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
combat:setParameter(COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_POISONARROW)
combat:setParameter(COMBAT_PARAM_BLOCKARMOR, true)
combat:setFormula(COMBAT_FORMULA_SKILL, 0, 0, 1, 0)

function onUseWeapon(player, variant)
if not combat:execute(player, variant) then
return false
end

player:addDamageCondition(Creature(variant:getNumber()), CONDITION_POISON, DAMAGELIST_LOGARITHMIC_DAMAGE, 3)
return true
end

this is poison arrow from 1.4.2 distro

the problem im expriencing is that the condition does not add into monsters properly sometimes it might deal damage other times it wont and othertimes that player hit it it will only add the tick once
it does not tick on its own and when player is not attacking monster the condition does not tick
i could not find any reference in sources to addDamageCondition
 
Back
Top