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 

Getting first Line of a on-the-web-located file
Goto page Previous  1, 2
 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
aap
Voice


Joined: 18 Jun 2006
Posts: 13

PostPosted: Mon Jun 19, 2006 1:26 pm    Post subject: Reply with quote

Wauw!

That is exactly what I needed!
Really thanks a lot!

aap

PS. if you need something from me Wink
Back to top
View user's profile Send private message
SaPrOuZy
Halfop


Joined: 24 Mar 2004
Posts: 75
Location: Lebanon

PostPosted: Tue Jun 20, 2006 3:10 am    Post subject: Reply with quote

i think you should declare check as global
try it.

Code:
bind time - * man ;# runs every minute
proc man {m h d mo y} {
 global check
   set a [info exists check]
   set fs [open file.txt r]
   gets $fs line(first)
   close $fs
   if { $a == 1 } {
      if { $check != $line(first) } {
         putserv "PRIVMSG #channel1 :$line(first)"
         unset check
         set check "$line(first)"
      }
   } elseif { $a == 0 } {
      set burpie "a is 0"
      putserv "PRIVMSG #channel1 :$burpie"
      set check "$line(first)"     
   } else {
      set burp "damnit, a is not 0 or 1"
      putserv "PRIVMSG #channel1 :$burp"
   }
}


EDIT: woops, i didn't see the second page of the post. Embarassed
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 -> Scripting Help All times are GMT - 4 Hours
Goto page Previous  1, 2
Page 2 of 2

 
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