nawyrus
Member
- Joined
- Jan 16, 2014
- Messages
- 37
- Reaction score
- 10
Is there a chance this could work in TFS 1.0?
http://otland.net/threads/pokemon-summon-teleport.113146/
Another thing, regarding monster walking over fields, is there a way to set which field the creature will walk around or will not pass unless attacked, like real Tibia? I know that setting canpushitems to 0 in the monster xml file will make it never trespass any field the creature is not immune, even if you attack it.
Code:
function onThink(interval, lastExecution, thinkInterval)
local tabla = {}
local maxDistance = 10
for _, pid in ipairs(getPlayersOnline()) do
local summons = getCreatureSummons(pid)
if #summons > 0 then
table.insert(tabla, pid)
end
end
for _, t in ipairs(tabla) do
local summ = getCreatureSummons(t)
if getThingPos(t).z ~= getThingPos(summ[1]).z or getDistanceBetween(getThingPos(t), getThingPos(summ[1])) > maxDistance then
doTeleportThing(summ[1], getThingPos(t))
doSendMagicEffect(getThingPos(t), 12)
end
end
return true
end
Another thing, regarding monster walking over fields, is there a way to set which field the creature will walk around or will not pass unless attacked, like real Tibia? I know that setting canpushitems to 0 in the monster xml file will make it never trespass any field the creature is not immune, even if you attack it.
Last edited by a moderator: