Porzadki w statsach.

This commit is contained in:
Bartek Stalewski 2014-11-18 13:56:47 +01:00
parent 48361f2f96
commit 34512740e2
6 changed files with 99 additions and 75 deletions

View File

@ -93,7 +93,7 @@
/endif %;\
/let linia=$[strcat("| ",pad(j,-6)," ",pad(wyp_razem,5),"/",pad(x,-5)," [",pad(procent,3),"%%] |",linia)] %;\
/eval /echo -p %{linia}@{n}
/def stat =\
/set wszystkie_parowania=0%;\
/echo -p +----[ Skutecznosc zbroi ]---+-----------[ Wyparowane przez ]---------+@{n}%;\
@ -183,7 +183,7 @@
/def czysc_spece = /quote -S /unset `/listvar -s spec_* %;
; by thornag
; postepy
/set _postepy_list=\
minimalne|\
nieznaczne|\
@ -201,74 +201,3 @@
wspaniale|\
gigantyczne|\
niebotyczne
/def _get_index = \
/let __element=%{1}%; \
/let __list=%{2}|%; \
/let __i=-1%; \
/while ({__list}!~"") \
/let __i=$[{__i}+1]%; \
/let __p=$[strstr({__list}, "|")]%; \
/let __el=$[substr({__list},0,{__p})]%; \
/if ({__el}=~{__element}) \
/return %{__i}%; \
/endif%; \
/let __list=$[substr({__list},{__p}+1)]%; \
/done%; \
/return -1
/def _get_element = \
/let __index=%{1}%; \
/let __list=%{2}|%; \
/let __i=-1%; \
/while ({__list}!~"") \
/let __i=$[{__i}+1]%; \
/let __p=$[strstr({__list}, "|")]%; \
/let __el=$[substr({__list},0,{__p})]%; \
/if ({__i}=={__index}) \
/return strcat({__el})%; \
/endif%; \
/let __list=$[substr({__list},{__p}+1)]%; \
/done%; \
/return ""
/def -Fp500 -mregexp -t'Poczynil.s (.*) postepy, od momentu kiedy wszedles do gry\.' _postepy_lap = \
/let __postep=%{2}%;\
/let __index=$[_get_index({__postep}, {_postepy_list})]%;\
/_postepy_zanotuj %{__index}%;\
/_sub %__index/15
/def _postepy_zanotuj = \
/let __postep=%{1}%; \
/if ({__postep}>{_postepy_current})\
/set _postepy_czas_%{__postep}=$[ftime("%H:%M", time())]%;\
/set _postepy_current=%{__postep}%;\
/endif
/def postepy = /_postepy_show_times
/def _postepy_show_times = \
/let __index=0%; \
/echo -p @{n}------------------------%; \
/echo | Postepy | Czas |%; \
/echo -p @{n}---------------+--------%; \
/while ({__index}<={_postepy_current}) \
/let __postep=$[_get_element({__index}, {_postepy_list})]%; \
/let __czas=$(/listvar -v _postepy_czas_$[strcat({__index})])%; \
/if ({__czas} =~ "" )\
/let __czas=??:??%;\
/endif%;\
/echo $[strcat("| ", pad({__postep},-13), "| ", {__czas}, " |")]%; \
/let __index=$[{__index}+1]%; \
/done%; \
/if ({_postepy_current}==-1) \
/echo -p @{n}| | |%; \
/endif%; \
/echo -p @{n}------------------------
/def _postepy_show = \
/let __postep=%{2}%; \
/let __index=$[_get_index({__postep}, {_postepy_list})]%; \
/_postepy_zanotuj %{__index}%; \
/test substitute(strcat("@{B}", {1}, " [",{__index},"/15]"),"",1)

View File

@ -25,7 +25,6 @@
/load binds.tf
/load colorscheme.tf
/load combat.tf
/load counter.tf
/load equipment.tf
/load hunt.tf
/load lists.tf
@ -35,6 +34,7 @@
/load movement.tf
/load odmiana.tf
/load people.tf
/load stats.tf
/load substitute.tf
/load team.tf
/load testuj.tf

View File

@ -112,3 +112,75 @@
/endif %;\
/echo -p #@{C%c_info}#@{n}# +%{linia1}----- W sumie: %{linia} %;\
/echo -p #@{C%c_info}#@{n}# +%{linia1}-------------------------+@{n}
; by thornag
/def _get_index = \
/let __element=%{1}%; \
/let __list=%{2}|%; \
/let __i=-1%; \
/while ({__list}!~"") \
/let __i=$[{__i}+1]%; \
/let __p=$[strstr({__list}, "|")]%; \
/let __el=$[substr({__list},0,{__p})]%; \
/if ({__el}=~{__element}) \
/return %{__i}%; \
/endif%; \
/let __list=$[substr({__list},{__p}+1)]%; \
/done%; \
/return -1
/def _get_element = \
/let __index=%{1}%; \
/let __list=%{2}|%; \
/let __i=-1%; \
/while ({__list}!~"") \
/let __i=$[{__i}+1]%; \
/let __p=$[strstr({__list}, "|")]%; \
/let __el=$[substr({__list},0,{__p})]%; \
/if ({__i}=={__index}) \
/return strcat({__el})%; \
/endif%; \
/let __list=$[substr({__list},{__p}+1)]%; \
/done%; \
/return ""
/def -Fp500 -mregexp -t'Poczynil.s (.*) postepy, od momentu kiedy wszedles do gry\.' _postepy_lap = \
/let __postep=%{2}%;\
/let __index=$[_get_index({__postep}, {_postepy_list})]%;\
/_postepy_zanotuj %{__index}%;\
/_sub %__index/15
/def _postepy_zanotuj = \
/let __postep=%{1}%; \
/if ({__postep}>{_postepy_current})\
/set _postepy_czas_%{__postep}=$[ftime("%H:%M", time())]%;\
/set _postepy_current=%{__postep}%;\
/endif
/def postepy = /_postepy_show_times
/def _postepy_show_times = \
/let __index=0%; \
/echo -p @{n}------------------------%; \
/echo | Postepy | Czas |%; \
/echo -p @{n}---------------+--------%; \
/while ({__index}<={_postepy_current}) \
/let __postep=$[_get_element({__index}, {_postepy_list})]%; \
/let __czas=$(/listvar -v _postepy_czas_$[strcat({__index})])%; \
/if ({__czas} =~ "" )\
/let __czas=??:??%;\
/endif%;\
/echo $[strcat("| ", pad({__postep},-13), "| ", {__czas}, " |")]%; \
/let __index=$[{__index}+1]%; \
/done%; \
/if ({_postepy_current}==-1) \
/echo -p @{n}| | |%; \
/endif%; \
/echo -p @{n}------------------------
/def _postepy_show = \
/let __postep=%{2}%; \
/let __index=$[_get_index({__postep}, {_postepy_list})]%; \
/_postepy_zanotuj %{__index}%; \
/test substitute(strcat("@{B}", {1}, " [",{__index},"/15]"),"",1)

View File

@ -7,6 +7,7 @@
/load money.tf
/load movement.tf
/load specs.tf
/load stats.tf
/load statusbar.tf
/load substitute.tf
/load warn.tf

22
nightal/stats.tf Normal file
View File

@ -0,0 +1,22 @@
; postepy
/set _postepy_list=\
znikome|\
minimalne|\
mizerne|\
nieznaczne|\
niewielkie|\
bardzo male|\
male|\
nieduze|\
znaczne|\
istotne|\
owocne|\
duze|\
pokazne|\
bardzo duze|\
trwale|\
wspaniale|\
wielkie|\
ogromne|\
kolosalne|\
nieopisane

View File

@ -256,7 +256,7 @@
/eval /status_add -r1 "K: ":: kondycja:23
/eval /status_add -r1 "Z: ":: zmeczenie:20
/eval /status_add -r1 "M: ":: mana:20
/eval /status_add -r1 "Hidden: ":: hide:4:C%c_main
/eval /status_add -r1 "Hidden: ":: hideshow:4:C%c_main
/eval /status_add -r1 "Cover: ":: nxt_zaslona:3
/eval /status_add -r1 "Mail: ":: poczta_show:5:C%c_main
/eval /status_add -r1 spacebreak::