Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- menu channel {
- Auto Modes: auto
- }
- alias auto {
- if ($active ischan && $dialog(auto) == $null) dialog -m auto auto
- }
- dialog auto {
- title "Auto Modes"
- size -1 -1 106 179
- option dbu
- text "Auto Modes For", 1, 32 7 42 8, center
- box "Previous Nicks", 2, 7 29 50 90
- list 3, 9 37 44 79, size sort
- box "Modes", 4, 63 29 35 63
- button "OK", 5, 34 158 37 12, ok cancel
- check "Protect", 6, 67 126 29 10, disable
- check "Op", 7, 67 38 23 10, disable
- check "Owner", 8, 67 102 28 10, disable
- check "Voice", 9, 67 48 26 10, disable
- check "Kick", 10, 67 58 22 10, disable
- check "Ban", 11, 67 68 23 10, disable
- check "Greet", 12, 67 78 26 10, disable
- check "Halfop", 13, 67 114 28 10, disable
- box "Chanserv", 14, 63 93 36 47
- text "(channel)", 15, 6 14 94 8, center
- edit "", 16, 7 130 50 10
- box "New Nick", 17, 3 121 58 30
- button "Enter", 18, 20 141 21 8, disable
- }
- on *:dialog:auto:edit:16:{
- if ($did(auto,16).text != $null) did -e auto 18
- else did -b auto 18
- }
- on *:dialog:auto:init:0:{
- did -ra auto 15 $active
- var %nick = 1
- while (%nick <= $ini($active $+ .ini,0)) {
- did -a auto 3 $ini($active $+ .ini,%nick)
- inc %nick
- }
- }
- on *:dialog:auto:sclick:*:{
- if ($did == 3 && $did(auto,3).seltext != $null) {
- did -e auto 6-13
- did -u auto 6-13
- if ($readini($active $+ .ini,$did(auto,3).seltext,op) == yes) did -c auto 7
- if ($readini($active $+ .ini,$did(auto,3).seltext,voice) == yes) did -c auto 9
- if ($readini($active $+ .ini,$did(auto,3).seltext,kick) == yes) did -c auto 10
- if ($readini($active $+ .ini,$did(auto,3).seltext,ban) == yes) did -c auto 11
- if ($readini($active $+ .ini,$did(auto,3).seltext,greet) != no && $readini($active $+ .ini,$did(auto,3).seltext,greet) != $null) did -c auto 12
- if ($readini($active $+ .ini,$did(auto,3).seltext,owner) == yes) did -c auto 8
- if ($readini($active $+ .ini,$did(auto,3).seltext,halfop) == yes) did -c auto 13
- if ($readini($active $+ .ini,$did(auto,3).seltext,protect) == yes) did -c auto 6
- }
- if ($did == 7) {
- if ($did(auto,7).state == 1) writeini $active $+ .ini $did(auto,3).seltext op yes
- else writeini $active $+ .ini $did(auto,3).seltext op no
- }
- if ($did == 9) {
- if ($did(auto,9).state == 1) writeini $active $+ .ini $did(auto,3).seltext voice yes
- else writeini $active $+ .ini $did(auto,3).seltext voice no
- }
- if ($did == 10) {
- if ($did(auto,10).state == 1) writeini $active $+ .ini $did(auto,3).seltext kick yes
- else writeini $active $+ .ini $did(auto,3).seltext kick no
- }
- if ($did == 11) {
- if ($did(auto,11).state == 1) writeini $active $+ .ini $did(auto,3).seltext ban yes
- else writeini $active $+ .ini $did(auto,3).seltext ban no
- }
- if ($did == 12) {
- if ($did(auto,12).state == 1) writeini $active $+ .ini $did(auto,3).seltext greet $$?="What would you like to greet $did(auto,3).seltext with?"
- else writeini $active $+ .ini $did(auto,3).seltext greet no
- }
- if ($did == 8) {
- if ($did(auto,8).state == 1) writeini $active $+ .ini $did(auto,3).seltext owner yes
- else writeini $active $+ .ini $did(auto,3).seltext owner no
- }
- if ($did == 13) {
- if ($did(auto,13).state == 1) writeini $active $+ .ini $did(auto,3).seltext halfop yes
- else writeini $active $+ .ini $did(auto,3).seltext halfop no
- }
- if ($did == 6) {
- if ($did(auto,9).state == 1) writeini $active $+ .ini $did(auto,3).seltext protect yes
- else writeini $active $+ .ini $did(auto,3).seltext protect no
- }
- if ($did == 18) {
- did -a auto 3 $did(auto,16).text
- writeini $active $+ .ini $did(auto,16.text) aop no
- did -r auto 16
- did -b auto 18
- }
- }
- on @*:join:#:{
- cs set $chan secureops off
- if ($readini($chan $+ .ini,$nick,op) == yes) mode $chan +o $nick
- if ($readini($chan $+ .ini,$nick,voice) == yes) mode $chan +v $nick
- if ($readini($chan $+ .ini,$nick,kick) == yes) kick $chan $nick (Settings From My Dialog)
- if ($readini($chan $+ .ini,$nick,ban) == yes) ban $chan $address($nick,2) (Settings From My Dialog)
- if ($readini($chan $+ .ini,$nick,greet) != no && $readini($chan $+ .ini,$nick,greet) != $null) {
- msg $chan $readini($chan $+ .ini,$nick,greet)
- }
- if ($readini($chan $+ .ini,$nick,owner) == yes) mode $chan +q $nick
- if ($readini($chan $+ .ini,$nick,halfop) == yes) mode $chan +h $nick
- if ($readini($chan $+ .ini,$nick,protect) == yes) mode $chan +a $nick
- }
Add Comment
Please, Sign In to add comment