Hey, basically I've been making this script for cutting a magic tree on my private server so i can make a detection system... I have successfully made the script work and have ran it for about 3 hours without fail but when I ran it over night, i must of suffered from some lag and because i do all my teleporting and banking by co-ordinated and wait's to be the same every time, my character has ran off into an area and sits there "waiting for tree...". This tree isn't in this area and never will be so i wanted to add a limit to how many times my script can actually loop before it goes to a fial safe and teleports away.
Heres my waiting script:
I was trying to add something like this:Simba Code://Theres obviously more up here, secret ;)
until not(FindColorSpiralTolerance(x, y, TreeColour, TreeX1, TreeY1, TreeX2, TreeY2, TreeColourTolerance))
or not(FindColorSpiralTolerance (x, y, 3029313, 702, 418, 710, 428, 20))
writeln('Waiting for tree');
wait(3000);
until not(FindColorSpiralTolerance(x, y, 3029313, 702, 418, 710, 428, 20));
Writeln('Full inventory, Going to bank.');
end;
Simba Code:var
I :Integer; //this is declared earlierSimba Code://Theres obviously more up here, secret ;)
until not(FindColorSpiralTolerance(x, y, TreeColour, TreeX1, TreeY1, TreeX2, TreeY2, TreeColourTolerance))
or not(FindColorSpiralTolerance (x, y, 3029313, 702, 418, 710, 428, 20))
WriteLn('waited ' + IntToStr(I) + ' Times.'); //tells you how many times you have waited
Inc(I);
wait(3000);
until not(FindColorSpiralTolerance(x, y, 3029313, 702, 418, 710, 428, 20)); //until inventory is full
or until(I = 6); //or until you have waited 6 times
Writeln('Full inventory, Going to bank.');
end;
but I get:
I also treid:Code:[Error] C:\Users\Taylor\Desktop\Working Magic Tree Bot.simba(36:8): Identifier expected at line 35 Compiling failed.
then i getSimba Code://Theres obviously more up here, secret ;)
until not(FindColorSpiralTolerance(x, y, TreeColour, TreeX1, TreeY1, TreeX2, TreeY2, TreeColourTolerance))
or not(FindColorSpiralTolerance (x, y, 3029313, 702, 418, 710, 428, 20))
WriteLn('waited ' + IntToStr(I) + ' Times.');
Inc(I);
wait(3000);
until not(FindColorSpiralTolerance(x, y, 3029313, 702, 418, 710, 428, 20)) //took out the semi-colon thing
or until(I = 6);
Writeln('Full inventory, Going to bank.');
end;
any suggestions?Code:[Error] C:\Users\Taylor\Desktop\Working Magic Tree Bot.simba(36:11): Syntax error at line 35 Compiling failed.


Reply With Quote





!! thank you very much 
