pioncz
New Member
- Joined
- Dec 3, 2008
- Messages
- 149
- Reaction score
- 1
Hi,
How to make doors that teleports depend on id?
When doors are horizontal so it teleport doorpos.y-1 or doorpos.y+1
but when they are vertical so they teleports x+1 or x-1 (depends on player position).
I've made this but its just a seed of script:
It runs on actionid 1001 (so i can make this action on each one door).
How to make doors that teleports depend on id?
When doors are horizontal so it teleport doorpos.y-1 or doorpos.y+1
but when they are vertical so they teleports x+1 or x-1 (depends on player position).
I've made this but its just a seed of script:
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
local newPosition = toPosition
newPosition.y = newPosition.y + 1
local doorPosition = fromPosition
local newPos = {x=1000, y=1000, z=7}
doTeleportThing(cid, newPos)
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_HEARTS)
return true
end