mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
#164066 07/11/06 11:03 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
If this is in the wrong section then I apologize.

I'm having some kind of crisis wif my $identifiers in one of my scripts.



And yet:

//echo -aet $_qt(Hello!)
//echo -aet $is_service(ChanServ)

Quote:

* No such identifier: $_qt
* No such identifier: $is_service


I've actually reloaded the script three times and restarted mIRC, and yet it's still not working. frown

Any help would be greatly appreciated.

#164067 07/11/06 11:11 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
Well, the aliases appear to be fine. Have you looked to make sure you don't have any {} mismatches? That would be the only thing I can think of.

The strange thing is that if I don't have those aliases entered and I try those echo commands you gave, I don't get the no such identifier errors. Instead, I get insufficient params for echo. (v6.2)

EDIT: You could also make your IF statement just see if $qt is valid rather than checking the version, if you wanted. if ($qt(a)) ... if it's valid, then you know $qt is available to use. Otheriwse, it would be $null and you'd know $qt wasn't available. Not really a big deal, but it does save a few characters. smile

Last edited by Riamus2; 07/11/06 11:15 PM.
#164068 07/11/06 11:12 PM
Joined: Jan 2003
Posts: 2,125
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,125
I don't see anything wrong, so look for the usual suspect: a bracket mismatch. Hit the {} key to see if there is one.

Btw, your $_qt/$_noqt aren't correct wink
Check
//echo -a $qt("abc")
and
//echo -a $noqt(a"b""c"d)
to see why

#164069 07/11/06 11:15 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
No bracket mismatch found.

Also, the $_noqt() isn't ment to be the same as $noqt(). However I'mma fix that $_qt() one. :P

Last edited by Jigsy; 07/11/06 11:16 PM.
#164070 07/11/06 11:17 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
Have you tried putting those aliases into a blank script to see if they work there?

Also, I edited my previous post in case you missed seeing that since it was edited when you were replying.

#164071 07/11/06 11:20 PM
Joined: Apr 2004
Posts: 755
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Apr 2004
Posts: 755
Checking if ($qt(a)) is not a very failsave method with custum identifiers called qt.

Admittingly it's a very small odd that someone has a qt alias loaded.

#164072 07/11/06 11:21 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
They'll work in any other remote scripts apart from this one. frown

#164073 07/11/06 11:22 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
Ah... good point. Well, then... if ($qt(a) == "a")

Granted that's not really much smaller and it's not really that helpful, either. That's what I get for not thinking it through all the way.

#164074 07/11/06 11:23 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
It would have to be a bracket issue, even if that button doesn't show you any. I don't know what else it could be. You could always put those aliases at the top of that script file.

EDIT: Does |_noqt work?

Last edited by Riamus2; 07/11/06 11:25 PM.
#164075 07/11/06 11:24 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
Weirdly enough the same problem still applies even if I do that. O_o

#164076 07/11/06 11:26 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
Does the rest of that script work?

What happens if you copy/paste that entire script into a new script file (*and unload the original*)? Perhaps the file is corrupted in Windows.

Last edited by Riamus2; 07/11/06 11:28 PM.
#164077 07/11/06 11:30 PM
Joined: Apr 2004
Posts: 755
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Apr 2004
Posts: 755
On that note ($qt() == "") would work just as well smile Still preffer version checking though.
Just a late night boring totally unimportant reply :P

#164078 07/11/06 11:30 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
Still won't work. smirk

#164079 07/11/06 11:34 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
Lol. You aren't having much luck tonight. It doesn't make sense if it doesn't work at the top of the script, but works on a new script, and doesn't work if the whole thing is on a new script.

(did you remember to unload the original?)

At that point, I might suggest sending the full script file to someone else to test and see if it is the script or something with your mIRC. As I mentioned, I don't get an unknown identifier error if it's not loaded.

#164080 07/11/06 11:40 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
Anyone willing to look at the code?

#164081 07/11/06 11:43 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
I'm not at home right now, so I can't. If you have no replies within about 2 hours, I'll be home and you can visit me in the #Invision channel (see my signature) and I'll look at it for you. I'm betting someone will be able to help before then, but I wanted to throw it out just in case.

#164082 07/11/06 11:47 PM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
No worries, I'll try bug someone off IRC in the mean time. :P

#164083 08/11/06 12:29 AM
Joined: Aug 2004
Posts: 7,168
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,168
I'm always willing to look at code. If it's small enough to post here, then please do so, otherwise contact me and we'll arrange a way for you to get the code to me. Please note that I'm unsure as to how much code can be placed in a single post, but I seem to remember having difficulties with very long codes previously (eg: 500 lines or more)

#164084 08/11/06 12:37 AM
Joined: Nov 2004
Posts: 822
J
Jigsy Offline OP
Hoopy frood
OP Offline
Hoopy frood
J
Joined: Nov 2004
Posts: 822
I'll e-mail it you.

#164085 08/11/06 01:08 AM
Joined: Aug 2004
Posts: 7,168
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,168
Thanks..I've reviewed the code and while I know why you're getting this problem, I'm unable to find a solution.

For some reason (and I haven't a clue as to why) your aliases aren't being recognized. You can test/check this yourself by using //echo -a $isalias(<alias name>)

If the alias exists (doesn't work with local aliases, since they can only be called from within the script), then it returns $true..otherwise $false

When I checked the aliases listed in your code, they returned $false, inspite of the fact that I can see the alias definition.

Sorry I can't be of more help.

Page 1 of 2 1 2

Link Copied to Clipboard