Hello, I have a problem with oracle on TFS 0.3.5.
So, in my map i have different city's names than oracle is using.
I changed it and coordinates of city's but nothing happaned.
When i'm saying "hi" to oracle she doesn't do anything.. ;/
Please, help me.
So, in my map i have different city's names than oracle is using.
I changed it and coordinates of city's but nothing happaned.
When i'm saying "hi" to oracle she doesn't do anything.. ;/
Please, help me.
am I changed everything well and nothing is omitted?<?xml version="1.0" encoding="UTF-8"?>
<npc name="The Oracle" floorchange="0" walkinterval="0">
<health now="150" max="150"/>
<look typeex="1448"/>
<interaction range="3" idletime="30">
<interact keywords="hi" focus="1">
<!--These are the keywords will trigger this interaction-->
<keywords>hello</keywords>
<keywords>greet</keywords>
<response>
<action name="script">
<!--
if(getPlayerVocation(cid) ~= 0) then
selfSay("SORRY, YOU HAVE ALREADY MADE YOUR CHOICE IN LIFE!")
_state.isidle = true
return
end
-->
if(getPlayerLevel(cid)) >= 8 then
selfSay(getCreatureName(cid) .. ", ARE YOU PREPARED O FACE YOUR DESTINY?")
_state.b1 = (isPremium(cid) == TRUE)
_state.topic = 1
else
selfSay("CHILD! COME BACK WHEN YOU HAVE GROWN UP!")
_state.isidle = true
end
</action>
</response>
</interact>
<interact keywords="yes" topic="1">
<!--Premium account, b1 is set in above-->
<response b1="1" text="IN WHICH TOWN DO YOU WANT TO LIVE: LIGHTING CITY, BLOOD BAY, FRIZEN, ANCIENTIC OR LENGUJ?">
<action name="topic" value="2"/>
</response>
<!--Normal account-->
<response text="IN WHICH TOWN DO YOU WANT TO LIVE: LIGHTING CITY, BLOOD BAY, FRIZEN, ANCIENTIC OR LENGUJ?">
<action name="topic" value="2"/>
</response>
</interact>
<interact keywords="lighting city" topic="2">
<response text="IN LIGHTING CITY! AND WHAT PROFESSION HAVE YOU CHOSEN: KNIGHT, PALADIN, SORCERER, OR DRUID?">
<!--n1: 1 = lighting city, 2 = blood bay, 4 = frizen, 5 = ancientic, 7 = lenguj-->
<action name="script">
_state.n1 = 1
_state.topic = 3
</action>
</response>
</interact>
<interact keywords="blood bay" topic="2">
<response text="IN BLOOD BAY! AND WHAT PROFESSION HAVE YOU CHOSEN: KNIGHT, PALADIN, SORCERER, OR DRUID?">
<!--n1: 1 = lighting city, 2 = blood bay, 4 = frizen, 5 = ancientic, 7 = lenguj-->
<action name="script">
_state.n1 = 2
_state.topic = 3
</action>
</response>
</interact>
<interact keywords="frizen" topic="2">
<response text="IN FRIZEN! AND WHAT PROFESSION HAVE YOU CHOSEN: KNIGHT, PALADIN, SORCERER, OR DRUID?">
<!--n1: 1 = lighting city, 2 = blood bay, 4 = frizen, 5 = ancientic, 7 = lenguj-->
<action name="script">
_state.n1 = 4
_state.topic = 3
</action>
</response>
</interact>
<interact keywords="ancientic" topic="2">
<response text="IN ANCIENTIC! AND WHAT PROFESSION HAVE YOU CHOSEN: KNIGHT, PALADIN, SORCERER, OR DRUID?">
<!--n1: 1 = lighting city, 2 = blood bay, 4 = frizen, 5 = ancientic, 7 = lenguj-->
<action name="script">
_state.n1 = 5
_state.topic = 3
</action>
</response>
</interact>
<interact keywords="lenguj" topic="2">
<response text="IN LENGUJ! AND WHAT PROFESSION HAVE YOU CHOSEN: KNIGHT, PALADIN, SORCERER, OR DRUID?">
<!--n1: 1 = lighting city, 2 = blood bay, 4 = frizen, 5 = ancientic, 7 = lenguj-->
<action name="script">
_state.n1 = 7
_state.topic = 3
</action>
</response>
</interact>
<!--If the player does not say any city, repeat our question-->
<interact keywords="|*|" topic="2">
<response b1="1" text="LIGHTING CITY, BLOOD BAY, FRIZEN, ANCIENTIC OR LENGUJ?"/>
<response text="LIGHTING CITY, BLOOD BAY, FRIZEN, ANCIENTIC OR LENGUJ?"/>
</interact>
<interact keywords="sorcerer" topic="3">
<response text="A SORCERER! ARE YOU SURE? THIS DECISION IS IRREVERSIBLE!">
<!--n2: 1 = sorcerer, 2 = druid, 3 = paladin, 4 = knight-->
<action name="script">
_state.n2 = 1
_state.topic = 4
</action>
</response>
</interact>
<interact keywords="druid" topic="3">
<response text="A DRUID! ARE YOU SURE? THIS DECISION IS IRREVERSIBLE!">
<!--n2: 1 = sorcerer, 2 = druid, 3 = paladin, 4 = knight-->
<action name="script">
_state.n2 = 2
_state.topic = 4
</action>
</response>
</interact>
<interact keywords="paladin" topic="3">
<response text="A PALADIN! ARE YOU SURE? THIS DECISION IS IRREVERSIBLE!">
<!--n2: 1 = sorcerer, 2 = druid, 3 = paladin, 4 = knight-->
<action name="script">
_state.n2 = 3
_state.topic = 4
</action>
</response>
</interact>
<interact keywords="knight" topic="3">
<response text="A KNIGHT! ARE YOU SURE? THIS DECISION IS IRREVERSIBLE!">
<!--n2: 1 = sorcerer, 2 = druid, 3 = paladin, 4 = knight-->
<action name="script">
_state.n2 = 4
_state.topic = 4
</action>
</response>
</interact>
<!--If the player does not say any profession, repeat our question-->
<interact keywords="|*|" topic="3">
<response text="KNIGHT, PALADIN, SORCERER, OR DRUID?"/>
</interact>
<interact keywords="yes" topic="4">
<response>
<!--n1: 1 = carlin, 2 = edron, 3 = thais, 4 = venore-->
<!--n2: 1 = knight, 2 = paladin, 3 = sorcerer, 4 = druid-->
<action name="script">
local pos = 0
if(_state.n1 == 1) then
pos = {x=160, y=50, z=7}
elseif(_state.n1 == 2) then
pos = {x=361, y=438, z=6}
elseif(_state.n1 == 4) then
pos = {x=448, y=26, z=7}
elseif(_state.n1 == 5) then
pos = {x=693, y=583, z=7}
elseif(_state.n1 == 7) then
pos = {x=82, y=729, z=7}
else
selfSay("I DO NOT KNOW WHAT PROFESSION THAT IS, ASK THE GODS FOR GUIDANCE!")
return
end
selfSay("SO BE IT!")
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)
if(doTeleportThing(cid, pos) == 0) then
doPlayerSetVocation(cid, _state.n2)
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)
end
</action>
<action name="idle" value="1"/>
</response>
</interact>
<interact keywords="bye" focus="0">
<keywords>farewell</keywords>
<response text="Good bye. Recommend us, if you were satisfied with our service."/>
</interact>
<!--
If the event onBusy exists, the npc will make a queue like Tibia, if the event is removed
the npc will be able to talk to all customers at the same time without problems.
-->
<interact event="onBusy">
<response text="WAIT UNTIL IT IS YOUR TURN!">
<action name="addqueue" value="|PLAYER|"/>
</response>
</interact>
<!--This event triggers if the player goes to far away from the npc/logout/idle timeout-->
<interact event="onPlayerLeave" focus="0">
<response text="COME BACK WHEN YOU ARE PREPARED TO FACE YOUR DESTINY!"/>
</interact>