Simple Question Zmud Tiggers to Mudlet

Post Reply
brayackmedia
Posts: 3
Joined: Fri Mar 02, 2012 12:05 pm

Simple Question Zmud Tiggers to Mudlet

Post by brayackmedia »

I bought a mac for my production stuff, but I am having serious problems getting to play dunemud with mudlet. My major problem is that I cannot program very well.

I can do basic triggers, but this is the one set of triggers I cannot do. I've been working on this all morning, but could someone please help me!

I have the following triggers:

in game:
HP: 5879/3552 CP: 1169/1182 Autorage: off Slices: 0 Satiation: 0% Enemy: 14%
#TRIGGER {^HP: &{hp}~/&{hpmax} CP: &{cp}~/&{cpmax} Autorage: &{autorage} Slices: &{slice} Satiation: &{sat}~% Enemy: &{enemyhp}~%}

{#if (@hpmax-@hp > 5500) {quit};
#if (@hpmax-@hp > 2500) {#BEEP};
#if (@hpmax-@hp > 2400) {#1 bitch1_ea};
#if (@hpmax-@hp > 2000) {#1 bitch1_ea};
#if (@hpmax-@hp > 1500) {#1 tap};
#if (@hpmax-@hp > 1000) {#1 bitch1_ea};
#if (@sat > 80) {#1 bitch1_thyroxine}}

and
in game:
HPS: 100% CPS: 55% ER: 137 Eaten: 31% Power: 44183 Mother: 0%
#TRIGGER {^HPS: &{hpp}~% CPS: &{cpp}~% ER: &{erations} Eaten: &{eaten}~% Power: (%d) &{vihu}: &{epros}~%$}
{#if (@hpp<=90) {bitch1_ea};
#if (@cpp<=43) {bitch1_ea}}

can someone please fix these for me. I'll be sure to not kill there character if they play on dune <3.

Thanks!

-Dan

Sheia
Posts: 33
Joined: Tue Dec 01, 2009 4:40 am

Re: Simple Question Zmud Tiggers to Mudlet

Post by Sheia »

I'm going to attempt to help you here, though I've never used Zmud or your particular MUD.

^HP: (\d+)/(\d+) CP: (\d+)/(\d+) Autorage: (off|on) Slices: (\d+) Satiation: (\d+)% Enemy: (\d+)%$
Code: [show] | [select all] lua
hp = tonumber(matches[2])
hpmax = tonumber(matches[3])
sat = tonumber(matches[8])
if hpmax - hp > 5500 then send("SomethingAboutaBitch?") else end
if hpmax - hp > 2500 then send("SomethingAboutaBitch?") else end
if hpmax - hp > 2400 then send("SomethingAboutaBitch?") else end
if hpmax - hp > 2000 then send("SomethingAboutaBitch?") else end
if hpmax - hp > 1500 then send("SomethingAboutaBitch?") else end
if hpmax - hp > 1000 then send("SomethingAboutaBitch?") else end
if sat > 80 then send("SomethingAboutaBitch?") else end
^HPS: (\d+)% CPS: (\d+)% ER: (\d+) Eaten: (\d+)% Power: (\d+) Mother: (\d+)%$
Code: [show] | [select all] lua
hpp = tonumber(matches[2])
cpp = tonumber(matches[3])
if hpp <= 90 then send("SomethingAboutaBitch?") else end
if cpp <= 43 then send("SomethingAboutaBitch?") else end
Replace send("SomethingAboutaBitch?") with what ever it is you want these checks to do. I don't know your MUD so I couldn't figure that out. Also not sure why your subtracting your current hp from your max? But I just kept that, and I think you can change that. Please note that this is probably the worst way of doing this. It would be better to make a prompt function in a script and just call it on every prompt. If you explain what your trying to accomplish I may be able to make this better.

brayackmedia
Posts: 3
Joined: Fri Mar 02, 2012 12:05 pm

Re: Simple Question Zmud Tiggers to Mudlet

Post by brayackmedia »

I think this will work out well for me. It doesn't have to be clean, but just help.

Basically I get a command prompt every round such as:

1000hp/2000hp etc etc etc. I want to be able to heal if my HP goes 1000 HP below the max. The total hp changes constantly, so I can't just heal when I go below 90 percent, but I have to calculate that.

FYI I had bitch1_ gagged in zmud so I wouldn't have to see my combat spam.

I'll try it out here but am pretty sure you nailed it. Thanks again!

-Dan

brayackmedia
Posts: 3
Joined: Fri Mar 02, 2012 12:05 pm

Re: Simple Question Zmud Tiggers to Mudlet

Post by brayackmedia »

It works perfect!

Sheia
Posts: 33
Joined: Tue Dec 01, 2009 4:40 am

Re: Simple Question Zmud Tiggers to Mudlet

Post by Sheia »

Glad to hear it!

Post Reply