Full Version : Rotate a NPC
xmlspawner >>Q&A >>Rotate a NPC
<< Prev | Next >>
riverman- 02-18-2007
i know i have seen this one time, but for the life of me i cant find it again,
how do i rotate a npc,?
they all seem to look north in the beginning.
ArteGordon- 02-18-2007
you can set their Direction property to change their facing. Here is a thread on the topic
http://xmlspawner.15.forumer.com/index.php?showtopic=557&hl=
riverman- 02-18-2007
thanks arte.
riverman- 02-19-2007
aai ArteGordon, im stuck again, i used the travelagent script to adapt for a dungeon traveler, but my gump doesnt seem to open, i am player level, it does ask me the diff senarious , but when i say travel nothing happens, what am i doing wrong ?
i attached the file if you want to look please.

QUOTE
<?xml version="1.0" standalone="yes"?> <XmlQuestNPC> <NPC> <Name>FlyByNight</Name> <Running>True</Running>
<ProximityRange>3</ProximityRange>
<AllowGhost>False</AllowGhost>
<ResetTime>0.20</ResetTime>
<ConfigFile>travelagent2</ConfigFile>
<SpeechEntries>14</SpeechEntries>
</NPC>
<SpeechEntry>
<EntryNumber>0</EntryNumber>
<ID>0</ID>
<DependsOn>999</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>1</EntryNumber>
<ID>3</ID>
<Text>Where can I take you today? The fare is 1000 gold. Just say Travel </Text>
<DependsOn>-1</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>2</EntryNumber>
<ID>3</ID>
<Text>What is your destination? The fare is 1000 gold. Just say Travel</Text>
<DependsOn>-1</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>3</EntryNumber>
<ID>3</ID>
<Text>Just say the word and you are off! The fare is 1000 gold. Just say Travel</Text>
<DependsOn>-1</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>4</EntryNumber>
<ID>4</ID>
<Keywords>travel</Keywords>
<DependsOn>3</DependsOn>
<Action>Gump,Travelagent,4/Please choose a Dungeon;Not Today;end;Covetous;on1;Deceit;on2;Despice;on3;Hythloth;on4;Shame;on5;Wrong;on6;Ice;on7;SolenHive;on8;<Action>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>5</EntryNumber>
<ID>5</ID>
<Keywords>end</Keywords>
<Text>Ah well, perhaps when your purse is heavier. </Text>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>6</EntryNumber>
<ID>6</ID>
<Keywords>on1</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/1401/y/1625/z/28</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>7</EntryNumber>
<ID>7</ID>
<Keywords>on2</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/2539/y/501/z/30</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>8</EntryNumber>
<ID>8</ID>
<Keywords>on3</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>9</EntryNumber>
<ID>9</ID>
<Keywords>on4</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>10</EntryNumber>
<ID>10</ID>
<Keywords>on5</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>11</EntryNumber>
<ID>11</ID>
<Keywords>on6</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>12</EntryNumber>
<ID>12</ID>
<Keywords>on7</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
<SpeechEntry>
<EntryNumber>13</EntryNumber>
<ID>13</ID>
<Keywords>on8</Keywords>
<Text>Enjoy your trip! </Text>
<Action>TAKEBYTYPE,1,1000,true/gold/SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>
<Pause>0</Pause>
<DependsOn>4</DependsOn>
</SpeechEntry>
</XmlQuestNPC>

mmm how do i get it into one of those small scrolleable windows?
ArteGordon- 02-19-2007
the keyword here should be GUMP not Gump

QUOTE
Gump,Travelagent,4/Please choose a Dungeon;Not

(edit)

QUOTE
<Action>Gump,Travelagent,4/Please choose a Dungeon;Not Today;end;Covetous;on1;Deceit;on2;Despice;on3;Hythloth;on4;Shame;on5;Wrong;on6;Ice;on7;SolenHive;on8;<Action>

Another problem is that this gump specification should be placed in the Gump field rather than in the Action field of the xmldialog entry. The difference between the two is that when you put it in the Gump field, the gump responses can be used as keyword triggers for other entries. If you put it in the Action field, the gump will come up, but the responses wont be able to trigger anything.
also, your Actions for taking gold and teleporting the player need to be changed. TAKEBYTYPE and SETONTRIGMOB are both standalone keywords (they can only be used at the beginning of an entry) and so need to be two separate actions. You need to separate them with a semicolon, like this

QUOTE
<Action>TAKEBYTYPE,1,1000,true/gold ; SETONTRIGMOB/map/felucca/x/4111/y/432/z/5</Action>

riverman- 02-20-2007
thanks Arte, you answered my next question as well, its working perfectly.
many many thanks, can i post the script somewhere?
ArteGordon- 02-20-2007
yeah, sure. You can post in the Files section.