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

Island of Destiny - Level 10 (teleport out)

Xianji

New Member
Joined
May 7, 2014
Messages
17
Reaction score
0
I'm using "The Forgotten Server v0.2.15", and I've with the help of some people gotten my Island of Destiny to work. Now I want people to get a message and be kicked out of the dungeon when they react level 10, to avoid having them stay there forever.

How is this done?

Thanks in advance!
 
I did this for my ot a couple of weeks ago when I worked on island of destiny.

The best is to use an onAdvance and check if the players hasent gotten a storage value from the boat npc.

But use if newLevel == level then, otherwise you check the storage even if they have left the island or the player is in rookgaard.
 
Thanks for the response! I'm not quite sure how to translate that into a script on my own. If it isn't too much to ask, could you lend me a hand?
 
Does your tfs use the new functions?
Change the text, position and storage variables.
Code:
function onAdvance(cid, skill, oldLevel, newLevel)
    if(skill == SKILL_LEVEL and newLevel > oldLevel) then
        local p = Player(cid)
        p:addHealth(p:getMaxHealth())
        p:addMana(p:getMaxMana())
        p:save()
       
        if(newLevel == 10 and p:getStorageValue(storage) ~= 1) then
            p:sendTextMessage(MESSAGE_EVENT_ADVANCE, text);
            p:teleportTo(position)
        end
    end
return true
end
 
Awesome! I can more or less figure out how to get that to work, however!

I'm aware there are people who like to stay in Rookgaard. How do I set it to discount non vocations in this teleport, or does it already?

Thanks a lot so far!
 
Awesome! I can more or less figure out how to get that to work, however!

I'm aware there are people who like to stay in Rookgaard. How do I set it to discount non vocations in this teleport, or does it already?

Thanks a lot so far!

Humm did not think about that on my own server even haha, you need to add another check for another storage value, or use the storage value 1 when you leave rookgaard and then 2 when they leave island of destiny.
 
Actually... I take that back. I can't get this to work on my own. :c How do I link it with the server and how do I prevent them from entering the same dungeon again?

Sorry. :c

Edit: Actually there's a second way, do you know how I can change my npc which currently works like on Island of Destiny where it grants you your class and you can enter the door/teleport.

How do I change that NPC to only give you the class once you accept it AND bring it a specific item? It'd be like a mission to "buy" your class.
 
Last edited:
Well I know how to do most things.
I programmed mine as rl except npc chats etc. But the festival is working.

You need to think on your own if you wanna learn.
 
Last edited:
Yeah, you're right. Hopefully it won't take too long to get a hang of, because I've always wanted to learn to script!

Thanks for your help, I'll get working now.
 
Back
Top