 |
Palek Wanderer
Joined: 28 Sep 2005 Posts: 55
|
Posted: Wed Sep 28, 2005 8:27 pm
Sending commands after #walk completes ***Solved*** |
Howdy all,
I am trying to setup a trigger that will walk to a room then execute a command after the #walk command completes. The best I can come up with at this point is using an alarm timer to run it but then on short walks you are waiting around for the alarm to trigger. here is the code I am using for this:
| Code: |
#TRIGGER {(%w). The package can be picked up from:$ -----$&pickuproom
#var pickupzone %1
#walk {@pickuproom} {@pickupzone}
#alarm +20 {#if %inwalk {#show still walking} {#send pickup}}}
|
This works but is inefficent, any help would be appreciated.
An example of the triggering text is:
Your task is to pick up a package on Cube. The package can be picked up from:
-----
Cube Cafe
The seating arrangements in this small cafe are by cubicle only so you may have to look around to find an empty one. An exit is southeast.
-----
Delivery details will be provided when you collect the package.
Thanks again.
Jamie |
|
Last edited by Palek on Wed Sep 28, 2005 11:28 pm; edited 1 time in total |
|
|
 |
Vijilante SubAdmin

Joined: 18 Nov 2001 Posts: 5187
|
Posted: Wed Sep 28, 2005 9:24 pm |
Check out the onwalkend special alias. This alias is automatically called when a speedwalk ends.
|
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
 |
Palek Wanderer
Joined: 28 Sep 2005 Posts: 55
|
Posted: Wed Sep 28, 2005 9:52 pm |
Ok I change the trigger to look like this:
| Code: |
#var pickupzone %1
#ALIAS (walk) {
#walk {@pickuproom} {@pickupzone}
#ALIAS onwalkend {pickup}
}
|
Now when the triggering text comes up it does nothing at all.
Tried appending walk to the end of it, it walks to the location but does not execute the onwalkend command.
tried appened walk and onwalkend to the end of this and it does the same as just putting the command after the walk command it executes it in the middle of the walk.
Jamie |
|
|
|
 |
Palek Wanderer
Joined: 28 Sep 2005 Posts: 55
|
Posted: Wed Sep 28, 2005 11:30 pm |
While researching onwalkend I came acrossed a solution:
| Code: |
#var pickupzone %1
#ALIAS onroomenter {#IF (@pickuproom=%roomid) {pickup}}
#walk {@pickuproom} {@pickupzone}
|
This works perfectly.
Thanks for pointing in the right direction.
Jamie |
|
|
|
 |
|
|
|