|
dazed-n-confused Novice
Joined: 14 Jan 2004 Posts: 31
|
Posted: Fri Mar 05, 2004 10:04 am
stringlist in an ailias |
I need the ailias to do something like this.
get poison1 from pouch
rub poison1 on dagger
throw dagger at target
then on to the next poison in my list
get poison2 from pouch
rub poison2 on dagger
throw dagger at target
ect.
When it gets to the end of the list I just want it to start over.
I thought I could handle this one but after almost yanking all my hair out I decided to ask for some help *sigh*. |
|
|
|
Serentus Apprentice
Joined: 28 Sep 2001 Posts: 103 Location: USA
|
Posted: Fri Mar 05, 2004 12:55 pm |
Here is one way, it should get you started
#VAR PoisonList {Poison1|Poison2|Poison3}
#VAR PoisonPosition {1}
#alias Daggers {get %item(@PoisonList,@PoisonPosition) from pouch; rub %item(@PoisonList,@PoisonPosition) on dagger;throw dagger at target}
#TRIGGER {You throw a dagger at target} {%IF (@PoisonPosition>=%numitems(PoisonList)) {#VAR PoisonPosition 1} {#ADD PoisonPosition 1}} |
|
|
|
horks Apprentice
Joined: 20 Jul 2001 Posts: 127 Location: USA
|
Posted: Sun Mar 07, 2004 4:32 pm |
Here's just another solution (the previous post would work too)
First, define @NPoison as the starting point:
Then, This alias should work just fine.
Code: |
#ALAIS PoisonDagger {
#VAR PoisonSpot {%concat(poison,@NPoison)};
get @PoisonSpot from pouch;
rub @PoisonSpot on dagger;
throw dagger at target;
#ADD NPoison {1}
}
|
The previous post would require either a list with lots of poison entries, or (as it is written) will only go up to the third poison. The alias I have here will continue to move to the next poison till you redefine @NPoison |
|
|
|
|
|