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

StepIn > Random teleport (Solved)

LucasFerraz

Systems Analyst
Joined
Jun 10, 2010
Messages
2,857
Reaction score
96
Location
Brazil
Hello,
How can I make it?
- When player stepin he get teleported to random place

Places:
X=10 Y=48 Z=7
X=78 Y=78 Z=8
X=52 Y=67 Z=5
X=44 Y=21 Z=6
X=70 Y=15 Z=4
X=97 Y=7 Z=2
 
Search for it next time!

LUA:
local t = {
	{x = 100, y = 100, z = 7},
	{x = 100, y = 100, z = 7},
	{x = 100, y = 100, z = 7}
}

function onStepIn(cid, item, position, fromPosition)
	if isPlayer(cid) then
		doTeleportThing(cid, t[math.random(#t)])
	end
end
 
Sorry for that, I didn't search because I'm in job and I cant keep OTLand open :D

I'll test at night
LUA:
local t = {
	{x = 100, y = 100, z = 7},
	{x = 100, y = 100, z = 7},
	{x = 100, y = 100, z = 7}
}
 
function onStepIn(cid, item, position, fromPosition)
	if isPlayer(cid) then
		doTeleportThing(cid, t[math.random(#t)])
	end
end
 
Back
Top