Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.

Due to spam on this forum, all posts now need moderator approval.

 Entire forum ➜ MUSHclient ➜ General ➜ Highlight what is being attacked when variable is called

Highlight what is being attacked when variable is called

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Gronka   (4 posts)  Bio
Date Tue 07 Aug 2018 08:30 AM (UTC)

Amended on Tue 07 Aug 2018 08:39 AM (UTC) by Gronka

Message
I have variable for target.
I have alias for attacking target.
I want to pop up a Blue note saying Attacking: @target

Variable:
<variables>
<variable name="target">s</variable>
</variables>

alias for attacking target
<aliases>
<alias
match="3some"
enabled="y"
expand_variables="y"
group="combat"
sequence="100"
>
<send>kill @target
aim 2.@target
aim 3.@target
treport</send>
</alias>
</aliases>


alias for treport as I was hoping it I use a second alias it would to there coloring part since I need a script in this alias. Can you put a script in an alias and send to world at same time? I think that would solve it.

<aliases>
<alias
match="treport"
enabled="y"
expand_variables="y"
send_to="12"
sequence="1"
>
<send>ColourNote ("white", "blue", "Attacking: @target")</send>
</alias>
</aliases>

treport ends up sending to world with no colour note.
Top

Posted by Nick Gammon   Australia  (23,140 posts)  Bio   Forum Administrator
Date Reply #1 on Tue 07 Aug 2018 08:27 PM (UTC)
Message
Quote:

Can you put a script in an alias and send to world at same time?


Yes, you can Send stuff, eg.


Send ("kill @target")

- Nick Gammon

www.gammon.com.au, www.mushclient.com
Top

Posted by Gronka   (4 posts)  Bio
Date Reply #2 on Wed 08 Aug 2018 04:10 AM (UTC)
Message
Well turns out that was pretty simple by adding your comment. Doing the below gives me the message I wanted on the screen and engages my targets. Thanks for your help!

<aliases>
<alias
match="some"
enabled="y"
expand_variables="y"
group="combat"
send_to="12"
sequence="100"
>
<send>ColourNote ("white", "blue", "Mass attacking: %1")
Send ("kill @target")
Send ("aim 2.@target")
Send ("aim 2.@target")</send>
</alias>
</aliases>
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.


9,500 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.