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.
Support & discussion of released scripts, and announcements of new releases.
skeletor1969
Voice
Posts: 8 Joined: Wed Jul 25, 2018 2:20 pm
Post
by skeletor1969 » Fri Aug 24, 2018 4:08 pm
If anyone is interested. I have found a working script that uses omdbapi and displays the imdb information. The only catch is you have to sign up for a free api key but thats it and it works perfectly. You can also change the bind from !movie to !imdb by uncommenting a line in the script.
[12:59pm] <~skeletor> !movie deadpool
[12:59pm] <&`slut> Deadpool (2016) R | 108 min | Action, Adventure, Comedy | 12 Feb 2016
[12:59pm] <&`slut> Cast: Ryan Reynolds, Karan Soni, Ed Skrein, Michael Benyaer
[12:59pm] <&`slut> Plot: A fast-talking mercenary with a morbid sense of humor is subjected to a rogue experiment that leaves him with accelerated healing powers and a quest for revenge.
[12:59pm] <&`slut> Metascore: 65, IMDB Rating: 8.0
[12:59pm] <&`slut>
http://www.imdb.com/title/tt1431045/
https://www.m00nie.com/2018/02/movie-se ... using-api/
Just a thought.
Dominatez
Halfop
Posts: 50 Joined: Mon Jan 14, 2019 5:08 pm
Location: United Kingdom
Post
by Dominatez » Wed Aug 07, 2019 8:16 am
No longer works.
Has started spitting out the following error.
unexpected '<' in TOP mode
Anyone any ideas ?
Fire-Fox
Master
Posts: 299 Joined: Sat Sep 23, 2006 9:01 pm
Location: /dev/null
Post
by Fire-Fox » Fri Nov 01, 2019 6:04 pm
It dosn't work for me, i get
Code: Select all
!imdb Beautiful Mind
Error in search mechanics - you probably need a newer version.
Gordon
Voice
Posts: 35 Joined: Wed Apr 04, 2007 11:45 am
Post
by Gordon » Wed Mar 04, 2020 1:55 pm
Madalin wrote: Another script for does interested is:
Code: Select all
# +-------------------------------------------------------------------------------------+
# | |
# | iMDB v1.0.0 |
# | |
# +-------------------------------------------------------------------------------------+
# | |
# | *** Website @ http://www.EggdropTCL.com |
# | *** GitHub @ http://github.com/MadaliNTCL/eggdrop-tcl |
# | |
# +-------------------------------------------------------------------------------------+
# | *** IRC Support: |
# | #EggdropTCL @ QuakeNET |
# | #EggdropTCL @ UnderNET |
# | #EggdropTCL @ EfNET |
# | |
# | *** Contact: |
# | Yahoo Messenger/Mail: madalinmen28@yahoo.com |
# | Google Mail : madalinmen28@gmail.com |
# | Skype Messenger : madalinmen28 |
# | |
# +-------------------------------------------------------------------------------------+
# + *** Commands *** |
# | +---------------+ |
# | [ OP - PUBLIC ] |
# | +---------------+ |
# | |
# | +++ !imdb <on/off> |
# +-------------------------------------------------------------------------------------+
bind PUBM - * imdb
bind PUBM - * imdb:pubm
package require json
package require http
package require tdom
setudef flag imdb
proc imdb:pubm {nick uhost hand chan arg} {
global temp
if {[string index $arg 0] in {! . `}} {
set temp(cmd) [string range $arg 1 end]
set temp(cmd) [lindex [split $temp(cmd)] 0]
set arg [join [lrange [split $arg] 1 end]]
} elseif {[isbotnick [lindex [split $arg] 0]]} {
set temp(cmd) [lindex [split $arg] 1]
set arg [join [lrange [split $arg] 2 end]]
} else { return 0 }
if {[info commands imdb:$temp(cmd)] ne ""} { imdb:$temp(cmd) $nick $uhost $hand $chan $arg }
}
proc imdb:imdb {nick uhost hand chan arg} {
global imdb iignore
switch -exact -- [lindex [split $arg] 0] {
on {
if {[isop $nick $chan]} {
channel set $chan +imdb
putserv "PRIVMSG $chan :\002$nick\002 - \00302Set channel mode \00306+imdb\0032 on \00304$chan"
}
}
off {
if {[isop $nick $chan]} {
channel set $chan -imdb
putserv "PRIVMSG $chan :\002$nick\002 - \00302Set channel mode \00306-imdb\0032 on \00304$chan"
}
}
}
}
proc imdb {nick uhost hand chan arg} {
global imdb iignore
if {![channel get $chan imdb]} { return }
## ++
set floodtime 10
## ++
if {![info exists iignore($nick)]} {
set iignore($nick) [unixtime]
utimer $floodtime [list unset -nocomplain iignore($nick)]
}
## ++
if {[expr [unixtime]-$iignore($nick)]>$floodtime} { putlog "ignoram"; return 0 }
regexp -all -nocase {(tt[0-9]{7})} $arg match imdbid
if {[catch {http::geturl http://www.omdbapi.com/?[http::formatQuery i $imdbid]} tok]} {
putlog "Socket error: $tok"
return 0
}
if {[http::status $tok] ne "ok"} {
set status [http::status $tok]
putlog "TCP error: $status"
return 0
}
if {[http::ncode $tok] != 200} {
set code [http::code $tok]
http::cleanup $tok
putlog "HTTP Error: $code"
return 0
}
set data [http::data $tok]
set parse [::json::json2dict $data]
set year [dict get $parse Year]
set title [dict get $parse Title]
set runtime [dict get $parse Runtime]
set genre [dict get $parse Genre]
set rating [dict get $parse imdbRating]
set votes [dict get $parse imdbVotes]
set plot [dict get $parse Plot]
set awards [dict get $parse Awards]
putserv "PRIVMSG $chan :\0031,8\002iMDB\002\003 - \00312$title\003 \037\[\037$runtime ($year)\037\]\037 \037\002/\002\037 \00306$genre\003 \037\002/\002\037 \002$rating\002 (\00302Votes\003: \00304$votes\003) \037\002/\002\037 Plot: \00310$plot\003 \037\002/\002\037 \00302Awards\003: \00304$awards"
}
putlog "++ \[ - \00304PUBLIC\003 - \00306loaded\003 * \00303iMDB\003 \]"
is triggered when imdb links are posted in the channel
This script makes bot error with
Code: Select all
Socket error: can't read "imdbid": no such variable
on every message in the channel.
Can anyone advice how to fix it?