Skip to content
MSN

Access list retrieve , help please

A TG007 community discussion started by emilkan.

Discussion 11 posts
Page 1 of 1
Open
Topic #1787 · 11 published posts · 1,249 views

I 'm writing to ask how i can retrieve the access list but not doing in the dialog ...

i'm using vincula 4.9 ... thankyou ~

for eg. .. loading the whole access list information into a variable ~

think you would find that a var would be too long after about 3 access entries

My code does NOT have bugs. It just develops random features.

arrrrr.. then does vincula provide any identifiers to facilitate this job ???

 

i wish i could countrol the access list through the remote script ...any advise pls ?

 

 

access list is all RAWS, so u cant set them in a variable

u can recall them to echo in the active window of the channel though it'll be exhausting to read within all the room msgs,actions,joins..etc.

 

about part 2, i didnt really get wut u meant with 'controlling access list with remote scripts'

o_O

on me:*:join:#:hop #

Hi emilkan,

Thats been on my mind also, funny that someone else brings it up. While updating the webtv control panel..I was thinking that it would be nice for the webtv hosts to be able to view...instead of only editting the access list.

 

Was considering having it write to .txt file and then having it echo or ctcp reply to the remote location. Haven't worked through it in code, just still in thought.

 

Was that the same type of thing you were looking at?

 

If you just want to add or delete access entries from a remote location then something like this works:

 

I'll just post the whole code:

Its not tested yet, as it was just finished a few hours ago.



@command Center 2004

-allows you to give your webtv hosts/owners the ability to host/unhost kick/ban
and change some room modes, by using a remote control system in your script.
-All room hosts/owners including webtv can use these commands.

-----------------------------------------------------------------------
on *:TEXT:*@help*:*: { 
 /ctcp $nick @host name
 /ctcp $nick @unhost name

}
on *:TEXT:*@kick!*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     if ($2 isin $nick) /kick $chan $nick $3
   }
 }
}
on *:TEXT:*@ban!*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     if ($2 isin $nick) { 
       if ($3 = $null) $3 = 15
       /access $chan add Deny $nick $3
       msg $chan $2 possible match: $nick 
       msg $chan To remove this ban use: @remove $nick
       /kick $chan $nick $2 possible match = $nick Banned for: $4 $3 minute(s) 

     }
   }
 }
}
on *:TEXT:*@remove*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     /access $chan delete deny $2
     /msg $chan Unbanning $2
   }
 }
}

on *:TEXT:*@moderated on*:*: { (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     /mode $chan +m 
     /msg $chan Moderated Room Set
   }
 }
}
on *:TEXT:*@moderated off*:*: { (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     /mode $chan -m
     /msg $chan Moderated Room Off
   }
 }
}
on *:TEXT:*@host*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     if ($2 = $me) { 
       /msg $chan You can't host me.
       halt
     }
     /mode $chan +o $2 
     /msg $chan Hosting $2
   }
 }
}
on *:TEXT:*@unhost*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     if ($2 = $me) { 
       /msg $chan You can't unhost me.
       halt
     }
     /mode $chan +o $2 
     /msg $chan Hosting $2
   }
 }
}
on *:TEXT:*@kick*:*: {  (%webtvcommandcenter == On) {
   if ($2 = $me) { 
     /msg $chan You can't kick me
     halt
   }
   if ($nick isop $chan) {
     /kick $chan $2 $3 
     /msg $chan kicking $2
   }
 }
}
on *:TEXT:*@ban*:*: {  (%webtvcommandcenter == On) {
   if ($2 = $me) { 
     /msg $chan You can't kick me
     halt
   }
   if ($nick isop $chan) {
     /access $chan add Deny $2 $3
     if ($3 = $null) $3 = 60
     msg $chan To remove this ban use: @remove $2
     /kick $chan $2 $4 (Banned $3 minute(s)) 
   }
 }
}
on *:TEXT:*@guestban on*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     if ($3 = $null) $3 = indefinate
     /access $chan add deny >*!*@*$* $3 Guest-Ban
     /msg $chan Adding Guest Ban For: $3 Minute(s)
   }
 }
}
on *:TEXT:*@guestban off*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     /access $chan delete deny >*!*@*$*
     /msg $chan Removing Guest Ban.
   }
 }
}
on *:TEXT:*@allow webtv*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     /access $chan add VOICE >*!*D21DB211*@*$* 
     /msg $chan Adding Webtv Access Entry.
   }
 }
}
on *:TEXT:*@allow webtv off*:*: {  (%webtvcommandcenter == On) {
   if ($nick isop $chan) {
     /access $chan delete VOICE >*!*D21DB211*@*$* 
     /msg $chan Removing Webtv Access Entry.
   }
 }
}


on *:LOAD: {  set %webtvcommandcenter $=on On 
 /echo $color(highlight text) -at [WebTv Command Center Is On]
 /echo $color(highlight text) -at All hosts/owners, including webtv are able to use this feature.
 /splay notify.wav 
}
on *:UNLOAD: { set %webtvcommandcenter $=off Off 
 /echo $color(highlight text) -at [WebTv Command Center Is Off]
 /splay unload.wav 
}

menu menubar { 
 -
 $iif(%webtvcommandcenter == On,$style(1)) @Command Center: /webtvcommands
 -
}


alias webtvcommands dialog -m webtvcommands webtvcommands

dialog webtvcommands { 
 title "@Command Center"
 icon $mircexe , 18
 size -1 -1 150 240
 option dbu
 box "", 1, 2 1 146 237

 button "On", 4, 10 10 15 9
 button "Off", 5, 28 10 15 9
 text "", 34, 47 12 30 9
 text "@command Center Information", 12, 8 26 80 9
 text "@command Center allows you to provide your webtv hosts and owners with the ability to kick, ban, host, unhost, change room modes etc within your room.  This works through a 'remote @command' system. They are able to type onto the screen @commands, which tell your bot to kick or ban or host or change room modes etc..", 13, 8 35 135 60
 text "Here are the @commands: ", 14, 8 80 135 7
 text "@host name", 15, 10 88 40 7
 text "@unhost name", 16, 70 88 40 7
 text "@kick name message", 21, 10 96 70 7
 text "@ban name minutes message", 22, 70 96 75 7
 text "@invite on", 17, 10 104 40 7
 text "@invite off", 18, 70 104 40 7
 text "@moderated on", 19, 10 112 40 7
 text "@moderated off", 20, 70 112 40 7
 text "@room whispers on", 23, 10 120 55 7
 text "@room whispers off", 24, 70 120 455 7
 text "@guest whispers on", 25, 10 128 55 7
 text "@guest whispers off", 26, 70 128 55 7
 text "@guestban on", 28, 10 136 45 7
 text "@guestban off", 29, 70 136 45 7
 text "@allow webtv", 30, 10 144 45 7
 text "@allow webtv off", 31, 70 144 70 7
 text " Example: @kick Gwen 60 Profanity", 32, 15 151 137 7
 text "Webtv hosts/owners are able to use all of your !host commands and remote commands also.", 33, 8 162 137 20
 text "*Use @kick! with a partial name for those hard to kick nicks..but be careful as it will kick any nick with that partial name in it: Example: @kick! gwe scrolling", 36, 10 177 137 20
 text "*Use @ban! with a partial name for those hard to ban nicks..but be careful as it will ban any nick with that partial name in it: Example: @ban! gwe 20 profanity", 37, 10 199 137 20
 text "*Use @remove name for those times you want to remove a ban you placed on a nick.", 38, 10 220 137 20
}
on *:DIALOG:webtvcommands*:init:*: {
 var %c did -a $dname, 
 %c 34 %webtvcommandcenter
}
on *:DIALOG:webtvcommands:sclick:4: { /set %webtvcommandcenter On
 /echo $color(highlight text) -at [WebTv Command Center Is On]
 /echo $color(highlight text) -at All hosts/owners, including webtv are able to use this feature.
 /splay notify.wav  
 did -a $dname 34 %webtvcommandcenter
}
on *:DIALOG:webtvcommands:sclick:5: { /set %webtvcommandcenter Off 
 /echo $color(highlight text) -at [WebTv Command Center Is Off]
 /splay unload.wav 
 did -a $dname 34 %webtvcommandcenter
}

 

Edited Oct 31, 2004 3:47 AM by Gwen
oops.gif yo ~~~ i'm right planning to do so ....but no clue in how to recall the list except view in dialog ... raw 802-805 is only could be captured while someone is accessing it .... so .. i need some advise

Didn't Command Center by NightChills run off of variables? Maybe I'm wrong, but thought it did.

 

Edit:

Yes it does, just checked it. It's on techgear, under addons I think, if you want to look at how he did it..from the raws. or message me and I can send it it you.

 

 

Edited Oct 31, 2004 3:57 AM by Gwen

this code only can change the entry of the access .. but not retrieving the access in a list form ... so it cannnot accomplish what i wish actually ..

 

i want to know the access content remotely ... but not doing ban or unban stuff ...

 

 

 

Hi Emilkan,

 

The code doesn't retrieve the access list..but the Command Center by NightChills does..and he saves the access list to variables...all without opening the access list dialog itself. If you look at his coding you would get a good idea of how to do it.

 

 

Edited Oct 31, 2004 4:06 PM by Gwen

sorry .. i couldn't find it ..

would u pls tell where can find his addons ??

i found the script now .. thx your help ..

but i 'm not good at the dialog scripting ..so .. so difficult for me to understand it

 

but 1 question i want to ask is ... any command will trigger raw 802 - 805 besides /access << since /acces will bring up the vincula dialog and halt for the second call