You're right.
//Code value test
function serverCMDCheckInt(%client,%val)
{
if(%val * 1 = %val)
echo("\c6 Value is \c4" @ %val @ " ");
else
echo("\c0 Value Error");
}
That code doesn't work at all, so it returns nothing
It'd need to be
if(%val * 1 == %val)
But it doesn' t work as a check for numbers anyways. Try the below code with anything as %val:
%val = "h"; if(%val * 1 == %val) { echo("it's a number"); }
Now try out this code:
%val = "545"; if(%val * 1 $= %val) { echo("it's a number"); }
It actually seems to to exactly as intended, until INTEGER numbers exceed negative or positive 1 million as the number string is changes to 1.0000e+006.
EDIT: It'll only take 6 digits total, whether it be -53.6353, 535632, -0.157845, or -1.52453, so you'd probably want to ensure this isn't exceeded if you use this code for other purposes.