• 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!

Monster that.. TFS 1.0

ATT3

Intermediate OT User
Joined
Sep 22, 2010
Messages
512
Reaction score
100
Is there a way to make monster do spell that lowers x% of players skills?/ml/dist etc.

From Tibia.wikia; Silencer
Abilities:
lowers your
Magic Level by 30-80% for 3 turns, overlaps if cast subsequently)

So.
Monster does spell that lowers X% of your current magic level for X time.
Tfs 1.0
 
Code:
<attack script="custom/spellname.lua" interval="15000" chance="100"/>
Code:
condition:setParameter(CONDITION_PARAM_STAT_MAGICPOINTSPERCENT, math.random(20, 70))
 
Code:
<attack script="custom/spellname.lua" interval="15000" chance="100"/>
Code:
condition:setParameter(CONDITION_PARAM_STAT_MAGICPOINTSPERCENT, math.random(20, 70))

Thanks, but how do I use this
Code:
condition:setParameter(CONDITION_PARAM_STAT_MAGICPOINTSPERCENT, math.random(20, 70))
Could you create example spell?

I am just getting bunch of errors, I have no idea how to get it working.
 
Code:
local combat1 = createCombatObject()
setCombatParam(combat1, COMBAT_PARAM_TYPE, 1)
setCombatParam(combat1, COMBAT_PARAM_EFFECT, 0)
setCombatParam(combat1, COMBAT_PARAM_DISTANCEEFFECT, 255)
condition:setParameter(CONDITION_PARAM_STAT_MAGICPOINTSPERCENT, math.random(20, 70))
--=======================================================================




local area1 = {
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0},
{0, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 0, 0},
{0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0},
{0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0},
{0, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 0},
{0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0},
{0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0},
{0, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 0, 0},
{0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}}
--=======================================




setCombatArea(combat1, createCombatArea(area1))



function onCastSpell(cid, var)
addEvent(doCombat, 0, cid, combat1, var)
return TRUE
end
try
 
Last edited:
Back
Top