Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
crimsondarksky
Newbie


Joined: 14 May 2005
Posts: 2

PostPosted: Sat May 14, 2005 8:07 pm   

Issues with brackets and such....
 
OKay, I have been working on my gauges for about 3 hours now....

This is EXACTLY how my prompt looks on the mud - I will break it down:

276[0]276 270/270 V/:03:37 pm:\V V~|(10)|~V

276(hp)[0(damage taken from last round)]276(maxhp)

270(sp)/270(maxsp)

V/:03:37 pm:\V the time surrounded by design stuff

V~|(10 (blood level))|~V

I would LIKE to keep my hpbar the way it is - if possible...
the issue I am having is that I cannot get the gauges to read it... I tried using the quick VAR by going i.e. &{hp}, but that didn't work...my gauges wouldn't update.

Could anyone help me write out a gauge for my hp and sp?
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Sun May 15, 2005 1:13 am   
 
#TRIGGER {&HP~[0~]&MaxHP &SP/&maxSP V/:03:37 pm:\V V~~~|~(10~)~|~~V}
Reply with quote
gamma_ray
Magician


Joined: 17 Apr 2005
Posts: 496

PostPosted: Sun May 15, 2005 5:47 am   
 
#REGEX {^(\d+)[(\d+)](\d+) (\d+)/(\d+) V/:(\d\d:\d\d [ap]m):\V V~\|\((\d+)\)\|~V} {hp = %1;hpChange = %2;hpMax = %3;sp = %4;spMax = %5;time = %6;blood = %7}

You can also use the in-trigger variables with RegEx, but I've found that it tends to make gauges flicker (very annoying). It'd look like this:

#REGEX {^(?hp:\d+)[(?hpChange:\d+)](?hpMax:\d+) (?sp:\d+)/(?spMax:\d+) V/:(?time:\d\d:\d\d [ap]m):\V V~\|\((?blood:\d+)\)\|~V}
Reply with quote
crimsondarksky
Newbie


Joined: 14 May 2005
Posts: 2

PostPosted: Sun May 15, 2005 4:55 pm   
 
Alrighty,

I tried all three of those, but I got nowhere. What I did, was I went into settings and clicked on new trigger. then I copy and pasted the whole line into the value spot of the trigger. It did nothing - I had nothing in the gauges line except for the 'Value,Gaugelow and Gaugemax'. I renamed all the variables to match the ones in the line.

If someone is willing, could you give me a bit of a walkthrough on it. If I can get a basic setup - I can jimmy with it from there.
Reply with quote
gamma_ray
Magician


Joined: 17 Apr 2005
Posts: 496

PostPosted: Sun May 15, 2005 6:54 pm   
 
Er, the triggers posted should be pasted into the command line to work (since they're prefixed by #TRIGGER and #REGEX). If you want to use the settings editor:

New trigger
Paste in this line:
Code:
^(\d+)\[(\d+)\](\d+) (\d+)/(\d+) V/:(\d\d:\d\d [ap]m):\V V~\|\((\d+)\)\|~V

tick the "Perl regular expression" box below the Pattern box
Paste this into the Value box:
Code:
hp = %1
hpChange = %2
hpMax = %3
sp = %4
spMax = %5
time = %6
blood = %7

Then when you're making your gauges, the caption should be something like
Code:
HP: @hp / @hpMax

and the Gauge tab..
Value:
Code:
@hp

Gauge Max:
Code:
@hpMax
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net