Full Version : How To Condiction Search Form nearby?
xmlspawner >>Q&A >>How To Condiction Search Form nearby?
<< Prev | Next >>
Xerocrates- 10-15-2007
Hi, me again
I have a problem (woa... what a news...) now i try to write it (woa... what a beautiful english...)
I'm try to make a command to tell at Npc's "mount on a horse controlled by me"
Command:Mount!
Text:bla bla bla
Condiction: GETONPARENT,controlmaster.serial=GETONTRIGMOB,serial&GETONNEARBY,1,*,basemount,controlmaster=GETONPARENT,controlmaster
Action:SETONNEARBY,1,*,basemount/rider/{GETONPARENT,serial} "{GETONPARENT,name}"
It work pefectly... but...
If nearby are other basemount (also not controled for his controlmaster) it take all of them.. and at lest his rest rider of one of them (it could be not the mount of his master.. but one form nearby, like in the script)
How i can tell to him "MOUNT ONLY on the mount nearby, this one owned by your master"?
SETONNEARBY,1,*,basemount{The one ownwed by your master}/rider/{GETONPARENT,serial} "{GETONPARENT,name}"
It could be:
SETONNEARBY,1,*,basemount/controlmaster={GETONPARENT,controlmaster}/rider/{GETONPARENT,serial} "{GETONPARENT,name}"
Tnx for any answer...anserw...awnser?.....ans... For any help....
Xerocrates- 10-16-2007
Someone? Anyone?
....yone.....yone.....one....ne....
*sigh*
ArteGordon- 10-16-2007
you can add a conditional test to the SETONNEARBY keyword to restrict its application.
from xmlspawner2.txt

QUOTE
- added a property test option to the SETONNEARBY keyword that allows you to restrict the objects selected (thanks to Steelcap for the suggestion). The new syntax is SETONNEARBY,range,name[,type][,searchcontainers][,proptest]/prop/value/prop/value...
So, for example, to set the hue of all nearby creatures with hitpoints of less than 100 to blue you could use something like
SETONNEARBY,10,*,basecreature,false,hits<100/hue/500

Xerocrates- 10-16-2007
I have the same problem of the last time, the server where i play cant upgrade at the second xml because it run on a mod of runUO...
Can you past the string for adding this features to the old version of xmlspawn please?
Tnx for the help
ArteGordon- 10-17-2007
try it like this
Action:SETONNEARBY,1,*,basemount,GETONPARENT,controlmaster.serial=GETONTRIGMOB,serial/rider/{GETONPARENT,serial}
Xerocrates- 10-17-2007
nah, it doesn't work, i most upgrate
tnx for the help
ArteGordon- 10-17-2007
that property restriction feature on SETONNEARBY was added in v3.21 so older versions wont support it.