.



December, 1999

When mIRC 5.6 first came out, loud screams were heard that it was full of bugs, and that a good deal of scripts and aliases were ruined. I was alarmed too, and went back to version 5.5. Some time later though, a good friend of mine steered me to a web page which did an evaluation of the changes done in version 5.6, done by MissPai:

http://www.pairc.com/cgi-bin/a-view.cgi?code=21

After I read this, it seemed to me that the changes were not so much after all. I then read versions.txt included in mIRC 5.6, and found out what exactly had changed to cause all this hue and cry. It seems most of it is caused by one major change: the way mIRC looks for text in four string identifiers, all having to do with text manipulations.
It seems unfair to me that people who have taught me how to use mIRC are now reluctant to use 5.6, scared that it will mess up their files. This is an opportunity for me to lend some assistance for them to understand the changes, and show how to modify their files.


Changes:
======


$left
$right
$str


There are many changes, but the differences that matter are caused by
$left , $right , $mid and $str

$left had the following syntax before 5.6:
$left(N,text) where N was a number, that would take N letters to the left of text
so
$left(1,text) would give : t (the first character in "text")
and
$left(2,text) would give : te (the first two characters in "text")

the syntax has simply changed to:
$left(text,N)

mIRC now looks for the text first and what to do with that text second
so
$left(text,1) will still give : t
and
$left(text,2) will give : te
So most of the time when you see $left, if you move the item denoting the "text" to the first place in the parenthesis, your problem will be solved.

Like this:
$left(1,hello) becomes
$left(hello,1)
the same is true of $right and $str

of course, life is never that simple :(
what if the command uses variables, like this??
$left(%i,%p)
which is the text and which is the number? I have seen aliases which have both the old syntax, and the new syntax in different lines.
You have to study the script, and determine which variable is the text, and which variable is the number.
Remember, the number comes in the end.

$mid:
===


While similar, the use of $mid is a little bit more complicated.

the old syntax was like this:

$mid(A,B,text)

it would take B characters, starting from the A position in the text (heh, that looks confusing even to me)
like this:
$mid(3,2,thing)would give in (the third position is i, and the two characters there are in
this has now changed to
$mid(text,A,B) In the example above, it would become
$mid(thing,3,2), using the new syntax.
So moving the text part, from the end of the parenthesis to the start of the parenthesis, will enable you to fix problems with $mid.

help for mIRC 5.7 back to my mIRC page