8.6
tfs 0.4
<movevent event="StepIn" itemid="111111111" script="scriptName.lua" />
local teleportPosition = {x = 1000, y = 1000, z = 7} -- if they have items, teleport them here
function onStepIn(cid, item, position, fromPosition)
if not isPlayer(cid) then
doTeleportThing(cid, teleportPosition)
return true
end
local slotItem
for i = 1, 10 do
slotItem = getPlayerSlotItem(cid, i)
if slotItem.itemid > 0 then
doTeleportThing(cid, teleportPosition)
return true
end
end
return...
Good question.Hello, can anyone help me , i need a script who makes ID : tile not walkeable if have itens/set/bp...etc
local tileId = 11111111 -- itemId they are stepping on
local teleportPosition = Position(1000, 1000, 7) -- if they have items, teleport them here
local moveEvent = MoveEvent()
moveEvent:type("stepin")
function moveEvent.onStepIn(creature, item, position, fromPosition)
if not creature:isPlayer() then
creature:teleportTo(teleportPosition)
return true
end
local slotItem
for i = 1, 10 do
slotItem = player:getSlotItem(i)
if slotItem then
creature:teleportTo(teleportPosition)
return true
end
end
return true
end
moveEvent:id(tileId)
moveEvent:register()
can you tell me what i put in movements.xml?LUA:local tileId = 11111111 -- itemId they are stepping on local teleportPosition = Position(1000, 1000, 7) -- if they have items, teleport them here local moveEvent = MoveEvent() moveEvent:type("stepin") function moveEvent.onStepIn(creature, item, position, fromPosition) if not creature:isPlayer() then creature:teleportTo(teleportPosition) return true end local slotItem for i = 1, 10 do slotItem = player:getSlotItem(i) if slotItem then creature:teleportTo(teleportPosition) return true end end return true end moveEvent:id(tileId) moveEvent:register()
The script above is for rev scripts. You just put it intocan you tell me what i put in movements.xml?
data/scripts as a lua file.<movevent event="StepIn" itemid="111111111" script="scriptName.lua" />
local teleportPosition = Position(1000, 1000, 7) -- if they have items, teleport them here
function onStepIn(creature, item, position, fromPosition)
if not creature:isPlayer() then
creature:teleportTo(teleportPosition)
return true
end
local slotItem
for i = 1, 10 do
slotItem = player:getSlotItem(i)
if slotItem then
creature:teleportTo(teleportPosition)
return true
end
end
return true
end
i have this issueThe script above is for rev scripts. You just put it intodata/scriptsas a lua file.
If for some reason you don't have rev scripts.. then yeah just throw it into movements
XML:<movevent event="StepIn" itemid="111111111" script="scriptName.lua" />LUA:local teleportPosition = Position(1000, 1000, 7) -- if they have items, teleport them here function onStepIn(creature, item, position, fromPosition) if not creature:isPlayer() then creature:teleportTo(teleportPosition) return true end local slotItem for i = 1, 10 do slotItem = player:getSlotItem(i) if slotItem then creature:teleportTo(teleportPosition) return true end end return true end

What server version are you using?i have this issue
View attachment 65410
8.6What server version are you using?
8.6
tfs 0.4
<movevent event="StepIn" itemid="111111111" script="scriptName.lua" />
local teleportPosition = {x = 1000, y = 1000, z = 7} -- if they have items, teleport them here
function onStepIn(cid, item, position, fromPosition)
if not isPlayer(cid) then
doTeleportThing(cid, teleportPosition)
return true
end
local slotItem
for i = 1, 10 do
slotItem = getPlayerSlotItem(cid, i)
if slotItem.itemid > 0 then
doTeleportThing(cid, teleportPosition)
return true
end
end
return true
end