Full Version : MultiQuestTest
xmlspawner >>Q&A >>MultiQuestTest


<< Prev | Next >>

DreadfullyDespized- 11-11-2006
Alright basically. If you don't have the "SkeletalSword" then it starts the process for the "SkeletalQuest1". If you do have the sword then it starts the process for "SkeletalQuest2". If you have the "SkeletalBow" It would prompt to ask if you need to get some arrows and the various amounts you are able to get at.

Here is the xml so far. I tried player mode with carrying sword and even in backpack but it still starts the process of the SkeletalQuest1.

CODE

<?xml version="1.0" standalone="yes"?>
<XmlQuestNPC>
 <NPC>
   <Name>Bolton</Name>
   <Running>True</Running>
   <ProximityRange>3</ProximityRange>
   <NoTriggerOnCarried>SkeletalQuest1,Visible=true | SkeletalQuest2,Visible=true | 100SkeletalArrows,Visible=true | 200SkeletalArrows,Visible=true | 500SkeletalArrows,Visible=true | 1000SkeletalArrows,Visible=true | 50Skele</NoTriggerOnCarried>
   <AllowGhost>False</AllowGhost>
   <SpeechPace>1</SpeechPace>
   <ResetTime>1</ResetTime>
   <ConfigFile>Bolton</ConfigFile>
   <SpeechEntries>15</SpeechEntries>
 </NPC>
 <SpeechEntry>
   <EntryNumber>0</EntryNumber>
   <ID>0</ID>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>True</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>10</EntryNumber>
   <ID>10</ID>
   <Text>Yo yo dawg get down with this shisnaz LOL.</Text>
   <Condition>~GETONCARRIED,SkeletalSword,Visible=true</Condition>
   <DependsOn>-1</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>20</EntryNumber>
   <ID>20</ID>
   <Text>Would you like to make me pretty? Skeletal Pretty?</Text>
   <DependsOn>10</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>True</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>30</EntryNumber>
   <ID>30</ID>
   <Keywords>yes,ok</Keywords>
   <DependsOn>20</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
   <Gump>GUMP,Bolton,4/Well around here there is a gateway near a tombstone to get to the SkeletalTemple. The God of Skeletal only spawns at night though. Could you go and bring back the blade of the skeletons from a Skeletal person. Could you do that for me?;yes;ok</Gump>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>40</EntryNumber>
   <ID>40</ID>
   <Keywords>ok</Keywords>
   <DependsOn>30,50</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
   <Gump>GUMP,Bolton,3/Keep Killing The Skeletal, and find the Skeletal Blade and bring it back to me.</Gump>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>50</EntryNumber>
   <ID>50</ID>
   <Keywords>accept</Keywords>
   <Action>GIVE/&lt;questholder/name/Skeletal1/notestring/Find the SkeletalBlade./objective1/COLLECT,SkeletalBlade,1/autoreward/true/rewardstring/ADD/SkeletalSword,1</Action>
   <DependsOn>40</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>60</EntryNumber>
   <ID>60</ID>
   <Text>Aw you are very skilled. Want to try Skeletal Quest 2? If so, say Quest2.</Text>
   <Condition>GETONCARRIED,SkeletalSword,Visible=true</Condition>
   <DependsOn>-1</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>70</EntryNumber>
   <ID>70</ID>
   <Text>If you would like to get some more arrows for your bow, say arrows.</Text>
   <Condition>GETONCARRIED,SkeletalBow,Visible=true</Condition>
   <DependsOn>-1</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>True</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>80</EntryNumber>
   <ID>80</ID>
   <Text>Say 50, 100, 200, 500, 1000. Based on how many arrows you want.</Text>
   <Keywords>arrows</Keywords>
   <DependsOn>70</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>True</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>90</EntryNumber>
   <ID>90</ID>
   <Keywords>50</Keywords>
   <Action>GIVE/&lt;questholder/name/50SkeletalArrows/notestring/Collect 50 SkeletalBones from any Skeletal People./objective1/COLLECT,SkeletalBone,50/autorew/ADD/SkeletalArrow,50</Action>
   <DependsOn>80</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>100</EntryNumber>
   <ID>100</ID>
   <Keywords>100</Keywords>
   <Action>GIVE/&lt;questholder/name/100SkeletalArrows/notestring/Collect 100 Skeletal Bones from any of the Skeletal People./objective1/COLLECT,SkeletalBone,100/autoreward/true/rewardstring/ADD/SkeletalArrow,100</Action>
   <DependsOn>80</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>110</EntryNumber>
   <ID>110</ID>
   <Keywords>200</Keywords>
   <Action>GIVE/&lt;questholder/name/200SkeletalArrows/notestring/Collect 200 SkeletalBones from the Skeletal people./objective1/COLLECT,SkeletalBone,200/autoreward/true/rewardstring/ADD/SkeletalArrow,200</Action>
   <DependsOn>80</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>120</EntryNumber>
   <ID>120</ID>
   <Keywords>500</Keywords>
   <Action>GIVE/&lt;questholder/name/500SkeletalArrows/notestring/Collect 500 SkeletalBones from any Skeletal people./objective1/COLLECT,SkeletalBone,500/autoreward/true/rewardstring/ADD/SkeletalArrow,500</Action>
   <DependsOn>80</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>130</EntryNumber>
   <ID>130</ID>
   <Keywords>1000</Keywords>
   <Action>GIVE/&lt;questholder/name/1000SkeletalArrows/notestring/Collect 1000 SkeletalBones from any Skeletal people./objective1/COLLECT,SkeletalBone,1000/autoreward/true/rewardstring/ADD/SkeletalArrow,1000</Action>
   <DependsOn>80</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>140</EntryNumber>
   <ID>140</ID>
   <Keywords>Quest2</Keywords>
   <Action>GIVE/&lt;questholder/name/SkeletalQuest2/notestring/Find and Kill The God of the Skeletals./objective1/KILL,SkeletalGod,1/autoreward/true/rewardstring/ADD/SkeletalBow,1</Action>
   <DependsOn>60</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
</XmlQuestNPC>


ArteGordon- 11-11-2006
overall it looks ok. There are a few small problems but I tested it and it works.

I would check the name on your SkeletalSword with '[get name' and make sure that it looks exactly like the name being tested, caps and all.
When I manually created a sword and named it 'SkeletalSword' and put it in my pack then I got the second quest instead of the first.

There is also a problem with your NoTriggerOnCarried string that is not properly formed. Each test has to look like

name[,type][,EQUIPPED][,objective,objective,...]

It is confusing because it doesnt use the same format as the condition tests. I think that you just want to test for the named quests like

SkeletalQuest1 | SkeletalQuest2

There are a few other small problems:

In your rewardstring for the first quest you use

rewardstring/ADD/SkeletalSword,1

but does your SkeletalSword constructor accept an argument like '1'? Normally only stackable items have such a constructor. Same thing for

rewardstring/ADD/SkeletalBow,1

Also, 'autorew' is a typo

objective1/COLLECT,SkeletalBone,50/autorew/ADD/SkeletalArrow,50

DreadfullyDespized- 11-11-2006
There is also a problem with your NoTriggerOnCarried string that is not properly formed. Each test has to look like

name[,type][,EQUIPPED][,objective,objective,...]

Could you give an example?

ArteGordon- 11-11-2006
QUOTE (DreadfullyDespized @ November 11, 2006 08:38 pm)
There is also a problem with your NoTriggerOnCarried string that is not properly formed. Each test has to look like

name[,type][,EQUIPPED][,objective,objective,...]

Could you give an example?


SkeletalQuest1,questholder | SkeletalQuest2,questholder

it will test for your questholders with those names and so wont trigger if they are carrying either of them

DreadfullyDespized- 11-13-2006
Very informative, I am working on another quest. Basic idea behind the first one I am working on is a basic healing interaction. Talk to npc. you say healing which accepts the quest/event. Then you get poisoned or loose some hits. You also recieve 20 bandages to heal the effects of poison or loss of hits. Once you are back to full life You complete the quest. 1 time quest. Going to be doing it with all the skills to help newcomers to UO out.

here is what I have so far.

CODE

<?xml version="1.0" standalone="yes"?>
<XmlQuestNPC>
 <NPC>
   <Name>MyTrainer</Name>
   <Running>True</Running>
   <ProximityRange>3</ProximityRange>
   <NoTriggerOnCarried>HealingQuest1,questholder | MageryQuest1,questholder | CarpentryQuest1,questholder | BlacksmithyQuest1,questholder | HuntingQuest1,questholder | CombatQuest1,questholder | SpecialAttacksQuest1,questholder | AlchemyQuest1,questholder | ScribingQuest1,questholder | StealingQuest1,questholder</NoTriggerOnCarried>
   <AllowGhost>False</AllowGhost>
   <SpeechPace>1</SpeechPace>
   <ResetTime>1</ResetTime>
   <ConfigFile>MyTrainer</ConfigFile>
   <SpeechEntries>3</SpeechEntries>
 </NPC>
 <SpeechEntry>
   <EntryNumber>10</EntryNumber>
   <ID>10</ID>
   <Text>Nice seeing you {GETONTRIGMOB,name}. Would you like some services?</Text>
   <DependsOn>-1</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>True</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>20</EntryNumber>
   <ID>20</ID>
   <Text>I can teach you the basics in Healing, Magery, Carpentry, Blacksmithy, Hunting, Combat, SpecialAttacks, Alchemy, Scribing, Stealing.</Text>
   <Keywords>services</Keywords>
   <DependsOn>10</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
 <SpeechEntry>
   <EntryNumber>30</EntryNumber>
   <ID>30</ID>
   <Text>I will give you 20 bandages to test out with. Simply double click the bandages and target yourself to use them. Then based on your healing skill, it will heal you in time.</Text>
   <Keywords>healing</Keywords>
   <Action>GETONTRIGMOB,hits - 10 &amp; GIVE/bandage,20</Action>
   <DependsOn>20</DependsOn>
   <Pause>1</Pause>
   <PrePause>-1</PrePause>
   <LockConversation>False</LockConversation>
   <IgnoreCarried>False</IgnoreCarried>
   <AllowNPCTrigger>False</AllowNPCTrigger>
   <SpeechStyle>Regular</SpeechStyle>
   <SpeechHue>-1</SpeechHue>
 </SpeechEntry>
</XmlQuestNPC>