Sounds for MUD combat options

Posted by Dukeskath on Thu 08 Aug 2024 06:25 PM — 1 posts, 3,836 views.

#0
I like to have sounds for everything in MUDs. I recently figured out how to use regex to tackle combat in Aardwolf:

Quote:

<triggers>
<trigger
custom_colour="17"
enabled="y"
ignore_case="y"
keep_evaluating="y"
match="(rends|eradicates|disembowels|obliterates|incinerates|extirpates|devastates) you*"
regexp="y"
send_to="12"
sequence="100"
other_text_colour="white"
other_back_colour="#5C1212"
>
<send>PlaySound(0, "PATH/sound.wav", false)
</send>
</trigger>
</triggers>


The custom color bits aren't necessary, but they're helping me track when the trigger fires.

Now I just need to add all the various verbs into the parenthetical area and the sound will play every time I'm hit.

I'm sure this isn't a big deal to most folks, but I thought I'd share in case anyone else is trying to achieve this.