Menu channel { Useful dialog:dialog -md ut ut } alias useful { dialog -md ut ut } dialog ut { title "[SLZ] Useful thing" size -1 -1 128 260 option dbu box ":רשימת חברים", 3, 1 1 126 58 edit "", 7, 3 9 80 10 list 8, 3 20 80 37, size button "הוסף", 9, 88 9 35 10 button "מחק", 10, 88 19 35 10 box ":רשימת אויבים", 11, 1 60 126 79 edit "", 12, 3 68 80 10 list 13, 3 79 80 37, size button "הוסף", 14, 88 68 35 10 button "מחק", 15, 88 78 35 10 box ":בעת התחברות", 16, 3 117 122 20 radio "בעיטה", 17, 94 124 28 10 radio "באן", 18, 71 124 21 10 radio "בעיטה + באן", 19, 23 124 45 10 check "", 20, 10 124 8 10 box ":(שורות מידע (אינפו ליין", 21, 1 139 126 75 list 22, 3 158 80 37, size edit "", 23, 3 147 80 10 button "הוסף", 24, 88 147 35 10 button "מחק", 25, 88 157 35 10 box "", 26, 3 194 122 18 button "הוסף שורת מידע", 27, 75 199 48 10 button "מחק שורת מידע", 28, 26 199 48 10 button "הסבר", 29, 5 199 20 10 button "סגור", 30, 92 249 35 10 button "שנה ססמא", 2, 4 236 33 10 box "נעילת חלון פרטי", 1, 1 214 126 34 box "", 4, 3 218 122 17 text ":סטטוס", 5, 101 224 22 8 edit "", 6, 72 224 27 9, disable button "", 31, 4 223 33 10 text ".חלונות נסגרו", 32, 70 237 37 8 edit "", 33, 106 236 19 10, disable } alias c1check { if (%utc1s == 1) did -ra $dname 6 נעול else did -ra $dname 6 פתוח } alias c3check { if (%utc3s == 1) { did -c $dname 20 } elseif (%utc3s == 0) { did -b $dname 17,18,19 } } on *:dialog:ut:sclick:31: { if (%utc1s == 1) { set %utc1s 2 | did -ra $dname 6 פתוח } else { set %utc1s 1 | did -ra $dname 6 נעול } } on *:dialog:ut:sclick:32: { set %utc1s 2 } on *:dialog:ut:sclick:20: { if ($did($dname,20).state == 1) { set %utc3s 1 | did -e $dname 17,18,19 | rstate } else { set %utc3s 0 | did -b $dname 17,18,19 | did -u $dname 17,18,19 } } on *:dialog:ut:sclick:17: { set %rstate17 1 | set %rstate18 0 | set %rstate19 0 } on *:dialog:ut:sclick:18: { set %rstate17 0 | set %rstate18 1 | set %rstate19 0 } on *:dialog:ut:sclick:19: { set %rstate17 0 | set %rstate18 0 | set %rstate19 1 } on *:dialog:ut:sclick:30: { dialog -x ut ut } on *:dialog:ut:init:0: { refresh.utfl | refresh.utbl | c3check | refresh.closed | rstate | c1check | refresh.util } on *:dialog:ut:sclick:2: { //var %utpass1 $$?=":ססמא חדשה" set %utpass %utpass1 | fnotice | echo -a 5הססמא שונתה בהצלחה } alias fnotice { if ($lines(Useful/friends.txt) > 0) { var %x 1 while (%x <= $lines(Useful/friends.txt)) { msg $read(Useful/friends.txt,%x) %utpass :ססמאת החלון הפרטי שלי שונתה. הססמא החדשה היא inc %x } } } alias infoactive { var %lines $lines(Useful/ $+ $nick $+ -info.txt) var %info $rand(1, $+ [ %lines ] $+ ) msg # 14Random (1/ $+ [ %lines ] $+ ) infoline for :12 $nick :1 $read(Useful/ $+ $nick $+ -info.txt,%info) } on *:join:#: { friendslist | infosearch | blacksearch } alias infosearch { if (Useful/ $+ $nick $+ -info.txt) && ($read(Useful/infonix.txt,w,$nick)) { infoactive } } alias friendslist { if ($read(Useful/friends.txt,w,$nick)) { msg # Friendslist : $nick [ $chr(91) $+ [ $address ] $+ [ $chr(93) ] ] } } alias blacksearch { if ($read(Useful/blacklisted.txt,w,$nick)) { blacklisted } } alias blacklisted { if (%utc3s == 1) && (%rstate17 == 1) { kick # $nick BlackListed } elseif (%utc3s == 1) && (%rstate18 == 1) { mode # +b $nick BlackListed } elseif (%utc3s == 1) && (%rstate19 == 1) { ban -ku900 # $nick 2 BlackListed } } alias rstate { if (%rstate17 == 1) && (%utc3s == 1) { did -c $dname 17 } elseif (%rstate18 == 1) && (%utc3s == 1) { did -c $dname 18 } elseif (%rstate19 == 1) && (%utc3s == 1) { did -c $dname 19 } } alias refresh.closed { did -ra ut 33 %windowsclosed } on *:open:?: { if (%utc1s == 1) && ($1 != %utpass) { close -m $nick | inc %windowsclosed | refresh.closed | notice $nick מצטער, אך לא אוכל לקבל את הודעתך. החלון הפרטי שלי נעול כרגע, והססמא שגויה. } elseif (%utc1s == 1) && ($1 == %utpass) { notice $Nick .הססמא התקבלה } elseif (%utc1s == 0) && ($1 == %utpass) { halt } elseif (%utc1s == 0) && ($1 != %utpass) { halt } } alias refresh.utfl { var %x 1 did -r $dname 8 while (%x <= $lines(Useful/friends.txt)) { did -a $dname 8 $read(Useful/friends.txt,%x) inc %x } } alias refresh.util { var %x 1 did -r $dname 22 while (%x <= $lines(Useful/infonix.txt)) { did -a $dname 22 $read(Useful/infonix.txt,%x) inc %x } } alias refresh.utbl { var %x 1 did -r $dname 13 while (%x <= $lines(Useful/blacklisted.txt)) { did -a $dname 13 $read(Useful/blacklisted.txt,%x) inc %x } } on *:dialog:ut:sclick:9: { write Useful/friends.txt $did($dname,7) | refresh.utfl | did -r $dname 7 } on *:dialog:ut:sclick:10: { write -dl $+ $did($dname,8).sel Useful/friends.txt | refresh.utfl } on *:dialog:ut:sclick:24: { write Useful/infonix.txt $did($dname,23) | refresh.util | did -r $dname 23 } on *:dialog:ut:sclick:25: { infodeleting } on *:dialog:ut:sclick:14: { write Useful/blacklisted.txt $did($dname,12) | refresh.utbl | did -r $dname 12 } on *:dialog:ut:sclick:15: { write -dl $+ $did($dname,13).sel Useful/blacklisted.txt | refresh.utbl } on *:dialog:ut:sclick:27: { write Useful/ $+ $did($dname,22).seltext $+ -info $+ .txt $$?=":שורת מידע" } on *:dialog:ut:sclick:28: { echo -a 5יש להכניס את מס' השורה שברצונכם למחוק. כדי להציג את מספור הרשימות לחצו על הסבר | write -dl $+ $$?=":מס השורה" Useful/ $+ $did($dname,22).seltext $+ -info $+ .txt } on *:dialog:ut:sclick:29: { echo -a $did($dname,22).seltext :שורות המידע שהוגדרו לכינוי | linesview } alias linesview { var %x 1 var %p 1 echo -a נמצאו $lines(Useful/ $+ $did($dname,22).seltext $+ -info $+ .txt) שורות while (%x <= $lines(Useful/ $+ $did($dname,22).seltext $+ -info $+ .txt)) { echo -a %p $+ . $read(Useful/ $+ $did($dname,22).seltext $+ -info $+ .txt,%x) inc %p inc %x } } alias infodeleting { if (Useful/ $+ $did($dname,22).seltext $+ -info.txt) { write -dl $+ $did($dname,22).sel Useful/infonix.txt | refresh.util | write -c Useful/ $+ $did($dname,22).seltext $+ -info.txt } else { write -dl $+ $did($dname,22).sel Useful/infonix.txt | refresh.util }