|
Rappy Wanderer
Joined: 15 Jul 2005 Posts: 96
|
Posted: Tue Mar 17, 2009 5:28 pm
Status bar |
Am I to understand you can't blank the status bar in cMUD? I've tried #ST {} #ST "" #ST {anything} and it APPENDS it to the line rather than replacing it. In zMUD you could just issue a #ST "" and the status was blanked.
Nevermind, adding an ID to the status definition does what I wanted.
-Rappy |
|
_________________ Windows 11 Pro,
cMUD 3.34 |
|
|
|
Fang Xianfu GURU
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Tue Mar 17, 2009 10:31 pm |
I've split this thread to keep the KB clean.
Creating and deleting settings is slow, and so often isn't the best solution. What you can do instead is have multiple status items, each for a single thing you want to show on the status line. So you'd have:
#st {HP: @hp}
#st {Affects: @affectnum}
and so on, each with its own ID or its own class (I didn't add IDs to these because I'd probably use classes). Then instead of blanking the status line with the #st command, you just disable the classes to disable the individual status items. If you want to be able to completely blank out the status line, you could put all the classes containing the status line entries into a single class, and then enable and disable that class to control them all at once. You can use whatever class structure you like to control them in sets. |
|
|
|
Rappy Wanderer
Joined: 15 Jul 2005 Posts: 96
|
Posted: Tue Mar 17, 2009 11:04 pm |
Thanks.
Does that autoformat them on the bar?
I am on zMUD trying to help someone with cMUD, so I can't test myself to find out.
If I have 4 elements, do they keep their position? Or do they jumble around. IE. If have have...
#ST {HP: @hp}
#ST {MA: @ma}
#ST {MV: @mv}
... and I turn off the MA one... does MV move over to where MA was? Also, if I enable MA again, does it get placed at the end? These answers will greatly help me help the other user =)
-Rappy |
|
_________________ Windows 11 Pro,
cMUD 3.34 |
|
|
|
Leitia Adept
Joined: 04 May 2007 Posts: 292 Location: Boston
|
Posted: Tue Mar 17, 2009 11:14 pm |
omg ty
Was going nuts working what couldn't be done. Really it was because I am trying to understand the roots of pkgs and how mods interact though trial upon trial.
I will need 12 folders to do this window thing. I used to be able to use %format() but am unsure how that is working for me after seeing my MumeMod2 root suck my stwin into it's vortex of unintelligibility. I am sure I will get the hang in time and simply check the right box. just how strange these imports became in my case.
To eventual perfection. |
|
Last edited by Leitia on Tue Mar 17, 2009 11:20 pm; edited 2 times in total |
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Tue Mar 17, 2009 11:16 pm |
Yes, if you disable one of the status items, the status line is redrawn using only the enabled status items. I believe that the order is determined by their priority, but I'm not certain and can't check just now.
|
|
|
|
Leitia Adept
Joined: 04 May 2007 Posts: 292 Location: Boston
|
Posted: Tue Mar 17, 2009 11:25 pm |
curious what advantage the status window has over creating a window now and putting a trigger in the window to #clr?
Edit:
I made a trigger on 'clearme' with a value of #clr, then converted my stw into #window target, so far its clean, though I was only using stw + so thats not really useful for you guys I spose |
|
|
|
Fang Xianfu GURU
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Wed Mar 18, 2009 12:01 am |
Rappy wrote: |
Does that autoformat them on the bar? |
What do you mean?
And no, it won't leave gaps, it'll display left to right only the items that're enabled, in priority order starting from 1. Keeping things in exactly the same spot on the status bar is difficult because the status bar font isn't fixed-width.
Leitia wrote: |
[I am] curious what advantage the status window has over creating a window now and putting a trigger in the window to #clr? |
Basically because you don't need to bother doing all that stuff yourself. You don't need to build systems to redraw text in it, to display only the text you want, to expand some things but not others, and so on. The stuff the status window can do, it'll do without you having to write it yourself. |
|
|
|
Tech GURU
Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Wed Mar 18, 2009 4:12 am |
I take a slightly different approach. I have pretty complex status menu (I use MXP to do a click driven menu interface) but I just put one variable into my status window, and keep updating the string value of the variable for that status window. Just another approach to consider.
|
|
_________________ Asati di tempari! |
|
|
|
Fang Xianfu GURU
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Wed Mar 18, 2009 5:06 am |
I was originally going to suggest that, but the main drawback of it is that it doesn't change as variables inside the string change like it normally would. So:
StatusString = %concat("HP: ",@hp)
#status {@StatusString}
This won't refresh as @hp changes - you'll have to update the value of StatusString each time. If you put it straight in the status object like #status {HP: @hp} then it'll change as the variable changes. |
|
|
|
|
|