beesafree
2010-05-13 20:43:01
mmmm
this is for the facebook application "My Tribe"
it will check your island for crates, stardust, and moondust, a minimum of three times every 30 seconds
if it finds a crate it will take a screen shot of what you got and save it to a file you specify
it should be able to get out of all pop-ups with ease…
tell me if you find any errors, infinite loops, or bad coding in general
Updated: May 17, 2010 - fixed an error when finding crates and mixing it up with the "rain storm" event, also deleted some "writeln"'s
this is for the facebook application "My Tribe"
it will check your island for crates, stardust, and moondust, a minimum of three times every 30 seconds
if it finds a crate it will take a screen shot of what you got and save it to a file you specify
it should be able to get out of all pop-ups with ease…
program AutoCollector;
var
x,y,clicked1,clicked2,found,pic,redo,over,never,tempnum: integer;
screen: string;
const
ScreenSaveLocation = 'C:\Users\Owner\Documents\My Tribe\pic-';
begin
pic:= 0
over:= 0
redo:= 0
never:= 0
wait(3000)
repeat
if over = 1 then
begin
wait (1000 * 30);
over:= 0
end;
repeat
found:=0
if findcolor(x,y,6342833,0,0,8000,8000) = true then
begin
movemousesmoothex(x,y,3,4,10,10,1);
wait(300)
HoldMouse(x,y,true)
wait(50+random(100))
ReleaseMouse(x,y,true)
wait(3000)
end;
if findcolor(x,y,4636906,0,0,8000,8000) = true then //find star
begin
movemouse(x,y);
clickmouse(x,y,true);
found:= 1
movemouse(0,0);
wait(2000)
repeat
if findcolor(x,y,4771067,0,0,8000,8000) = true then
begin
movemouse(x,y);
clickmouse(x,y,true);
clicked1:= 1
end else
begin
tempnum:= tempnum + 1
if tempnum = 20 then
clicked1:= 1;
end;
until (clicked1 = 1)
tempnum:= 0
clicked1:= 0
end;
wait(100)
if findcolor(x,y,16777098,0,0,8000,8000) = true then //find moon
begin
movemouse(x,y);
clickmouse(x,y,true);
found:= 1
movemouse(0,0);
wait(2000)
repeat
if findcolor(x,y,14729065,0,0,8000,8000) = true then
begin
movemouse(x,y);
clickmouse(x,y,true);
clicked1:= 1
end else
begin
tempnum:= tempnum + 1
if tempnum = 20 then
clicked1:= 1;
end;
until (clicked1 = 1)
clicked1:= 0
tempnum:= 0
end;
wait(100)
if findcolor(x,y,6937843,0,0,8000,8000) = true then //find crate
begin
movemouse(x,y);
clickmouse(x,y,true);
movemouse(0,0);
wait (2000)
repeat
wait(10)
if findcolor(x,y,6679807,0,0,8000,8000) = true then
begin
movemouse(x,y);
clickmouse(x,y,true);
found:= 1
repeat
wait (900+random(100))
if findcolorTolerance(x,y,5606583,0,0,8000,8000,1) = true then
begin
clicked2:= clicked2 + 1
movemousesmoothex(x,y,3,4,10,10,1);
wait(300)
HoldMouse(x,y,true)
wait(50+random(100))
ReleaseMouse(x,y,true)
movemouse(x-200,y)
if clicked2 = 4 then
begin
wait(2000)
screen:= ScreenSaveLocation+inttostr(pic)+'.bmp'
SaveScreenshot(screen)
pic:= pic + 1
end;
end else;
begin
tempnum:= tempnum + 1
if tempnum = 20 then
clicked2:= 5;
end;
until(clicked2 = 5)
end else;
begin
tempnum:= tempnum + 1
if tempnum = 20 then
clicked2:= 5;
end;;
until (clicked2 = 5)
clicked2:= 0
clicked1:= 0
tempnum:= 0
end;
if found = 0 then
redo:= redo + 1;
if redo = 3 then
over:= 1;
if found = 0 then
begin
if findcolor(x,y,10592165,0,0,8000,8000) = true then
begin
movemousesmoothex(x,y,3,4,10,10,1);
wait(300)
HoldMouse(x,y,true)
wait(50+random(100))
ReleaseMouse(x,y,true)
end;
end;
movemouse(0,0)
wait(1000)
until (over = 1)
redo:= 0
until (never = 1);
end.tell me if you find any errors, infinite loops, or bad coding in general
Updated: May 17, 2010 - fixed an error when finding crates and mixing it up with the "rain storm" event, also deleted some "writeln"'s