bpm91
Intermediate OT User
- Joined
- May 23, 2019
- Messages
- 928
- Solutions
- 7
- Reaction score
- 127
- Location
- Brazil
- YouTube
- caruniawikibr
Does anyone have the script that breaks the amphoras to open the teleport to enter the banuta? tf 1.5 7.72
Ah, i know now, after breaking four amphoras you can use the teleport, the problem is that the amphora is not returning to id 4996 after you break it, right ?break 4 amphora
21:39 You see canopic jar.
Item ID: 4996
Position: 32823, 32525, 10
and when breaking all the teleport is born, but the teleport does not close. only on server save
You need to set in items.xml the large amphora as an item that player can break, then, set the id of the trash(id 4997?) to decay to 4996 after 5 min.I actually don't have the script. but I'll let you know how it works
in fact, the script resets everything in 5 minutes, the teleport disappears, and the amphoras are born again
View attachment 73905
local banuta = MoveEvent()
-- amphoras location
local config = {Position(100, 100, 8), Position(100, 101, 8), Position(100, 102, 8), Position(100, 103, 8)}
function banuta.onStepin(creature, item, position, fromPosition)
local player = creature:getPlayer()
-- if player need storage, remove -- and add storage and value below
-- if player:getStorageValue(storage) < value then
-- player:teleportTo(fromPosition)
-- player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
-- return true
-- end
for i = 1, #config do
if not Tile(config[i]):getItemById(4997) then
player:teleportTo(fromPosition)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
return true
end
end
local destination = Position(100, 100, 9)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
player:teleportTo(destination)
destination:sendMagicEffect(CONST_ME_TELEPORT)
return true
end
banuta:type("stepin")
banuta:uid(10000)
banuta:register()
<movevent event="StepIn" uniqueid="12129" script="quests/the ape city/Mission9TheDeepestCatacombsteleport.lua" />
function onStepIn(creature, item, position, fromPosition)
local player = creature:getPlayer()
if not player then
return true
end
if item.uid == 12129 then
if player:getStorageValue(Storage.TheApeCity.Questline) >= 17 then
player:teleportTo({x = 32749, y = 32536, z = 10})
else
player:teleportTo(fromPosition)
player:sendTextMessage(MESSAGE_STATUS_SMALL, 'You don\'t have access to this area.')
end
position:sendMagicEffect(CONST_ME_TELEPORT)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
return true
end
-- 2 --
local config = {
amphoraPositions = {
Position(32792, 32527, 10),
Position(32823, 32525, 10),
Position(32876, 32584, 10),
Position(32744, 32586, 10)
},
brokenAmphoraId = 2252 --4997
}
if item.uid == 12130 then
local player = creature:getPlayer()
if not player then
return true
end
for i = 1, #config.amphoraPositions do
local amphoraItem = Tile(config.amphoraPositions[i]):getItemById(config.brokenAmphoraId)
if not amphoraItem then
player:teleportTo({x = 32852, y = 32544, z = 10})
position:sendMagicEffect(CONST_ME_TELEPORT)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
player:sendTextMessage(MESSAGE_STATUS_SMALL, "There are 4 large amphoras that must be broken in order to open the teleporter.")
return true
end
end
player:teleportTo({x = 32885, y = 32632, z = 11})
position:sendMagicEffect(CONST_ME_TELEPORT)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
return true
end
end
Ah, my bad, i thought that you can only teleport if all four is broken.I'm going to test, in fact the teleport is born when breaking all the amphoras, the teleport is born in a place on the map.
ty mano, i will try all scripts <3Ah, my bad, i thought that you can only teleport if all four is broken.
I update the script, even if you not using it, just use in another thing or as model
in this case it would not be a step in, but an action, because I don't need the storage part to enter, I just need 4 amphoras broken into positions. and create a teleport at a location that sends it to a location. I believe you would have to have action id in amphoras. and in stepintag:
Code:<movevent event="StepIn" uniqueid="12129" script="quests/the ape city/Mission9TheDeepestCatacombsteleport.lua" />
create a file in movements/scripts/quest/theapecity/Mission9TheDeepestCatacombsteleport.lua
Lua:function onStepIn(creature, item, position, fromPosition) local player = creature:getPlayer() if not player then return true end if item.uid == 12129 then if player:getStorageValue(Storage.TheApeCity.Questline) >= 17 then player:teleportTo({x = 32749, y = 32536, z = 10}) else player:teleportTo(fromPosition) player:sendTextMessage(MESSAGE_STATUS_SMALL, 'You don\'t have access to this area.') end position:sendMagicEffect(CONST_ME_TELEPORT) player:getPosition():sendMagicEffect(CONST_ME_TELEPORT) return true end -- 2 -- local config = { amphoraPositions = { Position(32792, 32527, 10), Position(32823, 32525, 10), Position(32876, 32584, 10), Position(32744, 32586, 10) }, brokenAmphoraId = 2252 --4997 } if item.uid == 12130 then local player = creature:getPlayer() if not player then return true end for i = 1, #config.amphoraPositions do local amphoraItem = Tile(config.amphoraPositions[i]):getItemById(config.brokenAmphoraId) if not amphoraItem then player:teleportTo({x = 32852, y = 32544, z = 10}) position:sendMagicEffect(CONST_ME_TELEPORT) player:getPosition():sendMagicEffect(CONST_ME_TELEPORT) player:sendTextMessage(MESSAGE_STATUS_SMALL, "There are 4 large amphoras that must be broken in order to open the teleporter.") return true end end player:teleportTo({x = 32885, y = 32632, z = 11}) position:sendMagicEffect(CONST_ME_TELEPORT) player:getPosition():sendMagicEffect(CONST_ME_TELEPORT) return true end end
I'm not sure about the "break and create teleport" because you can use all weapons to do that, are you REALLY sure about the break and create teleport? Not break and can teleport?ty mano, i will try all scripts <3
Post automatically merged:
in this case it would not be a step in, but an action, because I don't need the storage part to enter, I just need 4 amphoras broken into positions. and create a teleport at a location that sends it to a location. I believe you would have to have action id in amphoras. and in stepin
Thats how I remember too, so I simple do a script that meet thatI remember that the original teleport is already in its defined location, but the player is only teleported if the amphoras are broken, automatic respawn of the amphoras, on my server it works the way I told you
Got it, I'll try to adapt the script without the first part of the storage questI remember that the original teleport is already in its defined location, but the player is only teleported if the amphoras are broken, automatic respawn of the amphoras, on my server it works the way I told you