• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Requesting Level requirement to move on tile

Lightonia

Lightonia.servegame.com
Joined
Jun 4, 2007
Messages
492
Reaction score
9
Hi, i need a script that makes that you need a required level to walk on tile
 
Here We Are :)
in your movements/movements.xml paste the following code:
XML:
	<movevent type="StepIn" uniqueid="8888" event="script" value="tile.lua"/>

Now in your movements/movements.xml paste the following code:
LUA:
local level = 140 -- the level needed to acces the tile.
local notouch = {x=1,y=1,z=1}
function onStepIn(cid, item, position, lastPosition, fromPosition, toPosition, actor)
	if getPlayerLevel(cid) >= level then
		doTeleportThing(cid,notouch)
		doSendMagicEffect(getThingPos(cid),10)
	else
		doTeleportThing(cid,fromPosition)
		doPlayerSendTextMessage(cid,19,'You need level 140 or higher to acces this tile.')
		doSendMagicEffect(getThingPos(cid),2)
	end
	return true
end

Put uniqueid = 8888 in the tile which that need level x to acces

Rep++ If It Helpful For You
 
LUA:
function onStepIn(cid, item, position, lastPosition, fromPosition, toPosition, actor)
	if getPlayerLevel(cid) < 140 then
		return doTeleportThing(cid, fromPosition) and doPlayerSendCancel(cid, "You need level 140 or higher to access this tile.")
	end
	return true
end
 
Back
Top