Timers

by Unknown

Back to Mechanic's Corner.

Unknown2007-10-04 04:36:28
Does anyone have a timer for angels or demons? I have a one that shows up as a gauge but I'd really prefer one that had echos on my screen. I'd do it...but I can't code at all.

I'd appreciate any help.
Simimi2007-10-04 05:07:00
We would need to know your client and scripting language...
Unknown2007-10-04 06:26:20
Zmud...dunno what scripting language...didn't know you could script different languages
Xavius2007-10-04 06:36:29
In zMUD, you don't.

#say gets you an echo.
#alarm +sec will get you a one-time timer. I strongly recommend using +, not *, only because a buggy * call will ruin a good day and never shut up.

So, for example...
#trigger {Your l33t demon roxxors that fish's boxxors!!} {#alarm +6 {#say "**DEMON FIRING IN TWO SECONDS**"}}
...will give you a two second warning for the next demon attack.

Two problems. One, the demon is on a slightly random timer for the first attack. Two, your demon's attacks look just like the attacks of all the other demons in the room. With an appropriate trigger line, the line above will work just fine for solo combat. I don't have any better advice for group combat.
Forren2007-10-04 07:27:15
Alternately, you can make an alarm trigger with pattern *4 (every four seconds) that you disable and enable with ID number. I don't believe time resets if you #T+ that trigger again.
Unknown2007-10-04 10:59:08
I would go with the * recurring timer, too, as Forren suggests. Give it an ID (doesn't have to be a number) and enable/disable as needed. When you enable it, even if it was already enabled, the time does reset.
Malarious2007-10-12 07:21:44
For what its worth I trigger the demon messages to start an alias(which disables the trigs) and another alias (to count_.

The alias calls itself every second to count down, at 2 it gives the #SA warnings at 1 it calls another alarm for .5... (totalling 7.5) which enables the trigs that reset the timer to 8. If for some reason the demon doesnt hit it also stops if it falls below one.

EDIT:
Example

A hideous archdemon vomits forth a stream of noxious fluid that strikes @target,
---DARKSILVER - <> - SCABIES---
coating him with a thick green slime.
With a cold smile, a hideous archdemon digs his claws into the flesh of @target,
---HEMIPLEGY - <> - BLEEDING---
who screams in agony.
4534h, 6474m, 5004e, 10p, 17060en, 27350w elrxk-
<6 seconds later>

DEMON HITTING IN -2- SECONDS
DEMON HITTING IN -2- SECONDS

And yes I also echo what is hitting as well as other things in the event I am mixin it up for some reason (I do that here and there)