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

TFS 1.X+ "break" wall spell tfs 1.3

roriscrave

Advanced OT User
Joined
Dec 7, 2011
Messages
1,210
Solutions
35
Reaction score
206
Hi, how can i make a spell AREA that break a wall?
1 - have a wall in map ID 2777
2 - player uses spell in area, where spell picks up and has item ID 2777, this item is removed.
3 - getting like img 3

1575402441691.png
my area spell:
LUA:
local combat = Combat()
combat:setParameter(COMBAT_PARAM_TYPE, 1)
combat:setParameter(COMBAT_PARAM_EFFECT, 7)
combat:setFormula(COMBAT_FORMULA_LEVELMAGIC, -5.5, -3, -5.7, 3)
local arr = {
{0, 0, 0, 1 ,0 ,0 ,0},
{0, 0, 1, 1 ,1 ,0 ,0},
{0, 1, 1, 1 ,1 ,1 ,0},
{1, 1, 1, 2 ,1 ,1 ,1},
{0, 1, 1, 1 ,1 ,1 ,0},
{0, 0, 1, 1 ,1 ,0 ,0},
{0, 0, 0, 1 ,0 ,0 ,0},
}
combat:setArea(createCombatArea(arr))
function onCastSpell(creature, variant)
        return combat:execute(creature, variant)
end
 
Last edited:
Solution
you'll need to use function onTargetTile(cid, pos), check for item id on each tile and remove.
don't forget to add targettile function with combatcallback to your combat.
you'll need to use function onTargetTile(cid, pos), check for item id on each tile and remove.
don't forget to add targettile function with combatcallback to your combat.
 
Solution
Back
Top