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

Solved Help Movement Prestige/Level Script

thanhlan94

Dragonot.zapto.org Owner
Joined
Jun 11, 2011
Messages
192
Reaction score
14
Movement Script
function onStepIn(cid, item, position, fromPosition)
if isPlayer(cid) and getPlayerLevel(cid) >= 200 then
else getCreatureStorage(cid, 4500) >= 1
doTeleportThing(cid, {x=X, y=X, z=X})
doSendMagicEffect(position, CONST_ME_TELEPORT)
doSendMagicEffect({x=X, y=X, z=X}, CONST_ME_TELEPORT)
end
end

How do i change this so anyone who is higher than 1 prestige cannot enter but anyone below 1 prestige and above lvl 200 can enter? I cant find any online scripts for this :(
 
Code:
function onStepIn(cid, item, position, fromPosition)

        -- if anything but a player steps on the tile, do nothing
        if not isPlayer(cid) then
                return true
        end

        -- check prestige level, if above 1 prestige teleport back where they came from
        if getCreatureStorage(cid, 4500) > 1 then
                doTeleportThing(cid, fromPosition)
                return true
        end

        -- check player level, if less then 200 teleport back where they came from
        if getPlayerLevel(cid) < 200 the
                doTeleportThing(cid, fromPosition)
                return true
        end

        -- if all checks are fine, teleport player and send magic effects.
        doTeleportThing(cid, {x=X, y=X, z=X})
        doSendMagicEffect(position, CONST_ME_TELEPORT)
        doSendMagicEffect({x=X, y=X, z=X}, CONST_ME_TELEPORT)

        return true
end
 
Code:
function onStepIn(cid, item, position, fromPosition)

        -- if anything but a player steps on the tile, do nothing
        if not isPlayer(cid) then
                return true
        end

        -- check prestige level, if above 1 prestige teleport back where they came from
        if getCreatureStorage(cid, 4500) > 1 then
                doTeleportThing(cid, fromPosition)
                return true
        end

        -- check player level, if less then 200 teleport back where they came from
        if getPlayerLevel(cid) < 200 the
                doTeleportThing(cid, fromPosition)
                return true
        end

        -- if all checks are fine, teleport player and send magic effects.
        doTeleportThing(cid, {x=X, y=X, z=X})
        doSendMagicEffect(position, CONST_ME_TELEPORT)
        doSendMagicEffect({x=X, y=X, z=X}, CONST_ME_TELEPORT)

        return true
end
Thanks Xikini
 
Back
Top