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

[10.77][TFS 1.2] ORTS, a real map project

Npc zoltan.xml
Code:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Zoltan" script="zoltan.lua" walkinterval="2000" floorchange="0">
  <health now="100" max="100" />
  <look type="130" head="95" body="113" legs="95" feet="76" addons="0" />
<parameters>
        <parameter key="message_greet" value="Welcome player, student of the arcane arts."/>
        <parameter key="message_farewell" value="Good bye, and don't come back too soon."/>
    </parameters>
</npc>

Code:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)

function onCreatureAppear(cid)            npcHandler:onCreatureAppear(cid)            end
function onCreatureDisappear(cid)        npcHandler:onCreatureDisappear(cid)            end
function onCreatureSay(cid, type, msg)    npcHandler:onCreatureSay(cid, type, msg)    end
function onThink()                        npcHandler:onThink()    end

-- Storage IDs --     
mage        = 22005 
summoner    = 22011   

newaddon    = 'I bow to you, player, and hereby grant you the right to wear Ferumbras hat as accessory. Congratulations!'
noitems        = 'You do not have all the required items.'
noitems2    = 'You do not have all the required items or you do not have the first addon, which by the way, is a requirement for this addon.'
already        = 'It seems you already have this addon, don\'t you try to mock me son!'
 
-- MAGE START --   
function MageSecond(cid, message, keywords, parameters, node)

    if(not npcHandler:isFocused(cid)) then
        return false
    end

    if isPremium(cid) then
    addon = getPlayerStorageValue(cid,mage+1)
    if addon == -1 then
        if getPlayerSex(cid) == 0 then
        if getPlayerItemCount(cid,5903) >= 1 then
        if doPlayerRemoveItem(cid,5903,1) then
            selfSay(newaddon, cid)
             
            doSendMagicEffect(getCreaturePosition(cid), 13) 
            doPlayerAddOutfit(cid, 141, 2)
            setPlayerStorageValue(cid,summoner+1,1)
        end
        else
            selfSay(noitems, cid)
        end
        elseif getPlayerSex(cid) == 1 then
        if getPlayerItemCount(cid,5903) >= 1 then
        if doPlayerRemoveItem(cid,5903,1) then
            selfSay(newaddon, cid)
             
            doSendMagicEffect(getCreaturePosition(cid), 13)
            doPlayerAddOutfit(cid, 130, 2)
            setPlayerStorageValue(cid,mage+1,1)
        end
        else
            selfSay(noitems, cid)
        end
        end
    else
        selfSay(already, cid)
    end
    end

end
-- MAGE END --

node5 = keywordHandler:addKeyword({'proof'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = '... I cannot believe my eyes. You retrieved this hat from Ferumbras remains? That is incredible. If you give it to me, I will grant you the right to wear this hat as addon. What do you say?'})
    node5:addChildKeyword({'yes'}, MageSecond, {})
    node5:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Alright then. Come back when you got all neccessary items.', reset = true}) 



npcHandler:addModule(FocusModule:new())
 
To fix sam old backpack quest you need change the unique ID of door to 2234:
3nnfrnch.png
 
To fix sam old backpack quest you need change the unique ID of door to 2234:
3nnfrnch.png

Its better to update the actions.xml file, I did that, lets just wait for printer to accept the change.
 
How I can activate the Questlog-system?
You will have to rescript most of thr npcs, actions, creaturescripts.

Trust me its not fun, but if you do that it will act like rl.
If you can find the correct texts that is.
 
Have somebody the same problem with entchanting of ruby and other stones.
I always get lua errors.
s3quk3jo.png

How can I fiix that`?
 
Sorry guys that i cant help anymore, since im hardcore working alone on my project which has required alot of coding, mapping, spr editing and etc...

Thanks to @WibbenZ for all the help :)
 
Congratulations, great job.
But contains a small problem,
Warzone The Teleport's not Funcionão Of Bosses and access to NPCs.
 
Congratulations, great job.
But contains a small problem,
Warzone The Teleport's not Funcionão Of Bosses and access to NPCs.

Thats true, someone has to get the positions to all the bosses and rewrite the teleport script. Wote isen't done in any way, why not help out? :p
 
Is there auto-save system or I have to add it manually? If there isn't is there any tutorial?
 
Is there auto-save system or I have to add it manually? If there isn't is there any tutorial?
If you check globalevents/scripts/serversave.lua and edit the time in globalevents/globalevents.xml
Code:
<globalevent name="Server Save" time="09:55:00" script="serversave.lua"/>
 
the already compiled version of the server that is included in the download does it have any changes compared to the source? i mean like if you have done anything your self with the code or running it as standard
 
the already compiled version of the server that is included in the download does it have any changes compared to the source? i mean like if you have done anything your self with the code or running it as standard
It is standard forgottenserver pulled straight from the source thats listed in OP
 
the already compiled version of the server that is included in the download does it have any changes compared to the source? i mean like if you have done anything your self with the code or running it as standard

The only difference is the "Data" folder
 
the already compiled version of the server that is included in the download does it have any changes compared to the source? i mean like if you have done anything your self with the code or running it as standard
The only difference is the "Data" folder

You should not use that exe, its bugged if you ask me, found out that me and a couple of more have had problems with it crashing.
Use this one insted: http://otland.net/threads/10-31-the-forgotten-server-1-0-915.207351/
Workes great, im using it to test stuff before I make a change on github.
 
Back
Top