**********************************************
VEGETA T v2.0
By uN|x
Official Home Page www.ircvegetascript.cjb.net
E-mail ircvegetascript@email.it
**********************************************

dialog prott {
  title "[ VEGETA T ] v2.0 Protezioni"
  size 257 239 222 117
  option dbu
  tab "protezioni canale", 2, 72 1 148 94
  tab "protezioni flood 1", 300
  tab "protezioni flood 2", 400
  icon 1, 4 4 61 91, immagini\vegeprote.bmp
  check "mass @p", 3, 76 28 37 6, tab 2
  edit "", 4, 120 24 12 10, multi, return, tab 2
  text "@p in", 5, 140 28 37 6, tab 2
  edit "", 6, 176 24 12 10, multi, return, tab 2
  text "secondi", 7, 196 28 20 6, tab 2
  check "mass de@p", 8, 76 44 37 6, tab 2
  edit "", 9, 120 40 12 10, multi, return, tab 2
  text "de@p in", 10, 140 44 28 6, tab 2
  edit "", 11, 176 40 12 10, multi, return, tab 2
  text "secondi", 12, 196 44 20 6, tab 2
  check "mass kick", 13, 76 60 37 6, tab 2
  edit "", 14, 120 56 12 10, multi, return, tab 2
  text "kick in", 15, 140 60 20 6, tab 2
  edit "", 16, 176 56 12 10, multi, return, tab 2
  text "secondi", 17, 196 60 20 6, tab 2
  check "flood notice", 22, 76 28 37 6, tab 300
  edit "", 23, 120 24 12 10, multi, return, tab 300
  text "notice in", 24, 140 28 28 6, tab 300
  edit "", 25, 176 24 12 10, multi, return, tab 300
  text "secondi", 26, 196 28 20 6, tab 300
  check "flood canale", 27, 76 44 37 6, tab 300
  edit "", 28, 120 40 12 10, multi, return, tab 300
  text "messaggi in", 29, 140 44 28 6, tab 300
  edit "", 30, 176 40 12 10, multi, return, tab 300
  text "secondi", 31, 196 44 20 6, tab 300
  check "flood query", 32, 76 60 37 6, tab 300
  edit "", 33, 120 56 12 10, multi, return, tab 300
  text "messaggi in", 34, 140 60 32 6, tab 300
  edit "", 35, 176 56 12 10, multi, return, tab 300
  text "secondi", 36, 196 60 20 6, tab 300
  check "flood ctcp", 37, 76 76 37 6, tab 300
  edit "", 38, 120 72 12 10, multi, return, tab 300
  text "ctcp in", 39, 140 76 24 6, tab 300
  edit "", 40, 176 72 12 10, multi, return, tab 300
  text "secondi", 41, 196 76 20 6, tab 300
  check "topic flood", 44, 76 32 36 6, tab 400
  edit "", 45, 128 28 12 10, multi, return, tab 400
  text "in", 46, 152 32 8 6, tab 400
  edit "", 47, 172 28 12 10, multi, return, tab 400
  text "secondi", 48, 192 32 24 6, tab 400
  check "nick flood", 49, 76 48 37 6, tab 400
  edit "", 50, 128 44 12 10, multi, return, tab 400
  text "in", 51, 152 48 12 6, tab 400
  edit "", 52, 172 44 12 10, multi, return, tab 400
  text "secondi", 53, 192 48 24 6, tab 400
  button "ok", 42, 184 104 37 12, ok
  button "annulla", 43, 144 104 37 12, cancel
}

on *:dialog:prott:sclick:*:{
  if ($did == 50) { .splay sounds\click.wav | dialog -x prott prott | dialog -m protp protp }
  if ($did == 42) { .splay sounds\chiudi.wav }
  if ($did == 51) { .splay sounds\chiudi.wav }
  if ($did == 22) { if ($did(prott,22).state == 1) { set %noticeflood on | did -e prott 23,25 | .splay sounds\click.wav } | else { set %noticeflood off | did -b prott 23,25 | .splay sounds\click.wav } }
  if ($did == 27) { if ($did(prott,27).state == 1) { set %channelflood on | did -e prott 28,30 | .splay sounds\click.wav } | else { set %channelflood off | did -b prott 28,30 | .splay sounds\click.wav } }
  if ($did == 32) { if ($did(prott,32).state == 1) { set %queryflood on | did -e prott 33,35 | .splay sounds\click.wav } | else { set %queryflood off | did -b prott 33,35 | .splay sounds\click.wav } }
  if ($did == 37) { if ($did(prott,37).state == 1) { set %ctcpflood on | did -e prott 38,40 | .splay sounds\click.wav } | else { set %ctcpflood off | did  -b prott 38,40 | .splay sounds\click.wav } }
  if ($did == 3) { if ($did(prott,3).state == 1) { set %massop on | did -e prott 4,6 | .splay sounds\click.wav } | else { set %massop off | did -b prott 4,6 | .splay sounds\click.wav } }
  if ($did == 8) { if ($did(prott,8).state == 1) { set %massdeop on | did -e prott 9,11 | .splay sounds\click.wav } | else { set %massdeop off | did -b prott 9,11 | .splay sounds\click.wav } }
  if ($did == 13) { if ($did(prott,13).state == 1) { set %masskick on | did -e prott 14,16 | .splay sounds\click.wav } | else { set %masskick off | did -b prott 14,16 | .splay sounds\click.wav } }
  if ($did == 20) { if ($did(prott,20).state == 1) { .enable #antispam | set %antispam on | .splay sounds\click.wav } | else { .disable #antispam | set %antispam off | .splay sounds\click.wav } }
  if ($did == 18) { if ($did(prott,18).state == 1) { .enable #ciclop | set %ciclo on | .splay sounds\click.wav } | else { .disable #ciclop | set %ciclo off | .splay sounds\click.wav } }
  if ($did == 19) { if ($did(prott,19).state == 1) { set %dccprott on | .splay sounds\click.wav } | else { set %dccprott off | .splay sounds\click.wav } }
  if ($did == 44) { if ($did(prott,44).state == 1) { set %tflood on | did -e prott 45,47 | .splay sounds\click.wav } | else { set %tflood off | did  -b prott 45,47 | .splay sounds\click.wav } }
  if ($did == 49) { if ($did(prott,49).state == 1) { set %nflood on | did -e prott 50,52 | .splay sounds\click.wav } | else { set %nflood off | did  -b prott 50,52 | .splay sounds\click.wav } }
  if ($did == 56) { if ($did(prott,56).state == 1) { set %nuke1 on | .splay sounds\click.wav } | else { set %nuke1 off | .splay sounds\click.wav } }
  if ($did == 58) { if ($did(prott,58).state == 1) { set %nuke2 on | .splay sounds\click.wav } | else { set %nuke2 off | .splay sounds\click.wav } }
  if ($did == 60) { if ($did(prott,60).state == 1) { set %nuke3 on | .splay sounds\click.wav } | else { set %nuke3 off | .splay sounds\click.wav } }
  if ($did == 57) { run antinuke\anti.exe | .splay sounds\click.wav }
  if ($did == 59) { run antinuke\antinuke.exe | .splay sounds\click.wav }
  if ($did == 61) { run antinuke\nukenabber.exe | .splay sounds\click.wav }
  if ($did == 2) { .splay sounds\conferma.wav }
  if ($did == 300) { .splay sounds\conferma.wav }
  if ($did == 400) { .splay sounds\conferma.wav }
  if ($did == 500) { .splay spunds\conferma.wav }
}
on *:dialog:prott:sclick:64:{ if ($did(prott,64).state == 1) { set %prottban on | .splay sounds\click.wav } | else { set %prottban off | .splay sounds\click.wav } }

on *:dialog:prott:edit:*:{
  if ($did == 23) { set %numberonotice $did(23).text }
  if ($did == 25) { set %secondnotice $did(25).text }
  if ($did == 28) { set %numberomsg $did(28).text }
  if ($did == 30) { set %secondsms $did(30).text }
  if ($did == 33) { set %numberoquery $did(33).text }
  if ($did == 35) { set %secondquery $did(35).text }
  if ($did == 38) { set %ctcp.prot.num $did(38).text }
  if ($did == 40) { set %ctcp.prot.tme $did(40).text }
  if ($did == 4) { set %numberoop $did(4).text }
  if ($did == 6) { set %secondop $did(6).text }
  if ($did == 9) { set %numberodeop $did(9).text }
  if ($did == 11) { set %secondeop $did(11).text }
  if ($did == 14) { set %numberokick $did(14).text }
  if ($did == 16) { set %secondkick $did(16).text }
  if ($did == 45) { set %topic.rep $did(45).text }
  if ($did == 47) { set %topic.sec $did(47).text }
  if ($did == 50) { set %nick.rep $did(50).text }
  if ($did == 52) { set %nick.sec $did(52).text }
}
on *:dialog:prott:init:0:{
  if (%massop == on) { did -c prott 3 } | else { did -b prott 4,6 }
  if (%massdeop == on) { did -c prott 8 } | else { did -b prott 9,11 }
  if (%masskick == on) { did -c prott 13 } | else { did -b prott 14,16 }
  if (%noticeflood == on) { did -c prott 22 } | else { did -b prott 23,25 }
  if (%channelflood == on) { did -c prott 27 } | else { did -b prott 28,30 }
  if (%queryflood == on) { did -c prott 32 } | else { did -b prott 33,35 }
  if (%ctcpflood == on) { did -c prott 37 } | else { did -b prott 38,40 }
  if (%tflood == on) { did -c prott 44 } | else { did -b prott 45,47 }
  if (%nflood == on) { did -c prott 49 } | else { did -b prott 50,52 }
  if (%dccprott == on) { did -c prott 19 }
  if (%ciclo == on) { did -c prott 18 }
  if (%antispam == on) { did -c prott 20 }
  did -a prott 4 %numberoop
  did -a prott 6 %secondop
  did -a prott 9 %numberodeop
  did -a prott 11 %secondeop
  did -a prott 14 %numberokick
  did -a prott 16 %secondkick
  did -a prott 23 %numberonotice
  did -a prott 25 %secondnotice
  did -a prott 28 %numberomsg
  did -a prott 30 %secondsms
  did -a prott 33 %numberoquery
  did -a prott 35 %secondquery
  did -a prott 38 %ctcp.prot.num
  did -a prott 40 %ctcp.prot.tme
  did -a prott 45 %topic.rep
  did -a prott 47 %topic.sec
  did -a prott 50 %nick.rep
  did -a prott 52 %nick.sec
}
