---7.8! Você precisa ter suporte a movements!
Fiz um script para aquela planta feia que quando você pisa nela ela tira hit de você.
(Esse mata, tome cuidado)
Crie um arquivo chamado junglemaw.lua na pasta de movements.
function onStepIn(cid, item, pos)Damage1 = math.random(120,380)
if item.actionid > 0 then
Damage1 = item.actionid
end
if isPlayer(cid) == 1 then
if getPlayerAccess(cid) < 3 then
PlayerPos = getPlayerPosition(cid)
if getPlayerHealth(cid) < Damage1 then
Damage1 = getPlayerHealth(cid)
end
if item.itemid == 4208 then
doTransformItem(item.uid, item.itemid+1)
doCreatureAddHealth(cid,-Damage1)
doSendAnimatedText(PlayerPos, Damage1, 186)
end
end
end
return 1
end
function onStepOut(cid, item, pos)
doTransformItem(item.uid, 4208)
end
E no movements.xml:
<movevent event="StepIn" itemid="4208" script="junglemaw.lua" /> <movevent event="StepOut" itemid="4209" script="junglemaw.lua" />
Flwww!