This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Duel Request bot script

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
N
Nssvtr
Voice
Posts: 6
Joined: Sun Aug 17, 2014 11:13 pm

Duel Request bot script

Post by Nssvtr »

I am a DJ for a radiostation and online station and we have a radio bot we have a secrete room that we would like to use our eggdrop bot to pick up on a request that is !request Artist - Song and it will be noticed by our eggdrop bot and reply it in another room possibly on a different server if possibly if not thats fine but if it can reply to another room that would be awesome so it pics up from the other bot and sends the request in....I also forget to mention we use Icecast if that is needed info
w
willyw
Revered One
Posts: 1197
Joined: Thu Jan 15, 2009 12:55 am

Re: Duel Request bot script

Post by willyw »

Nssvtr wrote:I am a DJ for a radiostation and online station and we have a radio bot we have a secrete room that we would like to use our eggdrop bot to pick up on a request that is !request Artist - Song and it will be noticed by our eggdrop bot and reply it in another room possibly on a different server if possibly
One Eggdrop bot cannot connect to two irc servers simultaneously.
http://www.egghelp.org/faq.htm#044

To do what you describe, would require two bots, connected to each other using Eggdrop's botnet capability, along with a script that can use this connection.
if not thats fine but if it can reply to another room that would be awesome
One bot, on one irc server, in at least two channels, that relays upon command from one channel to another? If so, there are probably already scripts in the TCL archive that would do it. If not, it would be easy to write such a script.

It would be a good place for a beginner to start learning basic TCL. :)
so it pics up from the other bot and sends the request in....I also forget to mention we use Icecast if that is needed info
"other bot". What other bot?
N
Nssvtr
Voice
Posts: 6
Joined: Sun Aug 17, 2014 11:13 pm

Post by Nssvtr »

ya we have 2 bots on 2 different servers thats no issue there we just need them to transtlate to eachother to basically repeat its self from one to the other if that spossible been through the archives havnt seen anything unless you see one
N
Nssvtr
Voice
Posts: 6
Joined: Sun Aug 17, 2014 11:13 pm

Post by Nssvtr »

aswell it would need a trigger in order to actually repeat cause i dont want it to repeat everything just when people do !request then there artist and song
w
willyw
Revered One
Posts: 1197
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

Nssvtr wrote:ya we have 2 bots on 2 different servers thats no issue there we just need them to transtlate to eachother to basically repeat its self from one to the other if that spossible been through the archives havnt seen anything unless you see one
By what method are you looking??
I see lots of them.

http://www.egghelp.org/tclhtml/3478-4-4-0-1.htm


p.s.
It is very difficult to read your posts, due to lack of punctuation and capitalization.
w
willyw
Revered One
Posts: 1197
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

Nssvtr wrote:aswell it would need a trigger in order to actually repeat cause i dont want it to repeat everything just when people do !request then there artist and song
One way: Examine one of those relay scripts, and borrow some ideas and code. Instead of having it trigger on everything said, change the bind to one such that it triggers on your command word, when you write your own script.

Other way: Choose one of those scripts. Set it up and get it working. Then experiment with changing the bind(s), to make it react to your trigger word only.
N
Nssvtr
Voice
Posts: 6
Joined: Sun Aug 17, 2014 11:13 pm

Post by Nssvtr »

I been have been working and checking them out but they are not exactly what im looking for. What i need is a trigger system that a bot is gonna pick up on a !request <--- that trigger that anything after that the bot will take and mirror the message to another eggdrop on another channel. So the but in the second channel will display what the bot in the first channel has said BUT ONLY when when it sees !request not all text,kicks,bans and joins none of that. Just need a simple trigger mirror basically.
User avatar
play4free2
Voice
Posts: 34
Joined: Sat Nov 23, 2013 1:42 am
Contact:

Post by play4free2 »

Code: Select all

########################################################################
#
# Public Request for Radio Channel  - Author: play4free2
#
# version: 0.01
# by  (play4free2@420-hightimes.com)
#
# To use Type !request Artist - Song Title
#
# To enable in your channel(s) you want users to request from
# type ".chanset <channel> +radiorequest"
#
########################################################################
#Begin Setup

#DJ Staff Channel:
set radiostaff "#STAFFCHANNELHERE"

#End Setup
#########################################################
#DO NOT EDIT BELOW HERE UNLESS YOU KNOW HOW TO WRITE .tcl
#########################################################
bind pub -|- !request shoutcast_request

proc shoutcast_request {nick uhost hand chan arg} {
  global radiostaff
  if {[lsearch -exact [channel info $chan] +radiorequest] != -1} {
    set cmd [string tolower [lindex $arg 0]]
    if {$cmd == ""} {
      putserv "NOTICE $nick :Please use\: !request Artist - Song Title"
      return 0
      } else {
      putserv "PRIVMSG $radiostaff :\00304\002Request from\002\: \00303$nick \00304\002for\002\: \00303$arg\003"
      putserv "NOTICE $nick :Your request for \002'$arg'\002 has been succesfully sent to the station's staff."
    }
  }
}

setudef flag radiorequest
putlog "Public Request for Radio Channel v0.01 by: play4free2 irc.420-hightimes.com #HighTimes-Lounge loaded! Type .chanset <channel> +radiorequest to enable in your channel(s)"
Last edited by play4free2 on Fri Oct 02, 2020 10:15 pm, edited 5 times in total.
Image
420-HIGHTIMES IRC Network
User avatar
Get_A_Fix
Master
Posts: 206
Joined: Sat May 07, 2005 6:11 pm
Location: New Zealand

Post by Get_A_Fix »

play4free2, cool script, but there is one suggestion, if you don't mind.

Code: Select all

if {[lsearch -exact [channel info $chan] +radiorequest] != -1} {
For years, I also used this method. It's great and all, but now there's a much better, simpler way :)

Code: Select all

if {[channel get $chan radiorequest]} {
The above will check if radiorequest is true, else

Code: Select all

if {![channel get $chan radiorequest]} {
this would return not enabled.

I always have a habit of turning my scripts on/off, it makes it a lot easier to manage.
We explore.. and you call us criminals. We seek after knowledge.. and you call us criminals. We exist without skin color, without nationality, without religious bias.. and you call us criminals.
User avatar
play4free2
Voice
Posts: 34
Joined: Sat Nov 23, 2013 1:42 am
Contact:

Post by play4free2 »

Thanks Get_A_Fix,

I have used both really it just happened that when I wrote this part I wrote it this way. It's just part of my shoutcast.tcl I took out if Nssvtr wanted to use it was all.

I have also wrote it this way in a few codes:

Code: Select all

if {![channel get $chan radiorequest]} { return }
Image
420-HIGHTIMES IRC Network
Post Reply