help

Posted by Leon on Tue 26 Oct 2004 02:49 PM — 2 posts, 11,092 views.

#0
How to compse a vb script which would do as follows:
1. perform an action, for example "look".
2. wait for 10 seconds.
3. perform action "go <directrion> and direction is taken from txt file.

the scripts runs until last direction in the txt file, file body exaple: n, se, ne.

Leon
USA #1
Does the direction have to be taken from a text file? Since that adds a lot of complexity.
You can (assuming youre writing to a text file, or whatever) just as easily put it in a variable, and then read it from that.

Use a DoAfter (MC function) to add your timer (since you cant wait 10 seconds from within the script engine).

Once you get the string (which is delimited by commas it looks like) you can just parse it into an array (using the VB function "split") and then read through the array and send "go XXX" where XXX is the contents of your current array location.

If you want to add a time delay between things being sent, you can always use a speedwalk queue, and then youll use the array to queue things.