|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Mon Nov 09, 2009 12:45 am
Ummm WTF Status Window. |
Umm Iam attempting to setup status windows in 2 different sessions, and it seems like its not wanting to let me do that....
note my status window in docked on the right side of session 1 and I want a second one docked on the right side of session 2
and thoughts? |
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Mon Nov 09, 2009 1:00 am |
The status window is a Highlander Immortal--there can only be one (per CMud instance). If you want two then you have to have two CMuds open.
If you can come up with a system to manage the window updating, you can forgo the Status Window entirely in favor of two child windows. |
|
_________________ EDIT: I didn't like my old signature |
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Mon Nov 09, 2009 4:27 pm |
I wouldnt mind useing the child windows, but I dont know how to run the updating and stuff like the status window in a regular session window.......
if someone could help me come up with the scripting for that it would be great I really have no idea how too. Iam useing triggers to mod variables and variables post in the status window... as far as I know there not really a way to turn a regular window into a "fake status window?
Iam sure one of you Gurus can pul this rabbit out of the hat.....
Note: Given all the options that cmud has, i dont really see why a simple update could be made to have session orientated status windows instead of client status window.... right? I just doesnt seem like it would be that hard to do. and i dont know why it hasnt already been done?
Thanks Mud Gods |
|
|
|
orphean Apprentice
Joined: 21 Oct 2008 Posts: 147 Location: Olympia, WA
|
Posted: Mon Nov 09, 2009 6:05 pm |
The thing with child windows, as opposed to the status window, is that they won't update themselves automatically when a variable changes. Since you're using triggers anyway to capture the variables it makes sense to just update the window when the trigger fires.
It would be easy to create an alias that you add to your existing triggers to update a child window.
Assuming @hp, @hp_max, etc are variables you are assigning in a trigger something like the following could work:
Code: |
<alias name="status_update">
<value>#execwin Status {
#clr // Prevents scrolling.
#say hp @hp/@hp_max
}</value>
</alias> |
Obviously that is extremely simple, but you can do whatever you want in it, and as long as you call status_update in the triggers that assign the variables it will stay up to date. I do something close to this on a few muds I play, here's an example of one of my setups:
|
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 3:08 am |
how is it that you change the colors? perhapes you could copy and paste one of your script lines? maybe the alignment and gold line?
Iam not even ready for your stat bars.... |
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 3:34 am |
Iam doing this in the alias
#execwin PlagueStatus {#clr}
#execwin PlagueStatus {#say ---------------------}
#execwin PlagueStatus {#say Hits: @hitpoint/@maxhitpoint}
#execwin PlagueStatus {#say Mana: @manapoint/@maxmanapoint}
#execwin PlagueStatus {#say Move: @movepoint/@maxmovepoint}
#execwin PlagueStatus {#say ---------------------}
Iam getting this sent for some reason????
---------------------
Hits: | 21150/21150
Mana: 1050/1050
Move: 1050/1050
---------------------
After the Hits: that stupid line is appearing....
can I fix this |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 3:34 am |
he most likely used %ansi, or <color here>thing</color>
it would be like this
Code: |
<alias name="status_update">
<value>#execwin Status {
#clr // Prevents scrolling.
#say %ansi(high,cyan)hp%ansi(default) @hp/@hp_max
}</value>
</alias> |
edit on my own part: now that i learned about them i like using functions for this more then i do the %ansi code now, might want to look up on that |
|
Last edited by hadar on Tue Nov 10, 2009 3:38 am; edited 1 time in total |
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 3:36 am |
__BUMP__ Look Up
thanks Hadar |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 3:37 am |
daemoan.vermillious wrote: |
Hits: | 21150/21150
Mana: 1050/1050
Move: 1050/1050
After the Hits: that stupid line is appearing....
can I fix this |
check your VAR and how its being made i bet the pipe (|) is being made from your trigger to capture your prompt im assuming, so you might want to change it from wildcard (*) to (%d) |
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 3:43 am |
Trigger:
%1/%2 HP %3/%4 Mana %5/%6 Move
Trigger Value:
#variable hitpoint %1
#variable maxhitpoint %2
#variable manapoint %3
#variable maxmanapoint %4
#variable movepoint %5
#variable maxmovepoint %6
Alias Value:
#execwin PlagueStatus {#clr}
#execwin PlagueStatus {#say ---------------------}
#execwin PlagueStatus {#say Hits: <color white>@hitpoint</color>/<color white>@maxhitpoint</color>}
#execwin PlagueStatus {#say Mana: <color white>@manapoint</color>/<color white>@maxmanapoint</color>}
#execwin PlagueStatus {#say Move: <color white>@movepoint</color>/<color white>@maxmovepoint</color>}
#execwin PlagueStatus {#say ---------------------}
I dont know how can I do that and change the percents all in the same triggeR? |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 3:45 am |
change the trigger to this
(%d)/(%d) HP (%d)/(%d) Mana (%d)/(%d) Move
keep the values the same, cmud hates %1 ect in the pattern, it was a glitch in zmud to be able to use these in there cmud is less forgiving
in one of my muds this is my prompt capture trigger
Code: |
<trigger priority="20" id="2">
<pattern>(%d)~((%d)~)hitp (%d)~((%d)~)mana (%d)~((%d)~)move></pattern>
<value>#if (@promptvar.hp<@promptvar.halfhp) {#if (@alreadyasked=0) {gsay heal: cure crit;#var alreadyasked 1}}
#addkey promptvar hp %int( %1)
#addkey promptvar hpmax %int( %2)
#addkey promptvar mn %int( %3)
#addkey promptvar mnmax %int( %4)
#addkey promptvar mv %int( %5)
#addkey promptvar mvmap %int( %6)
#addkey promptvar halfhp %int(%eval(@promptvar.hpmax/2))</value>
</trigger>
|
|
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 3:51 am |
I changed it.... Altho Iam still haveing the "pipe" pop up/////
|
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 3:54 am |
as i said did you check your variable? then delete it?
|
|
|
|
orphean Apprentice
Joined: 21 Oct 2008 Posts: 147 Location: Olympia, WA
|
Posted: Tue Nov 10, 2009 4:02 am |
Color in that picture is just using %ansi but honestly using color tags would be easier for everything but the histograms. I have no idea whatsoever where that pipe character is coming from, but I suspect hadar is on the right track. Maybe post what your prompt looks like (if that's where you're getting these values) and we can narrow it down.
If you wanted to look at my thing it's in the package library as 'Statmon Window' in the Aardwolf section. |
|
|
|
charneus Wizard
Joined: 19 Jun 2005 Posts: 1876 Location: California
|
Posted: Tue Nov 10, 2009 6:29 am |
If the trigger has fired since he made the change, then the pipe character shouldn't be showing up at all, since a pipe character is not a digit, and the trigger is specifically looking for a digit.
Odd that it is showing up, however.
One thing to point out is anything that is NOT a function, variable, or command should be quoted. That means changing something from:
#SAY <color red>Hi!</color>
to:
#SAY "<color red>Hi!</color>"
This way you can preserve spaces and whatnot.
Charneus |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 11:10 am |
Ok so did the pipe ever go away? And thanks charn for reminding me about that I completly forgot
|
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 4:39 pm |
no every time I do the update alias its adding additional rows in the value.
makes new row 1
and my actual value is in row 2 and then also makes another empty row 3
now I manually delete these columns and they reappear on update
but only on that stupid hp line.
also just you say quoted... Iam useing the {} instead of quotes..... does this matter? |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 5:00 pm |
post the script exactly how it is now, from the trigger to the alias
|
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 5:06 pm |
<stat name="Plague Status" showinbar="false" showinwindow="true" priority="10" id="1">
<value>dgfdd</value>
</stat>
<class name="autolog" enabled="false" id="2">
<trigger priority="30" case="true" verbatim="true" newline="false" prompt="true" id="3">
<pattern>What name do you want to be known as: </pattern>
<value>#CH</value>
</trigger>
<trigger priority="40" case="true" verbatim="true" newline="false" prompt="true" id="4">
<pattern>Please enter password: </pattern>
<value>#PW;#T- autolog</value>
</trigger>
</class>
<trigger priority="50" id="5">
<pattern>~|~)~>chat~<~(~| %1~: %2</pattern>
<value>#cap PlagueLog</value>
</trigger>
<var name="hitpoint" type="Integer" id="7">| 21150</var>
<var name="maxhitpoint" id="8">21150</var>
<var name="manapoint" id="9">1050</var>
<var name="maxmanapoint" id="10">1050</var>
<var name="maxmovepoint" id="12">1050</var>
<trigger priority="130" id="13">
<pattern>Primal~: &%dprimalvar</pattern>
</trigger>
<alias name="ddd" id="14">
<value><![CDATA[#execwin PlagueStatus {#clr}
#execwin PlagueStatus {#say}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}
#execwin PlagueStatus {#say Hits: <color white>@hitpoint</color>/<color white>@maxhitpoint</color>}
#execwin PlagueStatus {#say Mana: <color white>@manapoint</color>/<color white>@maxmanapoint</color>}
#execwin PlagueStatus {#say Move: <color white>@movepoint</color>/<color white>@maxmovepoint</color>}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}
#execwin PlagueStatus {#say HRoll: <color white>@hitrollvar</color> DRoll: <color white>@damrollvar</color>}
#execwin PlagueStatus {#say Armor: <color white>@acvar</color> DCap: <color white>@damcapvar</color>}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}
#execwin PlagueStatus {#say Offense: <color white>@offensevar</color> Speed: <color white>@speedvar</color>}
#execwin PlagueStatus {#say Defense: <color white>@defensevar</color> Evade: <color white>@evasionvar</color>}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}
#execwin PlagueStatus {#say Primal: <color white>@primalvar</color> Qps: <color white>@qpvar</color>}
#execwin PlagueStatus {#say Status: <color white>@statusvar</color> Alignment: <color white>@alignvar</color>}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}
#execwin PlagueStatus {#say Autostance: <color white>@stancevar</color>}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}
#execwin PlagueStatus {#say DragonForm: <color white>@formvar</color>}
#execwin PlagueStatus {#say <color yellow>-------------------------</color>}]]></value>
</alias>
<var name="movepoint" id="15">1050</var>
<trigger priority="170" id="17">
<pattern>%1/%2 HP %2/%4 Mana %5/%6 Move</pattern>
<value>#variable hitpoint %1
#variable maxhitpoint %2
#variable manapoint %3
#variable maxmanapoint %4
#variable movepoint %5
#variable maxmovepoint %6 </value>
</trigger>
<trigger priority="180" id="18">
<pattern>%1 tells you '%2'.</pattern>
<value>#cap PlagueLog</value>
</trigger>
<trigger priority="190" id="19">
<pattern>Align: &%dalignvar</pattern>
</trigger>
<trigger priority="200" id="20">
<pattern>Status: &%dstatusvar</pattern>
</trigger>
<trigger priority="210" id="21">
<pattern>QPs: &%dqpvar</pattern>
</trigger>
<trigger priority="220" id="22">
<pattern>Hitroll: &%dhitrollvar</pattern>
</trigger>
<trigger priority="230" id="23">
<pattern>Damroll: &%ddamrollvar</pattern>
</trigger>
<trigger priority="240" id="24">
<pattern>AC: ~-&%dacvar</pattern>
</trigger>
<trigger priority="250" id="25">
<pattern>Damcap: &%ddamcapvar</pattern>
</trigger>
<trigger priority="260" id="26">
<pattern>Defense: &%ddefensevar</pattern>
</trigger>
<trigger priority="270" id="27">
<pattern>Offense: &%doffensevar</pattern>
</trigger>
<trigger priority="280" id="28">
<pattern>Speed: &%dspeedvar</pattern>
</trigger>
<trigger priority="290" id="29">
<pattern>Evasion: &%devasionvar</pattern>
</trigger>
<trigger priority="300" id="30">
<pattern>Unused: &%dunusedvar</pattern>
</trigger>
<trigger priority="310" id="31">
<pattern>Autostance: &%wstancevar</pattern>
</trigger>
<var name="alignvar" id="32">1000</var>
<var name="statusvar" id="33">0</var>
<var name="qpvar" id="34">2494</var>
<var name="hitrollvar" id="35">1234</var>
<var name="acvar" id="36">4031</var>
<var name="damrollvar" id="37">1236</var>
<var name="damcapvar" id="38">10000</var>
<var name="offensevar" id="39">0</var>
<var name="speedvar" id="40">0</var>
<var name="evasionvar" id="41">15</var>
<var name="primalvar" id="42">0</var>
<var name="defensevar" id="43">0</var>
<var name="stancevar" id="44">Monkey</var>
<alias name="kaiser" id="45">
<value>splice infinity
splice trance
splice radiance
splice complete
#variable formvar Kaiser</value>
</alias>
<alias name="humanform" id="46">
<value>splice human</value>
</alias>
<var name="formvar" id="47">Kaiser</var>
</window> |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Tue Nov 10, 2009 5:12 pm |
first i told you to change
<trigger priority="170" id="17">
<pattern>%1/%2 HP %2/%4 Mana %5/%6 Move</pattern>
<value>#variable hitpoint %1
#variable maxhitpoint %2
#variable manapoint %3
#variable maxmanapoint %4
#variable movepoint %5
#variable maxmovepoint %6 </value>
</trigger>
to
Code: |
<trigger priority="170" id="17">
<pattern>(%d)/(%d) HP (%d)/(%d) Mana (%d)/(%d) Move</pattern>
<value>#variable hitpoint %1
#variable maxhitpoint %2
#variable manapoint %3
#variable maxmanapoint %4
#variable movepoint %5
#variable maxmovepoint %6 </value>
</trigger> |
other then that it all looks fine to me |
|
|
|
daemoan.vermillious Apprentice
Joined: 28 Feb 2009 Posts: 135 Location: Chico, Ca
|
Posted: Tue Nov 10, 2009 5:22 pm |
this is my hp line Iam trying to capture
Plague of the Cooter |
40426/40426 HP 1050/1050 Mana 1050/1050 Move
now I tryied to change the pattern variables like you said...
but its not even captureing it.... |
|
|
|
hadar Apprentice
Joined: 30 Aug 2009 Posts: 198 Location: my apt, in california
|
Posted: Wed Nov 11, 2009 12:26 pm |
sense you told me you are using the free version, normally i would not do this but meh, use startcaptures to begin
Code: |
<trigger priority="10" id="1">
<pattern>~<~[(%d)~] ~[(%d)/(%d)H (%d)/(%d)M (%d)/(%d)MV]></pattern>
<value>#addkey dbstats exp %int(%1)
#addkey dbstats hp %int(%2)
#addkey dbstats maxhp %int(%3)
#addkey dbstats mana %int(%4)
#addkey dbstats maxmana %int(%5)
#addkey dbstats move %int(%6)
#addkey dbstats maxmove %int(%7)
updatewindow</value>
</trigger>
<var name="dbstats" type="Record" id="2"><![CDATA[mana=1050|maxmana=1050|move=1050|hp=5086|maxmove=1050|mnlv=15|maxhp=5050|mvlv=15|mntmp=###############|mvtmp=###############|hplv=15|hpgauge=[0;51;40m#####[0;53;40m#####[0;52;40m#####|mngauge=[0;51;40m#####[0;53;40m#####[0;52;40m#####|mvgauge=[0;51;40m#####[0;53;40m#####[0;52;40m#####|hptmp=###############|exp=2831]]></var>
<alias name="startupcaptures" id="3">
<value>#send {"prompt <[#r%x#n] [#c%h/%H#nH #c%m/%M#nM #c%v/%V#nMV]>"}
#win statcap</value>
</alias>
<alias name="updatewindow" id="4">
<value><![CDATA[dbstats.hplv=%round( %float( @dbstats.hp)*%float( 15)/%float( @dbstats.maxhp))
dbstats.mnlv=%round( %float( @dbstats.mana)*%float( 15)/%float( @dbstats.maxmana))
dbstats.mvlv=%round( %float( @dbstats.move)*%float( 15)/%float( @dbstats.maxmove))
dbstats.hptmp=%concat( %repeat( "#", @dbstats.hplv), %repeat( " ", %eval( 15-@dbstats.hplv)))
dbstats.mntmp=%concat( %repeat( "#", @dbstats.mnlv), %repeat( " ", %eval( 15-@dbstats.mnlv)))
dbstats.mvtmp=%concat( %repeat( "#", @dbstats.mvlv), %repeat( " ", %eval( 15-@dbstats.mvlv)))
dbstats.hpgauge=%concat( %ansi( high, red), %left( @dbstats.hptmp, 5), %ansi( high, yellow), %copy( @dbstats.hptmp, 6, 5), %ansi( high, green), %rightback( @dbstats.hptmp, 5))
dbstats.mngauge=%concat( %ansi( high, red), %left( @dbstats.mntmp, 5), %ansi( high, yellow), %copy( @dbstats.mntmp, 6, 5), %ansi( high, green), %rightback( @dbstats.mntmp, 5))
dbstats.mvgauge=%concat( %ansi( high, red), %left( @dbstats.mvtmp, 5), %ansi( high, yellow), %copy( @dbstats.mvtmp, 6, 5), %ansi( high, green), %rightback( @dbstats.mvtmp, 5))
#execwin statcap {#clr}
#execwin statcap {#say}
#execwin statcap {#say "<color yellow>-------------------------</color>"}
#execwin statcap {#say "Hits: <color white>"@dbstats.hp"</color>/<color white>"@dbstats.maxhp"</color>"}
#execwin statcap {#say "Mana: <color white>"@dbstats.mana"</color>/<color white>"@dbstats.maxmana"</color>"}
#execwin statcap {#say "Move: <color white>"@dbstats.move"</color>/<color white>"@dbstats.maxmove"</color>"}
#execwin statcap {#say "<color yellow>-------------------------</color>"}
#execwin statcap {#say "<color white>HP : [</color>"@dbstats.hpgauge"<color white>]</color>"}
#execwin statcap {#say "<color white>Mana : [</color>"@dbstats.mngauge"<color white>]</color>"}
#execwin statcap {#say "<color white>Moves: [</color>"@dbstats.mvgauge"<color white>]</color>"}]]></value>
</alias>
|
|
|
|
|
|
|