Hio..
I need help with me weapon script...
I want it to paralyze RANDOMLY not all the time
Can someone help me?
I need help with me weapon script...
Code:
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1)
setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 1)
setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_STUN)
setCombatFormula(combat, COMBAT_FORMULA_SKILL, 0, 0, 1.0, 0)
local condition = createConditionObject(CONDITION_PARALYZE)
setConditionParam(condition, CONDITION_PARAM_TICKS, 5000)
setConditionParam(condition, CONDITION_PARAM_SPEED, -150)
setCombatCondition(combat, condition)
function onUseWeapon(cid, var)
if getPlayerLevel(cid) >= 100 then
doCombat(cid, combat, var)
else
doPlayerSendCancel(cid, 'You need level 100 to use this weapon.')
end
end
Can someone help me?