mIRC Home    About    Download    Register    News    Help

Print Thread
#59224 05/11/03 07:41 AM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
I was given this code:

Code:
on *:action:*:#: {
    if (($1 == wonders) && ($2 == what) && ($4 == saying)) {
      describe # $read(sayings.txt,t)
  }
}


I was told to make a text file with the saying in it, one saying per line. I did. Put the sayins.txt file in the same folder as the script file was in.

Problem is....I can't get it to work. Does anyone know why?

#59225 05/11/03 07:46 AM
Joined: Dec 2002
Posts: 3,138
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
The file needs to be in mIRC's root directory, which is not necessarily the same folder you have the script in.

Make sure there aren't other on ACTION events that trigger above it in the same file, too.

#59226 05/11/03 08:00 AM
Joined: Sep 2003
Posts: 122
Gar Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Sep 2003
Posts: 122
thanks

#59227 05/11/03 02:41 PM
Joined: Jan 2003
Posts: 3,012
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
If you go into mirc, and type //echo $mircdir, you want it in that directory.


-KingTomato
#59228 05/11/03 04:30 PM
Joined: Sep 2003
Posts: 58
S
Babel fish
Offline
Babel fish
S
Joined: Sep 2003
Posts: 58
Hi Gar,

I'm the one that gave you the code...

You can also put the txt file in the same directory as the script...

You just need to change the following :

Code:
 on *:action:*:#: {    if (($1 == wonders) && ($2 == what) && ($4 == saying)) {      describe # $read( [color:red]Directory/sayings.txt[/color],t)  }} 


If the scripts is in this directory :
C:/mirc/scripts/yourscript.ini

Change the red part to :
scripts/sayings.txt


***************************
To chat, or not to chat.
That's the question
#59229 05/11/03 11:05 PM
Joined: Feb 2003
Posts: 810
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Feb 2003
Posts: 810
Use $scriptdir for that.


* cold edits his posts 24/7

Link Copied to Clipboard