Reply to this subject
Start a new subject
 
Refresh page
| Posted by |
Aryzure
(3 posts) bio
|
| Date |
Sat 26 Jul 2003 05:14 PM (UTC) [ quote
] |
| Message |
| I was wondering how you can make it so that when you type in a certain thing, like "kill boy" it would become your target so you can use a variable for all the monsters. Like...I type kill boy, and i have an alias set for fireball. The alias would be FB and it'd say fireball @kill or something...then, whoever i had targeted gets fireballed. I dont quite remember how to do this, so can anyone help me? | top |
|
| Posted by |
Nick Gammon
Australia (18,772 posts) bio
Forum Administrator |
| Date |
Reply #1 on Sat 26 Jul 2003 10:54 PM (UTC) [ quote
] |
| Message |
This should do it. The first alias, "kill *" sends the kill command, and also remembers the target. The second one, "FB" uses the saved target.
<aliases>
<alias
match="kill *"
enabled="y"
send_to="12"
omit_from_output="y"
sequence="100"
>
<send>Send "kill %1"
SetVariable "target", "%1"</send>
</alias>
<alias
match="FB"
enabled="y"
echo_alias="y"
expand_variables="y"
sequence="100"
>
<send>fireball @target</send>
</alias>
</aliases>
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
| Posted by |
Aryzure
(3 posts) bio
|
| Date |
Reply #2 on Sun 27 Jul 2003 01:26 AM (UTC) [ quote
] |
| Message |
| Alright, thanks a ton man! Sorry, but I forgot to ask how to make a variable. I use to a long time ago but I got a short memory span and forgot how to. | top |
|
| Posted by |
Nick Gammon
Australia (18,772 posts) bio
Forum Administrator |
| Date |
Reply #3 on Sun 27 Jul 2003 01:58 AM (UTC) [ quote
] |
| Message |
It's in the alias above:
SetVariable "name", "contents"
You can also do it in the world configuration screen - Variables tab. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
1,404 views.
Reply to this subject
Start a new subject
 
Refresh page
top
Comments to:
Gammon Software support
Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )