Here is a Reaper specific example of my status line(s). For this to work your hpbar must be configured as follows:
1 [Hit Points Plus]
2 [Spell Points]
3 [Necro Points/Corpses]
4 [Teleports/Glamors]
5 «<line-break»>
6 [Worth|Protection|Veil|Repower]
7 [Undead Follower/Coffin]
8 [Current Enemy]
9 «<line-break»>
10 [Memory] (drm dra scy clu)
UPDATE: This version is improved. It doesn't matter if you have a follower or a coffin. It will still parse out what it can. You still will need to have hpbars set up as above.
NOTES: This is heavly designed to work with my system but can be changed to work with yours. The Failsafe section can/should be changed to meet your requirements. DO NOT use this without reviewing the code to ensure it will do what you want. I have 2 status lines devoted to labels for function keys. If interest develops I'll post the code for those otherwise you WILL want to adjust that section or delete it.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Zstatus.tf ;;;
;;; Zorbo on 3k ;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
/loaded z::zstatus.tf
/set zstatus_version=0.002
;;;
;;; sets up and controls the status area
;;; uses defs from Zmacros.tf
;;; GLOBAL VARIABLES ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; variables used in status area
; and will be initialized here
/if (SB_chp=0) /set SB_chp=1%; /endif
/if (SB_fhp=0) /set SB_fhp=1%; /endif
/if (SB_mhp=0) /set SB_mhp=1%; /endif
/if (SB_php=0) /set SB_php=1%; /endif
/if (SB_dhp=0) /set SB_dhp=1%; /endif
/if (SB_csp=0) /set SB_csp=1%; /endif
/if (SB_fsp=0) /set SB_fsp=1%; /endif
/if (SB_msp=0) /set SB_msp=1%; /endif
/if (SB_psp=0) /set SB_psp=1%; /endif
/if (SB_cnp=0) /set SB_cnp=1%; /endif
/if (SB_mnp=0) /set SB_mnp=1%; /endif
/if (SB_pnp=0) /set SB_pnp=1%; /endif
/if (SB_ctp=0) /set SB_ctp=1%; /endif
/if (SB_mtp=0) /set SB_mtp=1%; /endif
/if (SB_cgl=0) /set SB_cgl=1%; /endif
/if (SB_mgl=0) /set SB_mgl=1%; /endif
/if (SB_pgl=0) /set SB_pgl=1%; /endif
/if (SB_mfhp=0) /set SB_mfhp=1%; /endif
/if (SB_mfsp=0) /set SB_mfsp=1%; /endif
;;; Unused Status area monitor variables ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; some variables that might be used in the future
;
;/set status_var_SB_mudlag=pad(SB_mudlag,4)
;/set status_var_SB_uptime=pad(SB_uptime,5)
;/set status_var_SB_reboot=pad(SB_reboot,6)
;;; STATUS LINE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Enable windowing mode.
/visual on
; set up 6 status lines and 1 input line and " " as the padding
/set status_height=6
/set isize=1
/set status_pad=
; enables clearing of input window when return is pressed
; enables clearing of input window when it is full of input
; (workaround for a bug that happens when isize=1)
/set cleardone=on
/set clearfull=on
;;; ROW 0 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; Main HP/SP/NP etc Status Bar
;
/status_add -s0 -B -c -r0 \
"HP":2:Cgreen \
"[":1:Cwhite \
SB_chp:3 \
"(":1:Cwhite \
SB_fhp:-3 \
")/":2:Cwhite \
SB_mhp:-3 \
"|":1:Cwhite \
SB_php:-3 \
"%|":2:Cwhite \
SB_dhp:-4 \
"] ":2:Cwhite \
"SP":2:Cmagenta \
"[":1:Cwhite \
SB_csp:-3 \
"(":1:Cwhite \
SB_fsp:-3 \
")/":2:Cwhite \
SB_msp:-3 \
"] ":2:Cwhite \
"NP":2:Cyellow \
"[":1:Cwhite \
SB_cnp:-3 \
"/":1:Cwhite \
SB_mnp:-3 \
"] ":2:Cwhite \
"T":1:Ccyan \
"G":1:Cmagenta \
"[":1:Cwhite \
SB_ctp:1 \
"/":1:Cwhite \
SB_mtp:1 \
"|":1:Cwhite \
SB_cgl:1 \
"/":1:Cwhite \
SB_mgl:1 \
"|":1:Cwhite \
SB_pgl:3 \
"%] ":3:Cwhite
/set status_var_SB_chp=(pad((((SB_chp * 100) / SB_mhp) = 100) ? decode_attr({SB_chp},'xBCgreen') \
: (((SB_chp * 100) / SB_mhp) > 100) ? decode_attr({SB_chp},'xBCwhite') \
: (((SB_chp * 100) / SB_mhp) > 90) ? decode_attr({SB_chp},'xCgreen') \
: (((SB_chp * 100) / SB_mhp) > 80) ? decode_attr({SB_chp},'xBCyellow') \
: (((SB_chp * 100) / SB_mhp) > 70) ? decode_attr({SB_chp},'xCyellow') \
: (((SB_chp * 100) / SB_mhp) > 60) ? decode_attr({SB_chp},'xBCmagenta') \
: (((SB_chp * 100) / SB_mhp) > 50) ? decode_attr({SB_chp},'xCred') \
: (((SB_chp * 100) / SB_mhp) >= 0) ? decode_attr({SB_chp},'xBCred') \
: decode_attr({SB_chp},'xBCblue'),3))
/set status_var_SB_fhp=(pad((((SB_fhp * 100) / SB_mfhp) = 100) ? decode_attr({SB_fhp},'xBCgreen') \
: (((SB_fhp * 100) / SB_mfhp) > 100) ? decode_attr({SB_fhp},'xBCwhite') \
: (((SB_fhp * 100) / SB_mfhp) > 90) ? decode_attr({SB_fhp},'xCgreen') \
: (((SB_fhp * 100) / SB_mfhp) > 80) ? decode_attr({SB_fhp},'xBCyellow') \
: (((SB_fhp * 100) / SB_mfhp) > 70) ? decode_attr({SB_fhp},'xCyellow') \
: (((SB_fhp * 100) / SB_mfhp) > 60) ? decode_attr({SB_fhp},'xBCmagenta') \
: (((SB_fhp * 100) / SB_mfhp) > 50) ? decode_attr({SB_fhp},'xCred') \
: (((SB_fhp * 100) / SB_mfhp) >= 0) ? decode_attr({SB_fhp},'xBCred') \
: decode_attr({SB_fhp},'xBCblue'),2))
/set status_var_SB_mhp=(pad(({SB_mhp} > 0) ? decode_attr({SB_mhp},'xBCgreen') \
: decode_attr({SB_mhp},'xBCred'),3))
/set status_var_SB_php=(pad(({SB_php} = 100) ? decode_attr({SB_php},'xBCgreen') \
: ({SB_php} > 100) ? decode_attr({SB_php},'xBCwhite') \
: ({SB_php} > 90) ? decode_attr({SB_php},'xCgreen') \
: ({SB_php} > 80) ? decode_attr({SB_php},'xBCyellow') \
: ({SB_php} > 70) ? decode_attr({SB_php},'xCyellow') \
: ({SB_php} > 60) ? decode_attr({SB_php},'xBCmagenta') \
: ({SB_php} > 50) ? decode_attr({SB_php},'xCred') \
: ({SB_php} >= 0) ? decode_attr({SB_php},'xBCred') \
: decode_attr({SB_php},'xBCblue'),3))
/set status_var_SB_dhp=(pad(({SB_dhp} >= 0) ? decode_attr({SB_dhp},'xBCgreen') \
: decode_attr({SB_dhp},'xBCred'),3))
/set status_var_SB_csp=(pad((((SB_csp * 100) / SB_msp) = 100) ? decode_attr({SB_csp},'xBCgreen') \
: (((SB_csp * 100) / SB_msp) > 100) ? decode_attr({SB_csp},'xBCwhite') \
: (((SB_csp * 100) / SB_msp) > 90) ? decode_attr({SB_csp},'xCgreen') \
: (((SB_csp * 100) / SB_msp) > 80) ? decode_attr({SB_csp},'xBCyellow') \
: (((SB_csp * 100) / SB_msp) > 70) ? decode_attr({SB_csp},'xCyellow') \
: (((SB_csp * 100) / SB_msp) > 60) ? decode_attr({SB_csp},'xBCmagenta') \
: (((SB_csp * 100) / SB_msp) > 50) ? decode_attr({SB_csp},'xCred') \
: (((SB_csp * 100) / SB_msp) >= 0) ? decode_attr({SB_csp},'xBCred') \
: decode_attr({SB_csp},'xBCblue'),3))
/set status_var_SB_fsp=(pad((((SB_fsp * 100) / SB_mfsp) = 100) ? decode_attr({SB_fsp},'xBCgreen') \
: (((SB_fsp * 100) / SB_mfsp) > 100) ? decode_attr({SB_fsp},'xBCwhite') \
: (((SB_fsp * 100) / SB_mfsp) > 90) ? decode_attr({SB_fsp},'xCgreen') \
: (((SB_fsp * 100) / SB_mfsp) > 80) ? decode_attr({SB_fsp},'xBCyellow') \
: (((SB_fsp * 100) / SB_mfsp) > 70) ? decode_attr({SB_fsp},'xCyellow') \
: (((SB_fsp * 100) / SB_mfsp) > 60) ? decode_attr({SB_fsp},'xBCmagenta') \
: (((SB_fsp * 100) / SB_mfsp) > 50) ? decode_attr({SB_fsp},'xCred') \
: (((SB_fsp * 100) / SB_mfsp) >= 0) ? decode_attr({SB_fsp},'xBCred') \
: decode_attr({SB_fsp},'xBCblue'),2))
/set status_var_SB_msp=(pad(({SB_msp} > 0) ? decode_attr({SB_msp},'xBCmagenta') \
: decode_attr({SB_msp},'xBCred'),3))
/set status_var_SB_cnp=(pad((((SB_cnp * 100) / SB_mnp) = 100) ? decode_attr({SB_cnp},'xBCgreen') \
: (((SB_cnp * 100) / SB_mnp) > 100) ? decode_attr({SB_cnp},'xBCwhite') \
: (((SB_cnp * 100) / SB_mnp) > 90) ? decode_attr({SB_cnp},'xCgreen') \
: (((SB_cnp * 100) / SB_mnp) > 80) ? decode_attr({SB_cnp},'xBCyellow') \
: (((SB_cnp * 100) / SB_mnp) > 70) ? decode_attr({SB_cnp},'xCyellow') \
: (((SB_cnp * 100) / SB_mnp) > 60) ? decode_attr({SB_cnp},'xBCmagenta') \
: (((SB_cnp * 100) / SB_mnp) > 50) ? decode_attr({SB_cnp},'xCred') \
: (((SB_cnp * 100) / SB_mnp) >= 0) ? decode_attr({SB_cnp},'xBCred') \
: decode_attr({SB_cnp},'xBCblue'),3))
/set status_var_SB_mnp=(pad(({SB_mnp} > 0) ? decode_attr({SB_mnp},'xBCyellow') \
: decode_attr({SB_mnp},'xBCred'),3))
/set status_var_SB_ctp=({SB_ctp} > 0) ? decode_attr({SB_ctp},'xBCcyan') \
: decode_attr({SB_ctp},'xBCred')
/set status_var_SB_mtp=({SB_mtp} > 0) ? decode_attr({SB_mtp},'xBCcyan') \
: decode_attr({SB_mtp},'xBCred')
/set status_var_SB_cgl=({SB_cgl} > 0) ? decode_attr({SB_cgl},'xBCred') \
: decode_attr({SB_cgl},'xCred')
/set status_var_SB_mgl=({SB_mgl} > 0) ? decode_attr({SB_mgl},'xBCred') \
: decode_attr({SB_mgl},'xCred')
/set status_var_SB_pgl=(pad(({SB_pgl} = 100) ? decode_attr({SB_pgl},'xBCgreen') \
: ({SB_pgl} > 90) ? decode_attr({SB_pgl},'xCgreen') \
: ({SB_pgl} > 80) ? decode_attr({SB_pgl},'xBCyellow') \
: ({SB_pgl} > 70) ? decode_attr({SB_pgl},'xCyellow') \
: ({SB_psl} > 60) ? decode_attr({SB_pgl},'xBCmagenta') \
: ({SB_pgl} > 50) ? decode_attr({SB_pgl},'xCred') \
: ({SB_pgl} >= 0) ? decode_attr({SB_pgl},'xBCred') \
: decode_attr({SB_pgl},'xBCblue'),3))
;;; Row 1 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; Additional status bar
; Status[w125%|pON|vOFF|r10%] Manshi[156%/24c/19c] E[none]
; Status[w120%|pON|vOFF|r72%] Ghoul[100%/11c/0c] E[none]
;
/status_add -s0 -B -c -r1 \
"Status":6:Cyellow \
"[w":2:Cwhite \
SB_worth:-3 \
"%|p":3:Cwhite \
SB_prot:3 \
"|v":2:Cwhite \
SB_veil:3 \
"|r":2:Cwhite \
SB_repower:-3 \
"%] ":3:Cwhite \
SB_fol_type:-6 \
"[":1:Cwhite \
SB_fol_php:-3 \
"%] ":3:Cwhite \
"E":1:Cred \
"[":1:Cwhite \
SB_Enemy:26 \
"|":1:Cwhite \
SB_scan:-3:BCred \
"%]":2:Cwhite
/set status_var_SB_worth=(pad(({SB_worth} >= 125) ? decode_attr({SB_worth},'xBCgreen') \
: ({SB_worth} >= 0) ? decode_attr({SB_worth},'xBCred') \
: decode_attr({SB_worth},'xBCblue'),3))
/set status_var_SB_prot=({SB_prot} =/ "*ON*") ? decode_attr({SB_prot},'xBCgreen') \
: decode_attr({SB_prot},'xBCred')
/set status_var_SB_veil=({SB_veil} =/ "*ON*") ? decode_attr({SB_veil},'xBCgreen') \
: decode_attr({SB_veil},'xBCred')
/set status_var_SB_repower=(pad(decode_attr({SB_repower},'xBCcyan'),3))
/set status_var_SB_fol_type=decode_attr({SB_fol_type},'xCmagenta')
/set status_var_SB_fol_php=(pad(({SB_fol_php} = 100) ? decode_attr({SB_fol_php},'xBCgreen') \
: ({SB_fol_php} > 100) ? decode_attr({SB_fol_php},'xBCwhite') \
: ({SB_fol_php} > 90) ? decode_attr({SB_fol_php},'xCgreen') \
: ({SB_fol_php} > 80) ? decode_attr({SB_fol_php},'xBCyellow') \
: ({SB_fol_php} > 70) ? decode_attr({SB_fol_php},'xCyellow') \
: ({SB_fol_php} > 60) ? decode_attr({SB_fol_php},'xBCmagenta') \
: ({SB_fol_php} > 50) ? decode_attr({SB_fol_php},'xCred') \
: ({SB_fol_php} >= 0) ? decode_attr({SB_fol_php},'xBCred') \
: decode_attr({SB_fol_php},'xBCblue'),3))
/set status_var_SB_Enemy=({SB_Enemy} =~ "none") ? decode_attr({SB_Enemy},'xBCgreen') \
: decode_attr({SB_Enemy},'xBCred')
;;; ROW 2 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; Battle/Auto Stuff
;
/status_add -s0 -B -c -r2 \
"DF":2:Cmagenta \
"[":1:Cwhite \
SB_DreamFreq_disp:6:BCmagenta \
"] ":2:Cwhite \
"CF":2:Cred \
"[":1:Cwhite \
SB_CorpseFreq_disp:6:BCred \
"] ":2:Cwhite \
"IN":2:Cblue \
"[":1:Cwhite \
SB_Invoke_disp:6:BCblue \
"] ":2:Cwhite \
"G":1:Cyellow \
"[":1:Cwhite \
AutoCorpse:1:BCyellow \
AutoFolCorpse:1:BCyellow \
AutoSmuggle:1:BCyellow \
AutoCoffin:1:BCyellow \
"|":1:Cwhite \
AutoBag:1:BCyellow \
AutoChest:1:BCyellow \
"] ":2:Cwhite \
"M":1:Ccyan \
"[":1:Cwhite \
"dm":2:Ccyan \
SB_drm:3:Cmagenta \
"dn":2:Ccyan \
SB_dra:2:Cmagenta \
"sy":2:Ccyan \
SB_scy:2:Cmagenta \
"cl":2:Ccyan \
SB_clu:1:Cmagenta \
"] ":2:Cwhite \
"SS":2:Cmagenta \
"[":1:Cwhite \
SB_ss:5:Cmagenta \
"]":1:Cwhite
/set status_var_SB_DreamFreq_disp=pad(SB_DreamFreq_disp,6)
/set status_var_SB_Invoke_disp=pad(SB_Invoke_disp,6)
/set status_var_SB_CorpseFreq_disp=pad(SB_CorpseFreq_disp,6)
/set status_var_SB_ss=pad(SB_ss,5)
;;; ROW 3 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; shortroom description, corpses and Function Key Menu Name
;
;/status_add -s0 -A -c -r3 \
; "Rm":2:Cblue \
; "[":1:Cwhite \
; SB_shortroom:-40 \
; "] ":2:Cwhite \
; "C":1:Ccyan \
; "[":1:Cwhite \
; SB_icc:2 \
; "/":1:Cwhite \
; SB_fcc:2 \
; "/":1:Cwhite \
; SB_ccc:2 \
; "/":1:Cwhite \
; SB_scc:2 \
; "|":1:Cwhite \
; SB_tcc:3 \
; "] ":2:Cwhite \
; SB_FKBank:-16:BCyellow
/status_add -s0 -A -c -r3 \
"[":1:Cwhite \
SB_message:-42:BCcyan \
"] ":2:Cwhite \
"C":1:Ccyan \
"[":1:Cwhite \
SB_icc:2 \
"/":1:Cwhite \
SB_fcc:2 \
"/":1:Cwhite \
SB_ccc:2 \
"/":1:Cwhite \
SB_scc:2 \
"|":1:Cwhite \
SB_tcc:3 \
"] ":2:Cwhite \
SB_FKBank:-16:BCyellow
; my corpses
/set status_var_SB_icc=(pad(({SB_icc} > 0) ? decode_attr({SB_icc},'xBCblue') \
: decode_attr({SB_icc},'xBCred'),2))
;follower corpses
/set status_var_SB_fcc=(pad(({SB_fcc} > 0) ? decode_attr({SB_fcc},'xBCgreen') \
: decode_attr({SB_fcc},'xBCred'),2))
;coffin corpses
/set status_var_SB_ccc=(pad(({SB_ccc} > 0) ? decode_attr({SB_ccc},'xBCyellow') \
: decode_attr({SB_ccc},'xBCred'),2))
;smuggle corpses
/set status_var_SB_scc=(pad(({SB_scc} > 0) ? decode_attr({SB_scc},'xBCmagenta') \
: decode_attr({SB_scc},'xBCred'),2))
;total corpses
/set status_var_SB_tcc=(pad(((SB_icc+SB_fcc+SB_ccc+SB_scc) > 0) ? decode_attr((SB_icc+SB_fcc+SB_ccc+SB_scc),'xBCcyan') \
: decode_attr((SB_icc+SB_fcc+SB_ccc+SB_scc),'xBCred'),3))
/set status_var_SB_FKBank=pad(SB_FKBank,16)
/set status_var_SB_message=pad(SB_message,-42)
;/set status_var_SB_shortroom=pad(SB_shortroom,-40)
;;; ROW 4 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; Function Key Labels F11-F20
;
/status_add -s0 -A -c -r4 \
"|11":3 \
SB_fk11:5 \
"|12":3 \
SB_fk12:5 \
"|13":3 \
SB_fk13:5 \
"|14":3 \
SB_fk14:5 \
"|15":3 \
SB_fk15:5 \
"|16":3 \
SB_fk16:5 \
"|17":3 \
SB_fk17:5 \
"|18":3 \
SB_fk18:5 \
"|19":3 \
SB_fk19:5 \
"|20":3 \
SB_fk20:5
/set status_var_SB_fk11=pad(SB_fk11,-5)
/set status_var_SB_fk12=pad(SB_fk12,-5)
/set status_var_SB_fk13=pad(SB_fk13,-5)
/set status_var_SB_fk14=pad(SB_fk14,-5)
/set status_var_SB_fk15=pad(SB_fk15,-5)
/set status_var_SB_fk16=pad(SB_fk16,-5)
/set status_var_SB_fk17=pad(SB_fk17,-5)
/set status_var_SB_fk18=pad(SB_fk18,-5)
/set status_var_SB_fk19=pad(SB_fk19,-5)
/set status_var_SB_fk20=pad(SB_fk20,-5)
;;; SB_update_TopFK ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; statusbar update top FK labels
; syntax: SB_update_TopFK("<F11label>","<F12label>",...,"<F20label>","<attributes>")
;
/def SB_update_TopFK = \
/test SB_fk11 := pad({1},-3)%; \
/test status_edit(strcat("SB_fk11:5:", {11}))%; \
/test SB_fk12 := pad({2},-3)%; \
/test status_edit(strcat("SB_fk12:5:", {11}))%;\
/test SB_fk13 := pad({3},-3)%; \
/test status_edit(strcat("SB_fk13:5:", {11}))%;\
/test SB_fk14 := pad({4},-3)%; \
/test status_edit(strcat("SB_fk14:5:", {11}))%;\
/test SB_fk15 := pad({5},-3)%; \
/test status_edit(strcat("SB_fk15:5:", {11}))%;\
/test SB_fk16 := pad({6},-3)%; \
/test status_edit(strcat("SB_fk16:5:", {11}))%;\
/test SB_fk17 := pad({7},-3)%; \
/test status_edit(strcat("SB_fk17:5:", {11}))%;\
/test SB_fk18 := pad({8},-3)%; \
/test status_edit(strcat("SB_fk18:5:", {11}))%;\
/test SB_fk19 := pad({9},-3)%; \
/test status_edit(strcat("SB_fk19:5:", {11}))%;\
/test SB_fk20 := pad({10},-3)%; \
/test status_edit(strcat("SB_fk20:5:", {11}))
;;; ROW 5 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; Function Key Labels F1-F10
;
/status_add -s0 -A -c -r5 \
"|1":2 \
SB_fk1:6 \
"|2":2 \
SB_fk2:6 \
"|3":2 \
SB_fk3:6 \
"|4":2 \
SB_fk4:6 \
"|5":2 \
SB_fk5:6 \
"|6":2 \
SB_fk6:6 \
"|7":2 \
SB_fk7:6 \
"|8":2 \
SB_fk8:6 \
"|9":2 \
SB_fk9:6 \
"|10":3 \
SB_fk10:5
/set status_var_SB_fk1=pad(SB_fk1,-6)
/set status_var_SB_fk2=pad(SB_fk2,-6)
/set status_var_SB_fk3=pad(SB_fk3,-6)
/set status_var_SB_fk4=pad(SB_fk4,-6)
/set status_var_SB_fk5=pad(SB_fk5,-6)
/set status_var_SB_fk6=pad(SB_fk6,-6)
/set status_var_SB_fk7=pad(SB_fk7,-6)
/set status_var_SB_fk8=pad(SB_fk8,-6)
/set status_var_SB_fk9=pad(SB_fk9,-6)
/set status_var_SB_fk10=pad(SB_fk10,-5)
;;; SB_update_BotFK ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; statusbar update bottom FK labels
; syntax: SB_update_BotFK("<F1label>","<F2label>",...,"<F10label>","<attributes>")
;
/def SB_update_BotFK = \
/test SB_fk1 := pad({1},-4)%; \
/test status_edit(strcat("SB_fk1:6:", {11}))%;\
/test SB_fk2 := pad({2},-4)%; \
/test status_edit(strcat("SB_fk2:6:", {11}))%;\
/test SB_fk3 := pad({3},-4)%; \
/test status_edit(strcat("SB_fk3:6:", {11}))%;\
/test SB_fk4 := pad({4},-4)%; \
/test status_edit(strcat("SB_fk4:6:", {11}))%;\
/test SB_fk5 := pad({5},-4)%; \
/test status_edit(strcat("SB_fk5:6:", {11}))%;\
/test SB_fk6 := pad({6},-4)%; \
/test status_edit(strcat("SB_fk6:6:", {11}))%;\
/test SB_fk7 := pad({7},-4)%; \
/test status_edit(strcat("SB_fk7:6:", {11}))%;\
/test SB_fk8 := pad({8},-4)%; \
/test status_edit(strcat("SB_fk8:6:", {11}))%;\
/test SB_fk9 := pad({9},-4)%; \
/test status_edit(strcat("SB_fk9:6:", {11}))%;\
/test SB_fk10 := pad({10},-3)%; \
/test status_edit(strcat("SB_fk10:5:", {11}))
;;; HPBAR 1 TRIGGER ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; NOTE:Status_var_HpBar1-4 below have escaped vertical bars that are not needed except in a def
; NOTE: $[{P1} + 0].... and the like are to strip colors
; new hp bar
;HP[278(38)/278|100%|0] SP[294(38)/294] NP[220/220|6c] TG[1|5]
; with BLAZE we get the following hp bar
;HP[352(58)/352|100%|0] SP[321(58)/357] NP[370/370|0c] TG[2|4/93%]
; chp fhp mhp php dhp csp fsp msp cnp mnp cc tp gla
;
/def -F -p1075 -mregexp -ag -t'HP\[([^\(]*)\(([^\)]*)\)/([^\|]*)\|([^\%]*)\%\|([^\]]*)\] \
SP\[([^\(]*)\(([^\)]*)\)/([^\]]*)\] \
NP\[([^\/]*)\/([^\|]*)\|([^c]*)c\] \
TG\[([^\|]*)\|([^\]]*)\]' HpBarTrigger = \
/eval /set SB_chp=$[{P1} + 0]%; \
/eval /set SB_fhp=$[{P2} + 0]%; \
/eval /set SB_mhp=$[{P3} + 0]%; \
/eval /set SB_php=$[{P4} + 0]%; \
/eval /set SB_dhp=$[{P5} + 0]%; \
/eval /set SB_csp=$[{P6} + 0]%; \
/eval /set SB_fsp=$[{P7} + 0]%; \
/eval /set SB_msp=$[{P8} + 0]%; \
/eval /set SB_psp=$[((SB_csp * 100) / SB_msp)]%; \
/eval /set SB_cnp=$[{P9} + 0]%; \
/eval /set SB_mnp=$[{P10} + 0]%; \
/eval /set SB_pnp=$[((SB_cnp * 100) / SB_mnp)]%; \
/eval /set SB_icc=$[{P11} + 0]%; \
/eval /set SB_ctp=$[{P12} + 0]%; \
/eval /set SB_cgl=$[{P13} + 0]%; \
/set SB_pgl=%; \
/let tempv=$[strchr({P13},"/")]%; \
/if (tempv > 0) \
/set SB_cgl=$[substr({P13}, 0, tempv)]%; \
/let tempv2=$[strchr({P13},"%")]%; \
/let tempv=$[tempv + 1]%; \
/let tempv2=$[tempv2 - tempv]%; \
/set SB_pgl=$[substr({P13}, tempv, tempv2)]%; \
/endif%; \
/if (FS_hp_Active==1) \
/if ((SB_php < FS_hp_p) & (FS_hp_Issued=0)) \
/test PPNotice(6,"H P F A I L S A F E")%; \
/CmdParse -s"~" $[FS_hp_c]%; \
/set FS_hp_Issued=1%; \
/elseif ((SB_php > FS_hp_p) & (FS_hp_Issued=1)) \
/set FS_hp_Issued=0%; \
/endif%; \
/endif%; \
/if (FS_sp_Active==1) \
/if ((SB_psp < FS_sp_p) & (FS_sp_Issued=0)) \
/test PPNotice(6,"S P F A I L S A F E")%; \
/CmdParse -s"~" $[FS_sp_c]%; \
/set FS_sp_Issued=1%; \
/elseif ((SB_psp > FS_sp_p) & (FS_sp_Issued=1)) \
/set FS_sp_Issued=0%; \
/endif%; \
/endif%; \
/if (FS_np_Active==1) \
/if ((SB_pnp < FS_np_p) & (FS_np_Issued=0))\
/test PPNotice(6,"N P F A I L S A F E")%; \
/CmdParse -s"~" $[FS_np_c]%; \
/set FS_np_Issued=1%; \
/elseif ((SB_pnp > FS_np_p) & (FS_np_Issued=1)) \
/set FS_np_Issued=0%; \
/endif%; \
/endif%; \
/if (AutoMonitor==1) \
/let dif_chp=$[SB_chp-old_chp]%; \
/let dif_csp=$[SB_csp-old_csp]%; \
/let dif_cnp=$[SB_cnp-old_cnp]%; \
/let dif_php=$[((dif_chp * 100) / SB_mhp)]%; \
/if (dif_php<=-30) \
/test PPNotice(4,"AutoMonitor: BIG HIT DETECTED $[dif_php]%")%; \
/BattleHeal_inc%; \
/endif%; \
/if ((dif_chp+dif_csp+dif_cnp)!= 0) \
/test dif_chp:=({dif_chp}>=0) ? code_attr({dif_chp},"BCgreen") : code_attr({dif_chp},"BCred")%; \
/test dif_php:=({dif_php}>=0) ? code_attr({dif_php},"BCgreen") : code_attr({dif_php},"BCred")%; \
/test dif_csp:=({dif_csp}>=0) ? code_attr({dif_csp},"BCgreen") : code_attr({dif_csp},"BCred")%; \
/test dif_cnp:=({dif_cnp}>=0) ? code_attr({dif_cnp},"BCgreen") : code_attr({dif_cnp},"BCred")%; \
/let noticeline=$[strcat("@{xCgreen}HP@{n}:",dif_chp,\
" ",dif_php,"%",\
" @{xCmagenta}SP@{n}:",dif_csp,\
" @{xCyellow}NP@{n}:",dif_cnp)]%; \
/let LenNoticeLine=$[strlen(decode_attr(noticeline))]%; \
/let LenLeadin=$[75-LenNoticeLine]%; \
/let Leadin=$[code_attr(strrep("_",LenLeadin),"BCblue")]%; \
/eval /echo -p %Leadin %noticeline%; \
/endif%; \
/set old_chp=$[SB_chp]%; \
/set old_csp=$[SB_csp]%; \
/set old_cnp=$[SB_cnp]%; \
/endif%; \
/set SB_tcc=$[SB_tcc + 0]
;;; HPBAR 2 TRIGGER ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
;Status[w125%|pON|vOFF|r10%] Manshi[156%/24c/19c] E[none]
;Status[w120%|pON|vOFF|r72%] Ghoul[100%/11c/0c] E[none]
;w/o coffin
;Status[w125%|pON|vOFF|r77%] Wight[100%/8c] E[none]
;w/o follower
;Status[w125%|pON|vOFF|r61%] Undead[none/0c] E[Nofunk:healthy]
;Status[w125%|pON|vOFF|r70%] Undead[none/0c] E[none]
;
/def -E(AutoHaveCoffin==1) -F -p1075 -mregexp -ag -t'Status\[w([^\%]*)\%\|p([^\|]*)\|v([^\|]*)\|r([^\%]*)\%\]' \
HpBar2Trigger = \
/let line=%{*}%; \
/set SB_worth=$[{P1} + 0]%; \
/set SB_prot=%P2%; \
/set SB_veil=%P3%; \
/set SB_repower=$[{P4} +0]%; \
/test trial1:=regmatch(" ([^\\\[]*)\\\[([^\%]*)\\\%\\\/([^c]*)c\\\/([^c]*)c\\\] ",line)%; \
; test for follower + coffin
/if (trial1==5) \
/set SB_fol_type=%P1%; \
/set SB_fol_php=%P2%; \
/set SB_fcc=$[{P3} + 0]%; \
/set SB_ccc=$[{P4} + 0]%; \
/else \
; test for follower only
/test trial2:=regmatch(" ([^\\\[]*)\\\[([^\\\%]*)\\\%\\\/([^c]*)c\\\] ",line)%; \
/if (trial2==4) \
/set SB_fol_type=%P1%; \
/set SB_fol_php=%P2%; \
/set SB_fcc=$[{P3} + 0]%; \
/set SB_ccc=0%; \
/else \
; test for coffin only
/test trial3:=regmatch(" Undead\\\[none\\\/([^c]*)c\\\] ",line)%; \
/if (trial3==2) \
/set SB_fol_type=None%; \
/set SB_fol_php=0%; \
/set SB_ccc=$[{P1} +0]%; \
/set SB_fcc=0%; \
/else \
; must be no follower and no coffin -muah-
/set SB_fol_type=None%; \
/set SB_fol_php=0%; \
/set SB_ccc=0%; \
/set SB_fcc=0%; \
/endif%; \
/endif%; \
/endif%; \
/test trial4:=regmatch(" E\\\[([^\\\]]*)\\\]",line)%; \
/set SB_Enemy=%P1%; \
/set SB_tcc=$[SB_tcc + 0]%; \
/if (((strchr(SB_prot,"F")>0)) & (AutoProtection==1))\
/send protection%; \
/send con 100%; \
/endif%; \
/if ((AutoCon==1) & (SB_worth<125)) \
/send con 20%; \
/endif
;;; HPBAR 3 TRIGGER ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
/set Auto_drm_min=10
/set Auto_dra_min=4
/set Auto_scy_min=0
/set Auto_clu_min=0
;Memory[drm85 dra20 scy15 clu5]
/def -F -p1075 -mregexp -ag -t'Memory\[drm([^ ]*) dra([^ ]*) scy([^ ]*) clu([^\]]*)\]' HpBar3Trigger = \
/set SB_drm=$[{P1} + 0]%; \
/set SB_dra=$[{P2} + 0]%; \
/set SB_scy=$[{P3} + 0]%; \
/set SB_clu=$[{P4} + 0]%; \
/if ((SB_drm>=Auto_drm_min) & (Auto_NoDream=1)) \
/set Auto_NoDream=0%; \
/Com2_sp_dream%; \
/test PPNotice(6,"DREAMS REMEMBERED - SWITCHING TO DREAM FOR SP")%; \
/elseif (SB_drm<Auto_drm_min) \
/test PPNotice(6,"DREAM COUNT LOW")%; \
/endif%; \
/if (SB_dra<Auto_dra_min) /test PPNotice(6,"DRAIN COUNT LOW")%; /endif%; \
/if (SB_scy<Auto_scy_min) /test PPNotice(6,"SCYTHE COUNT LOW")%; /endif%; \
/if (SB_clu<Auto_clu_min) /test PPNotice(6,"CLUTCH COUNT LOW")%; /endif





