- alias autovoice { dialog -md autovoice autovoice }
-
- dialog autovoice {
- title "Auto Voice by Lod"
- size -1 -1 108 145
- option dbu
- list 4, 46 15 54 73, size
- check "Activer +v sur tout les channels", 5, 10 92 87 10, flat
- button "ok !", 6, 57 125 37 12, ok
- text "Chanel avec auto +v :", 7, 44 2 57 8, center
- box "Group Box", 8, -25 -23 166 129
- button "Ajouter", 9, 4 16 37 12
- button "Supprimer", 10, 4 38 37 12
- check "Désactiver Tout", 21, 11 110 50 10, flat
- menu "Fenetre", 13
- item "Cancel", 40, 13, cancel
- }
-
- dialog addvoice {
- title "Ajouter un chan"
- size -1 -1 106 36
- option dbu
- text "Entrer le nouveau channel :", 1, 4 7 80 8
- edit "", 2, 8 19 50 10
- button "Ajouter", 3, 65 18 31 11
- }
-
- on *:dialog:autovoice:init:*:{
- if ( %allvoice == 1 ) { did -c autovoice 5 }
- if ( %voice.actif == 0 ) { did -c autovoice 21 }
- voice.init
- }
-
- on *:dialog:autovoice:sclick:*:{
- if ($did = 6) {
- if ($did(autovoice,5).state == 1) { set %allvoice 1 }
- elseif ($did(autovoice,5).state == 0) { set %allvoice 0 }
- if ($did(autovoice,21).state == 1) { set %voice.actif 0 }
- elseif ($did(autovoice,21).state == 0) { set %voice.actif 1 }
- }
- elseif ($did = 9) { dialog -md addvoice addvoice }
- elseif ($did = 10) {
- set %chan.voice $remtok(%chan.voice,$gettok(%chan.voice,$did(4).sel,44),44)
- voice.init
- }
- }
-
- on *:dialog:addvoice:sclick:3:{
- if ( $chr(44) isin $did(2) ) { var %erreurr = $input(Ne met pas de point virgule !,300,Avertissement) | halt }
- var %addvoice = $did(2)
- set %chan.voice $sorttok($addtok(%chan.voice,%addvoice,44),44)
- /dialog -x addvoice addvoice
- voice.init
- }
-
-
- alias voice { mode $chan +v $nick }
-
- alias voice.init {
- did -r autovoice 4
- if (%chan.voice !== $null) {
- var %autovoice.loop.n = 1
- :loop
- did -a autovoice 4 $gettok(%chan.voice,%autovoice.loop.n,44)
- inc %autovoice.loop.n
- if ($gettok(%chan.voice,%autovoice.loop.n,44) !== $null) { goto loop }
- }
- else {
- unset %chan.voice
- } }
-
-
- on *:JOIN:*: {
- if (($me !isop $chan) || ($me !ishop $chan)) { halt }
- elseif ($chan isin %chan.voice && %voice.actif == 1) { voice }
- elseif (%allvoice == 1 && %voice.actif == 1) { voice }
- }
-
- on *:load:{ set %voice.actif 1 | set %allvoice 0 | echo -a 4 Auto-voice Chargé | echo -a 4Script by Lodtripe }
-
- menu menubar,channel {
- -
- :: Auto Voice ::
- .Lancer:/autovoice
- }
alias autovoice { dialog -md autovoice autovoice }
dialog autovoice {
title "Auto Voice by Lod"
size -1 -1 108 145
option dbu
list 4, 46 15 54 73, size
check "Activer +v sur tout les channels", 5, 10 92 87 10, flat
button "ok !", 6, 57 125 37 12, ok
text "Chanel avec auto +v :", 7, 44 2 57 8, center
box "Group Box", 8, -25 -23 166 129
button "Ajouter", 9, 4 16 37 12
button "Supprimer", 10, 4 38 37 12
check "Désactiver Tout", 21, 11 110 50 10, flat
menu "Fenetre", 13
item "Cancel", 40, 13, cancel
}
dialog addvoice {
title "Ajouter un chan"
size -1 -1 106 36
option dbu
text "Entrer le nouveau channel :", 1, 4 7 80 8
edit "", 2, 8 19 50 10
button "Ajouter", 3, 65 18 31 11
}
on *:dialog:autovoice:init:*:{
if ( %allvoice == 1 ) { did -c autovoice 5 }
if ( %voice.actif == 0 ) { did -c autovoice 21 }
voice.init
}
on *:dialog:autovoice:sclick:*:{
if ($did = 6) {
if ($did(autovoice,5).state == 1) { set %allvoice 1 }
elseif ($did(autovoice,5).state == 0) { set %allvoice 0 }
if ($did(autovoice,21).state == 1) { set %voice.actif 0 }
elseif ($did(autovoice,21).state == 0) { set %voice.actif 1 }
}
elseif ($did = 9) { dialog -md addvoice addvoice }
elseif ($did = 10) {
set %chan.voice $remtok(%chan.voice,$gettok(%chan.voice,$did(4).sel,44),44)
voice.init
}
}
on *:dialog:addvoice:sclick:3:{
if ( $chr(44) isin $did(2) ) { var %erreurr = $input(Ne met pas de point virgule !,300,Avertissement) | halt }
var %addvoice = $did(2)
set %chan.voice $sorttok($addtok(%chan.voice,%addvoice,44),44)
/dialog -x addvoice addvoice
voice.init
}
alias voice { mode $chan +v $nick }
alias voice.init {
did -r autovoice 4
if (%chan.voice !== $null) {
var %autovoice.loop.n = 1
:loop
did -a autovoice 4 $gettok(%chan.voice,%autovoice.loop.n,44)
inc %autovoice.loop.n
if ($gettok(%chan.voice,%autovoice.loop.n,44) !== $null) { goto loop }
}
else {
unset %chan.voice
} }
on *:JOIN:*: {
if (($me !isop $chan) || ($me !ishop $chan)) { halt }
elseif ($chan isin %chan.voice && %voice.actif == 1) { voice }
elseif (%allvoice == 1 && %voice.actif == 1) { voice }
}
on *:load:{ set %voice.actif 1 | set %allvoice 0 | echo -a 4 Auto-voice Chargé | echo -a 4Script by Lodtripe }
menu menubar,channel {
-
:: Auto Voice ::
.Lancer:/autovoice
}