Good first try! I'll edit this post tomorrow morning. I have to go! Sorry! That's a very good first try at your first script. One thing, make sure to credit people for their functions and procedures.
IE:
SCAR Code:
function FindObjMultiText2(var cx, cy: Integer; Ut1, UT2, UT3: string; color,
tolerance: Integer): Boolean;
var
x, y, a, c, i, x1, y1, x2, y2: Integer;
begin
Color := Color;
if (FindColorTolerance(x, y, color, msx1, msy1, msx2, msy2, tolerance)) then
begin
x1 := 245;
y1 := 165;
x2 := 277;
y2 := 185;
repeat
if (not (Loggedin)) then
Break;
a := a + 1;
if (a = 1) or (a = 3) then
c := c + 1;
for i := 1 to c do
begin
if (a = 1) then
begin
x1 := x1 + 30;
x2 := x2 + 30;
end
else if (a = 2) then
begin
y1 := y1 - 20;
y2 := y2 - 20;
end
else if (a = 3) then
begin
x1 := x1 - 30;
x2 := x2 - 30;
end
else if (a = 4) then
begin
y1 := y1 + 20;
y2 := y2 + 20;
end;
if (x1 = 485) and (x2 = 517) then
x2 := x2 - 2;
if (y1 = 325) and (y2 = 345) then
y2 := y2 - 7;
if (x2 > 515) then
Break;
if (FindColorTolerance(x, y, Color, x1, y1, x2, y2, tolerance)) then
begin
MMouse(x, y, 0, 0)
Wait(10);
cx := x;
cy := y;
if (IsUpTextMulti(UT1, UT2, UT3)) then
begin
Result := True;
Break;
end;
end;
end;
if (a = 4) then
a := 0;
until (x2 > 515) or (Result = True);
end;
end;
Make sure to credit that. I'll tell you how to improve this tomorrow morning if I remember.
Here's a quick fix. Alright. You could add in this to the DeclarePlayers procedure.
Players[x].String1 := 'Oak';
They can enter which tree they will be using there, then, instead of using all those WillowTree, OakTree, etc..on the FindObjMultiText, you can just move the mouse to the tree color and look for the tree that the macroer filled in for String1.
IsUpText(Players[CurrentPlayer].String1);.
EG:
SCAR Code:
Procedure Tree;
begin
repeat
if(FindColorSpiral(x, y, Tree, MSX1, MSY1, MSX2, MSY2))then
begin
repeat
MMouse(x, y, 2, 2);
wait(500+random(300));
until(IsUpText(Players[CurrentPlayer].String1));
Mouse(x, y, 2, 2, true);
end;
FindRandoms;
AntiBanage;
FindHead;
FindEnt(TreeColor);
wait(10000+random(1000));
Until(invcount = 28);
drop;
End;
I did that really fast, and you may want to have someone check it over before you use it. Hope I helped! Good luck! You're on the right track.