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
➜ VBscript
➜ Rat killing triggers
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Metsuro
USA (389 posts) Bio
|
Date
| Thu 15 Jul 2004 02:49 AM (UTC) |
Message
| ok here goes... I want a series of triggers to work together, for when, like.
A rat enters.
To check a variable, and if its say like 1, then to kick rat, then set the variable to like 0, but if. You kill a rat appears. I want it to change the variable back to 1, and if the rat is still alive, when i recover balance, i want to have it check the variable again, and attack if the variable is right, any ideas or suggestions would be nice thank you all!
|
Everything turns around in the end | Top |
|
Posted by
| Flannel
USA (1,230 posts) Bio
|
Date
| Reply #1 on Thu 15 Jul 2004 03:42 AM (UTC) |
Message
| You want to attack the rat, if youre not already attacking it, if youre attacking it, and you recover balance, you want to kick it again, and if you kill the rat, you want to stop the balancing attack, and restart the initializing one?
Instead of using variables, you can use the "enabled" flag of the triggers. You would have three triggers.
Trigger 1:
Name: AttInitialize
match: A rat enters.
flags: enabled, keep evaluating, ignore case.
Send to: Script
Send:
world.enabletrigger "AttInitialize", 0
world.enabletrigger "Balance", 1
world.enabletrigger "RatDeath", 1
world.send "kick rat"
Trigger 2:
Name: "Balance"
match: (whatever the balance message is)
flags: keep evaluating, ignore case. (NOT ENABLED)
send to: world
Send: "kick rat"
Trigger 3:
Name: "RatDeath"
match: You kill a rat
flags: keep evaluating, ignore case. (NOT ENABLED)
send to: script
send:
world.enabletrigger "AttInitialize", 1
world.enabletrigger "Balance", 0
world.enabletrigger "RatDeath", 0
Now some comments.
You can rename the triggers, just make sure you change the first and third send texts. You can also change the sequence of the THIRD trigger to be LOWER than the second, having them in the same sequence could be problematic, because you could get 'kill a rat' and then after battle 'you regain your balance' and then it could start you in another battle (that you might not want), so if you change the sequence of the third to lower than the second, it will trigger, and then your balance message wont get triggered. |
~Flannel
Messiah of Rose
Eternity's Trials.
Clones are people two. | Top |
|
Posted by
| Metsuro
USA (389 posts) Bio
|
Date
| Reply #2 on Sat 23 Jul 2005 01:48 PM (UTC) |
Message
| ok quick question, using that above, multiple rats may enter a room and leave during the course of the fight, could someone help me figure out how i could set it up to watch on rats that continue to enter and remove them if they laeve? |
Everything turns around in the end | 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.
12,170 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top