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
➜ Lua
➜ Adding i new alias with AddAlias in lua
Adding i new alias with AddAlias in lua
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Jedhi
(37 posts) Bio
|
Date
| Sat 17 May 2014 09:31 AM (UTC) |
Message
| Hello,
i do not understand alias flags. how can i make alias both enabaled and using regular expression?
AddAlias(
'someName',
'the command',
'say testing',
1
)
1 will enable. how to add other flags?
i want to use this function so i do not have to add stuff in the xml format. | Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #1 on Sat 17 May 2014 08:24 PM (UTC) Amended on Sat 17 May 2014 08:26 PM (UTC) by Nick Gammon
|
Message
| You add them together like this:
AddAlias(
'someName',
'the command',
'say testing',
1 + 128
)
For better documentation use the built-in names, eg.
AddAlias(
'someName',
'the command',
'say testing',
alias_flag.Enabled + alias_flag.RegularExpression
)
These are documented here:
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #2 on Sat 17 May 2014 08:25 PM (UTC) |
Message
| Remember, if you are replacing an existing alias of the same name, use the "Replace" flags as well. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Jedhi
(37 posts) Bio
|
Date
| Reply #3 on Sun 18 May 2014 10:06 AM (UTC) |
Message
| |
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.
13,738 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top