I have made an autorescue trigger. My trigger works fine, but after some field testing I have run into the problem that I want to only try to rescue the person once every 5 seconds or so. This is due to my mud having lag penalties for rescue so if multiple people get attacked I end up trying to rescue each one about 5 times before I am out of lag from the first one.
I also have a trigger that automatically adds people to the variable "group". I can post it if you would like it.
Here is what I have:
Again really if my variable contains:
Mike|Fred|Jim
and Fred gets attacked I only want to send the rescue once. I considered building into the trigger a line that disabled the trigger and activated a timer for 5 seconds that would run once and re-enable the trigger. The problem with this is if another groupie gets attacked while the trigger is disabled I would not be able to get them.
Thanks for any input you could give me.
I also have a trigger that automatically adds people to the variable "group". I can post it if you would like it.
Here is what I have:
<triggers>
<trigger
enabled="y"
expand_variables="y"
ignore_case="y"
keep_evaluating="y"
match="(?U)^(?!You)(.*) (attack|attacks) (strikes|strike|haven't hurt) (@!group) (?!you)(.*) (time|times), with * *."
name="Autorescue_1"
regexp="y"
sequence="100"
>
<send>rescue %4</send>
</trigger>
</triggers>
<triggers>
<trigger
enabled="y"
expand_variables="y"
ignore_case="y"
keep_evaluating="y"
match="(?U)^(?!You)(.*) attacks haven\'t hurt (@!group)\!$"
name="autorescue_2"
regexp="y"
sequence="100"
>
<send>rescue %2</send>
</trigger>
</triggers>
<triggers>
<trigger
enabled="y"
ignore_case="y"
match="^You fail to rescue (.*?) from"
name="I_Fail_Rescue"
regexp="y"
sequence="100"
>
<send>rescue %1</send>
</trigger>
</triggers>
Again really if my variable contains:
Mike|Fred|Jim
and Fred gets attacked I only want to send the rescue once. I considered building into the trigger a line that disabled the trigger and activated a timer for 5 seconds that would run once and re-enable the trigger. The problem with this is if another groupie gets attacked while the trigger is disabled I would not be able to get them.
Thanks for any input you could give me.