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
➜ Bug reports
➜ AddTrigger
It is now over 60 days since the last post. This thread is closed.
Refresh page
| Posted by
| tobiassjosten
Sweden (79 posts) Bio
|
| Date
| Tue 17 May 2005 09:49 PM (UTC) |
| Message
| | Don't know if this is a LUA-bug or a MC-bug, but here goes.. When I try to use the AddTrigger command from an "external" lua-file of mine, it wont add the trigger if its name collides with the script-part of another one. Got a trigger named "" which executes "balLostHerb", and I wanted to add a trigger named "balLostHerb". It didn't let me (no message or anything), until I tested to change the name to "balaLostHerb". |
Simplicity is Divine | http://nogfx.org/ | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #1 on Sun 22 May 2005 07:46 AM (UTC) |
| Message
| | Not sure if I know what you mean by the script-part. Can you post the actual AddTrigger command? |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| tobiassjosten
Sweden (79 posts) Bio
|
| Date
| Reply #2 on Sun 22 May 2005 09:10 AM (UTC) |
| Message
| It's gone, I'm afraid, but I could try to explain.. Let say we have a trigger looking like this:
<trigger
enabled="y"
keep_evaluating="y"
match="^whatever$"
regexp="y"
script="theScript"
sequence="100">
</trigger>
Then MUSHclient wont let me do the command:
AddTriggerEx ("theScript", "* attacks", "You are under attack!", trigger_flag.Enabled, custom_colour.Custom15, 0, "", "", 12, 50)
..because the new trigger's name collides with the above trigger's associated function's name. See what I mean? |
Simplicity is Divine | http://nogfx.org/ | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #3 on Sat 15 Oct 2005 02:35 AM (UTC) |
| Message
| I successfully added that trigger.
What error code did you get from the AddTriggerEx?
Unless you have the "replace" flag on you cannot add the same named trigger twice, perhaps that is what is happening?
Also, if you specify a script routine the script must exist. |
- 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.
15,523 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top