View Full Version : Pulling Stamina GSL variable through Zmud?
Martaigne
04-01-2007, 01:39 AM
Anyone know how to do this? Health, Mana, and Spirit are super easy but I can't find any documentation on Stamina.
Thanks in advance.
TheEschaton
04-01-2007, 10:10 AM
I imagine it's the same format as those variables. When zMUD first became compatible with GS, there was no stamina stat.
-TheE-
Martaigne
04-01-2007, 12:38 PM
ZMud automatically pulls those three and inserts them into default variables for easy use, but not stamina. I'm trying to decode the GSL stream to pull it out myself. I'm using 7.21, but nothing on zuggsoft forums. Or google, for that matter. I tried logging the GSL stream, but I don't see anything that pertains to that particular stat.
Bobmuhthol
04-01-2007, 12:43 PM
Is there a stamina bar in StormFront? I'm kind of wondering if stamina has a GSL tag whenever it changes, since I know the Wizard FE doesn't have to refresh it. I never looked into it when I was tracing GSL tags so I can't be of much use other than to say it either might not exist or you'll have to read the stream more closely.
Martaigne
04-01-2007, 12:50 PM
Hm, I don't know. I'll pull up SF and find out. I usually use Wizard for travel scripts until I can adapt them to Zmud.
Martaigne
04-01-2007, 12:54 PM
Yep, at the bottom, all in a row:
Health, Mana, Stamina, Spirit.
There is also displays for exp til level, exp buffer, MTPs, PTPs, TP conversion, posture, and bounties.
Perhaps I have to fool the game into thinking I'm using SF to get the proper stream? I'll post a short log of my GSL stream via Zmud in a moment.
Martaigne
04-01-2007, 01:03 PM
Welcome to GemStone IV (R) v5.10
Copyright 2007 Simutronics Corp.
All Rights Reserved
GSmEmpty
GSlEmpty
GSg0000000100
GSnNone
GSV00000001560000000156000000000800000000080000000 002000000000200000000000000000000
GSFB0000000000GSFM0000000000GSFP0000000000
GSrA
GSPK
GSPK
GSPK
The bolded line appears to be my health (156), spirit (8), and mana (2), I can only guess that the last part would be stamina (which should be 78) if it saw my FE as SF?
I also tried this in Wizard and Web Client compatibility modes, with the same results. There is no SF compatibility mode for ZMud yet.
Bobmuhthol
04-01-2007, 01:08 PM
Ah, you're actually using zMud to see the tags. I never played around with it; I always used Wizard and a third-party packet sniffer to see the raw data as it came. If you did the same thing with StormFront, you'd likely get your answer.
TheEschaton
04-01-2007, 01:08 PM
eh. Is there another line somewhere labelled GSV?
-TheE-
Martaigne
04-01-2007, 01:14 PM
Ah, you're actually using zMud to see the tags. I never played around with it; I always used Wizard and a third-party packet sniffer to see the raw data as it came. If you did the same thing with StormFront, you'd likely get your answer.
Got a recommendation for one?
eh. Is there another line somewhere labelled GSV?
-TheE-
Nope, not even after a few minutes playing around bullrushing and killing roltons to update my stamina value. The only one I saw was at the beginning.
Bobmuhthol
04-01-2007, 01:17 PM
http://www.ethereal.com/download.html
This is what I was using a while ago.
Martaigne
04-01-2007, 01:19 PM
Thank you sir. I'll get this installed and running and I'll report back shortly.
Martaigne
04-01-2007, 01:29 PM
Well, SF uses a constant XML stream to update the frontend.
<dialogData id='minivitals'>
<skin id='healthSkin' name='healthBar' controls='health' left='0%' top='0%' width='25%' height='100%'/>
<progressBar id='health' value='100' text='health 156/156' left='0%' customText='t' top='0%' width='25%' height='100%'/>
</dialogData>
<dialogData id='minivitals'>
<skin id='manaSkin' name='manaBar' controls='mana' left='25%' top='0%' width='25%' height='100%'/>
<progressBar id='mana' value='100' text='mana 2/2' left='25%' customText='t' top='0%' width='25%' height='100%'/>
</dialogData>
<dialogData id='minivitals'>
<skin id='spiritSkin' name='spiritBar' controls='spirit' left='75%' top='0%' width='25%' height='100%'/>
<progressBar id='spirit' value='100' text='spirit 8/8' left='75%' customText='t' top='0%' width='25%' height='100%'/>
</dialogData>
<dialogData id='minivitals'>
<skin id='staminaSkin' name='staminaBar' controls='stamina' left='50%' top='0%' width='25%' height='100%'/>
<progressBar id='stamina' value='100' text='stamina 78/78' left='50%' customText='t' top='0%' width='25%' height='100%'/>
</dialogData>
Martaigne
04-02-2007, 01:58 AM
Well, I managed to do it, but I think it's sloppy. I used the ticker, the 'stamina' command, a trigger, and a few creatively placed gags to create my stamina meter. It updates every 15 seconds. It works, and until I find out if I can get stamina from the GSL stream, it'll have to do.
Celephais
04-02-2007, 02:40 PM
Well, I managed to do it, but I think it's sloppy. I used the ticker, the 'stamina' command, a trigger, and a few creatively placed gags to create my stamina meter. It updates every 15 seconds. It works, and until I find out if I can get stamina from the GSL stream, it'll have to do.
I think if you really felt like doing things right you could turn off the ZMud GSL interpretation entirely and do some parsing of the stormfront tags yourself. I had started working on a SF->GSL conversion to allow for the extra data SF has to be used in the WizFE, but I'm a huge vaporware person and it never got very far (that and I hate the WizFE). But it sounds like you know what you're doing enough to go that route, you'll be much happier than working w/ the GSL tags, there is a lot more info hidden in the SF tags to work with. The biggest being the unique IDs for every object (so your code can tell the difference between "rat" and "other rat")
Martaigne
04-02-2007, 03:36 PM
This is an interesting idea. I'll have to make a longer session log with SF and see what I can pull from any constant streams.
Celephais
04-02-2007, 03:56 PM
This is an interesting idea. I'll have to make a longer session log with SF and see what I can pull from any constant streams.
Anything that's in the GSL is in the stormfront tags. You'll have to set up gags and triggers to fill in variables for you that would normally be your GSL variables, but once you get them all set you'll have a lot more to work with; and you'll be able to do things like highlight links in rooms to give you hints as to what the noun is for a given object (the tags have a noun property for every object, as well as the unique ID), or use the room tags to tell you when people pop in and out of hiding.
I had started working on a SF->GSL conversion to allow for the extra data SF has to be used in the WizFE, but I'm a huge vaporware person and it never got very far (that and I hate the WizFE).
Haha very true, you've started a lot of things!
Celephais
04-02-2007, 04:47 PM
Haha very true, you've started a lot of things!
I get all gung-ho about a project and then find myself "quiting" GS for a while... so I'm mostly vaporware. I haven't actually played in a few months now, but I'm starting to re-visit the forums more frequently, maybe I'll hit a stride soon. RL has been keeping me real busy too...
Shaelun
04-06-2007, 04:59 PM
If it's of use, my notes on the Wizard stuff is attached.
Martaigne
04-06-2007, 07:13 PM
Thanks... no stamina attribute, but still some handy notes.
I've released the first version of my GS4 meters over on Zuggsoft's forums, feel free to take a look and offer constructive criticism.
http://forums.zuggsoft.com/phpbb/viewtopic.php?t=26997
TheEschaton
04-06-2007, 07:16 PM
Now I'm gonna need to re-download zMUD onto my old computer, and hope they'll accept my registration code from 98
-TheE-
Shaelun
04-06-2007, 07:34 PM
The vast majority of that's greek to me (never used or worked with zMUD), but off-hand:
#TRIGGER {Roundtim* (%d) sec*} {#ADD roundtime %1;#var roundtimemax %1;#math RT @roundtime*1000};
If that's a regular expression and zMUD supports negated character sets (in most Regex "dialects" you do this with [^c]), it's a lot more efficient to do something like Roundtim[^\s]* than Roundtim*.
Hard RT is almost always described with a line of "Roundtime: 2 sec." and soft RT is almost always "Cast Roundtime 3 Seconds." Don't know if that's useful in separating the two (note the colon as opposed to the lack thereof), but there it is either way. Also, "Roundtime changed to 1 second." is how I've always seen it announce haste: it appears before the "Roundtime:" line on at least some actions though, so you'd have to somehow disable that trigger for one match and then re-enable it or something.
I think somebody already mentioned it, but there's no stamina tag because Wizard doesn't have one (nor does the game when talking to Wizard).
Martaigne
04-06-2007, 08:55 PM
Yeah, I didn't have a chance to play with Haste roundtimes until last night, or casting (soft) roundtimes because I play squares, until I noticed that when I rubbed a small statue it gave me roundtime.
I also adapted this script from a previously posted one on the Zuggsoft forums. That trigger match is all theirs. What I'll do is turn it into a hard and soft RT meter, I think, to benefit spellcasters as well, then use the Haste messaging to change rather than add to the total roundtime.
Martaigne
04-06-2007, 09:12 PM
Okay, I've got Roundtime and Cast roundtime in seperate meters, treated seperately. I'll have to get in touch with a wizard friend tonight and experiment with the haste messaging so that I can insert a proper condition.
Shaelun
04-06-2007, 09:15 PM
Sounds good, but incase I'm not misunderstanding what you mean, the haste bit will cause problems. For example, when I type "wait" with haste (technically 1035, "Song of Tonis" -- make sure it's not different for haste), this comes up in my game window:
Time drags on by...
Roundtime changed to 1 second.
Roundtime: 2 sec.
Unless you somehow compensate for the haste "changed to" line coming directly before the unmodified "Roundtime:" line, you're going to need to disable the "Roundtime" trigger so it doesn't increment the RT.
If zMUD provides the ability to access the lines Simu sends that are meant only for the front-end to update its graphical displays, you can just go off of "GSQ" (your roundtime is guaranteed to be the "GSq" number subtracted from the "GSQ" number).
Martaigne
04-06-2007, 09:24 PM
Ooh, I'll take a look at that variable then. Thanks for the heads up.
Martaigne
04-07-2007, 12:54 AM
Just a couple examples of roundtimes and haste messaging being in disparately different locations. This is going to be a difficult one to figure out, because I could use #COND to alter the roundtime if it ALWAYS showed up after a roundtime adder, but since it doesn't... gonna have to wrap my head around it.
You attempt to throw a firephantom!
Roundtime changed to 2 seconds.
MB: 127 vs MB: -26 = 153 -- Gain advantage!
Expert maneuver! Perfect position.
THT 69, d100 roll: 5, modified: 158
... +3 extra hits. Foe thrown to ground and stunned in a nice move.
Roundtime: 4 sec.
You swing a pitted steel greatsword at a firephantom!
AS: +154 vs DS: -68 with AvD: +41 + d100 roll: +71 = +334
... and hit for 171 points of damage!
Strong assault amputates the leg at the knee.
It floats in the air a moment before drifting back into place!
You hear a sound like a weeping child as a white glow separates itself from the firephantom's body as it rises, disappearing into the heavens.
The firephantom slowly settles to the ground and begins to dissipate.
Roundtime: 5 sec.
Roundtime changed to 3 seconds.
Shaelun
04-07-2007, 01:48 AM
I have no idea how to do this in zMUD, but if you can access the status data sent from the game, just subtract whatever number "GSq" last was from the number in the "GSQ" string and set your roundtime to be that.
If you can't do that with zMUD... well, guess I'll just say good luck finding a reliable way to compensate for an unpredictable response. Not impossible, but I wouldn't call it worth the trouble.
Martaigne
04-07-2007, 03:24 AM
I did try it that way, triggering it to pull those variables and do the math whenever it saw the round time messaging. So far all my results were '0', despite the numbers being different. Still working on it.
Shaelun
04-07-2007, 03:40 AM
Could you be mistaken about the order in which they're sent to the game...? Or is it possible that zMUD is treating the numbers as strings instead of actual numbers, and so not subtracting them the way you want?
From Lich's "echo" script (set to display unmodified data), which does nothing but echoes a copy of any strings it sees:
>wait
Time drags on by...
Roundtime: 2 sec.
[echo: "\034GSQ1175927477"]
[echo: "Time drags on by..."]
[echo: "Roundtime: 2 sec."]
[echo: "\034GSq1175927475"]
(the "\034" prefix is the ASCII code for the character Simutronics uses to signify to Wizard that the line is a status update, not game text)
Lich goes off the "GSQ" and "GSq" lines (I guess you might call them its "triggers"), not the line you see in your game window. There are times when you have to do it that way (for example, I think if you get hit with a CMAN FEINT). I'm positive that Lich properly tracks your current RT, but anything beyond the basic idea being sound I can't comment on.
I also can't think of any other reliable way of doing it. Sorry I can't be of more help.
Good luck.
Martaigne
04-07-2007, 10:43 AM
Or is it possible that zMUD is treating the numbers as strings instead of actual numbers, and so not subtracting them the way you want?
This is exactly what I think is going on, so I'll have to do the %number conversion to the values to get the correct results, I believe.
You've been plenty of help, and it's appreciated. Thank you. :)
Celephais
04-07-2007, 02:31 PM
Haven't used ZMud in forever, but here is my old setting file... essentially it has everything the wizard had plus durations for wizard spells, exp tll level settings, and indicators for COL skills. There might be more stuff but I don't have any time to mess w/ it right now.
http://www.deadlylight.com/images/zmud.jpg
www.deadlylight.com/gemstoneIII.zip (http://www.deadlylight.com/gemstoneIII.zip)
Martaigne
04-07-2007, 04:46 PM
Wow, that's the motherlode! Thanks! I'm not using any bitmaps for sake of transportability, but I can probably make use of a lot of this code. I appreciate it!
Celephais
04-07-2007, 06:03 PM
Wow, that's the motherlode! Thanks! I'm not using any bitmaps for sake of transportability, but I can probably make use of a lot of this code. I appreciate it!
No problem, and good luck with it, if you find any posts on the zMud board by GuinnessKMF they were me. I don't use zMud anymore and I've completely forgotten the scripting language but if any of my triggers/aliases/whatever don't make any sense I'll be glad to try to decipher them. That was made during my warrior mage phase, so I'm pretty sure haste is working in the timers too.
Martaigne
04-07-2007, 06:24 PM
Actually I've already gotten your RT code working with my gauge. I'll be testing it with haste tonight, but looks like it works fine so far. I think I'll go digging through and pull our your positioning code too.
Thanks a lot for posting that!
Martaigne
04-07-2007, 06:41 PM
Here's a cap of the gauge area of zmud to show the simplicity and functionality:
http://www.martaigne.com/images/zmud.gif
TheEschaton
04-07-2007, 07:24 PM
I fucking love zMUD.
-TheE-
Kranar
04-07-2007, 07:38 PM
I fucking love zMUD.
-TheE-
Hahaha, yeah zMUD is a very well designed client. Too bad it's not open source.
Martaigne
04-09-2007, 08:22 PM
Updated screen cap to show new features, see above!
Celephais
04-09-2007, 08:59 PM
Updated screen cap to show new features, see above!
looking good and clean, nice job.
Martaigne
04-10-2007, 04:17 AM
Thanks! I just added the Compass, and I have a Prepared Spell indicator now.
Martaigne
04-10-2007, 02:31 PM
http://forums.zuggsoft.com/phpbb/viewtopic.php?t=26997
Updated again. Posted recent screen caps, separated the code segments, and gave credit where credit is due. Thanks for your help guys.
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.