Clutch
2015-03-08 23:44:21
Trying to input an if else statement. Basically I can use either the random age or the typical typesend age. It won't let me put an else at the end of it. I've spent hours trying to figure this out and am beyond frustrated at this point. Ideas?
Compiling failed.
I don't want to put an END; I want it to detect that it is an else after that. If this isn't an option I can switch the way it is called but I need a way to do the following
If (AGE) = an integer (ex. character creation screen, if they input ANY integer for their age it'll input it (this is a contsant) but if they leave it blank it'll give a random age)
then typeSend (AGE)
if USERNAME = '0' then //Generating Character Name
mouseBox(IntToBox(649,216,755,236), MOUSE_LEFT)
else
typesend (USERNAME);
ageBox := intToBox(497,322,538,313); //inserts default age else inserts random age thanks to @KeepBotting with this
mouseBox(ageBox, MOUSE_LEFT);
wait(1000);
if (AGE) = '' then
tmpStr:= '10';
randomize;
for i:= 1 to 2 do
tmpStr :=tmpstr + RNDINT[random(10)+1];
typeSend (tmpStr)
else
typeSend (AGE);Error: Found unexpected token "else", expected "End" at line 65Compiling failed.
I don't want to put an END; I want it to detect that it is an else after that. If this isn't an option I can switch the way it is called but I need a way to do the following
If (AGE) = an integer (ex. character creation screen, if they input ANY integer for their age it'll input it (this is a contsant) but if they leave it blank it'll give a random age)
then typeSend (AGE)