egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

NowPlaying.tcl

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases
View previous topic :: View next topic  
Author Message
greenbear
Owner


Joined: 24 Sep 2001
Posts: 733
Location: Norway

PostPosted: Tue Jun 28, 2005 11:36 pm    Post subject: NowPlaying.tcl Reply with quote

Kinda pointless, but someone asked for it.

Code:
###
# NowPlaying.tcl v0.1 by greenbear <at> gmail.com
#
# Announce current and upcomming movies at the theatres.

bind pub - !nowplaying pub:playing
bind pub - !commingsoon pub:comming

if ![info exists egghttp(version)] {
  putlog "egghttp.tcl was NOT successfully loaded."
}

proc pub:playing {nick uhost hand chan text} {
  set sock [egghttp:geturl http://www.movietome.com/ [list parse:mtome $chan 0]]
}

proc pub:comming {nick uhost hand chan text} {
  set sock [egghttp:geturl http://www.movietome.com/ [list parse:mtome $chan 1]]
}

proc parse:mtome {chan type sock} {
 set data [egghttp:data $sock]
 egghttp:cleanup $sock

 set data [string map {"\n" ""} $data]
 set data [string map {"<p>" "<p>\n"} $data]

 if {!$type} {
   set to "Recently released movies:"
 } {
   set to "Upcoming movies:"
 }

 foreach line [split $data \n] {
   if [string match -noc "*$to*" $line] {
     set line [string map {"<br>" "<br>\n"} $line]
     regsub -all {<(.|\n)*?>} $line {} line
     foreach out [split $line \n] {
       if ![string match -noc "*Terms of Service*" $out] {
         putserv "PRIVMSG $chan :$out"
       }
     }
     continue
   }
 }
}

putlog "NowPlaying.tcl loaded."
Back to top
View user's profile Send private message Send e-mail
deadman
Voice


Joined: 08 May 2006
Posts: 18

PostPosted: Sun Feb 18, 2007 6:00 pm    Post subject: Reply with quote

Can anyone fix this and it dont seem to work anymore Sad
thnx
Back to top
View user's profile Send private message
Ladykiller
Voice


Joined: 18 Feb 2007
Posts: 7

PostPosted: Sun Feb 18, 2007 6:50 pm    Post subject: Reply with quote

errormsg etc.....
Some more infos would be helpfull
Back to top
View user's profile Send private message
rosc2112
Revered One


Joined: 19 Feb 2006
Posts: 1454
Location: Northeast Pennsylvania

PostPosted: Sun Feb 18, 2007 8:02 pm    Post subject: Reply with quote

The website changed and now redirects to filmspot.com.. Would be easier to simply write a new script to work with the new site. I'll put it on my todo list and see if I can get one written in a day or 3.
Back to top
View user's profile Send private message
deadman
Voice


Joined: 08 May 2006
Posts: 18

PostPosted: Sun Feb 25, 2007 1:41 pm    Post subject: Reply with quote

anyone had any look finding a working one wondered y it had stoped working Sad
Back to top
View user's profile Send private message
rosc2112
Revered One


Joined: 19 Feb 2006
Posts: 1454
Location: Northeast Pennsylvania

PostPosted: Mon Feb 26, 2007 6:49 pm    Post subject: Reply with quote

Done:
http://forum.egghelp.org/viewtopic.php?p=70772
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber