testa ae..
function onTargetTile(cid, pos) local getPos = pos getPos.stackpos = 1 local trap = getThingFromPos(getPos) if (item.itemid == 5750) and (item.uid > 0) and (not isMoveable(item.uid)) then doRemoveItem(trap.uid) doSendMagicEffect(pos, CONST_ME_MAGIC_BLUE) return true end return false end local area, combat = createCombatArea(AREA_CIRCLE3X3), createCombatObject() setCombatArea(combat, area) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE) setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) return doCombat(cid, combat, var) end




info
Grupo: Artesão
Registrado: 22/02/14
Posts: 101
Reputação: +21
Eai pessoal, eu gostaria que criassem uma spell que destroi trap, ou seja, o Player esta TRAPADO.
Assim:
{x,x,x}
{x,0,x}
{x,x,x}
Então ele usa a magia e destroi essa trap.
{ , , }
{ ,0, }
{ , , }
Entenderam? o ID da trap é 5750.
Se não entenderam, peçam para eu explicar melhor por favor.
Obrigado