Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ON *:START: {
- var %h = WHITEHOST
- var %f = $mircdirdata\ $+ %h $+ .list
- if (!$file(%f)) { return }
- hmake %h 3000
- hload %h $qt(%f)
- }
- alias hostadd {
- tokenize 32 $strip($1-)
- var %h = WHITEHOST
- var %d = $hfind(%h,$1,0,W).data
- if (!$1) { echo 4 -gate Error: Please specify a parameter! | return }
- if (%d) { echo 4 -gate Error: Already exists $qt($1) in %h list! | return }
- hadd -m %h $ctime $1
- hsave %h $qt($mircdirdata\ $+ %h $+ .list)
- unbanall $1
- echo 3 -gate Added $qt($1) in the %h list. - Total: $hget(%h,0).item
- }
- alias hostdel {
- tokenize 32 $strip($1-)
- var %h = WHITEHOST
- var %d = $hfind(%h,$1,1,W).data
- if (!$1) { echo 4 -gate Error: Please specify a parameter! | return }
- if (!%d) { echo 4 -gate Error: Not exists $qt($1) on the %h list! | return }
- hdel %h %d
- hsave %h $qt($mircdirdata\ $+ %h $+ .list)
- echo 3 -gate Removed $qt($1) from the %h list. - Total: $hget(%h,0).item
- }
- alias hostlist {
- var %h = WHITEHOST
- var %t = $hget(%h,0).item
- if (!%t) { echo 4 -gate Error: %h list is empty! | return }
- echo 10 -gate Display all %h list..
- var %i = 1
- while (%i <= %t) {
- var %item = $hget(%h,%i).item
- var %data = $hget(%h,%item)
- if (%item) && (%data) { echo 6 -gate $+($chr(35),%i,:) %data - Added on: $asctime(%item) }
- inc %i
- }
- echo 10 -gate End of %h list.
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement