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

Rewrite script for TFS 0.4

bivan

New Member
Joined
Dec 18, 2008
Messages
125
Reaction score
1
Hi,
Can someone rewrite for me one script? There is:
Code:
function onStepIn(cid, item, frompos, item2, topos) 
local novapos = {x=434, y=1367, z=8} 

if item.uid == 10226 then

getThingfromPos(getPlayerPosition(cid)) 
doSendMagicEffect(getPlayerPosition(cid),2) 
doTeleportThing(cid,novapos) 
doSendMagicEffect(novapos,10) 
end 
end
It doesn't work for me...
 
Lua:
function onStepIn(cid, item, position)
	local teleport = {x=434, y=1367, z=8} 

	if item.uid == 10226 then
		doSendMagicEffect(position, 2) 
		doTeleportThing(cid, teleport) 
		doSendMagicEffect(getThingPos(cid), 10) 
	end 
	return true
end
 
It's working, thank You! ; )
Can You look this script:
Code:
local gatepos = {x=33297, y=31677, z=15, stackpos=1}

function onUse(cid, item, frompos, item2, topos)
local getgate = getThingfromPos(gatepos)

	if item.itemid == 1945 and getgate.itemid == 1304 then
		doRemoveItem(getgate.uid, 1)
		doTransformItem(item.uid, item.itemid+1)
	elseif item.itemid == 1946 and getgate.itemid == 0 then
		doCreateItem(1304, 1, gatepos)
		doTransformItem(item.uid, item.itemid-1)
	else
		doPlayerSendCancel(cid,"Sorry, not possible.")
	end
return 1
end
Removing walls by levers.
 
Back
Top