View Full Version : How to make a loot procedure
Helper
01-09-2012, 03:40 AM
Hellow, i want to know how to make a procedure to loot gold charms.
:norris:
belbn
01-09-2012, 04:04 AM
procedure Loot;
begin
If(FindColorTolerance(x,y,COLOR,msx1,mxy1,msx2,msy 2,10)then
begin
mousebox(x,y,x,y,0);
if WaitUpText('Gold',RandomRange(150,250)) then
begin
clickmouse2(true);
end
end;
end;
Helper
01-09-2012, 09:44 PM
procedure Loot;
begin
If(FindColorTolerance(x,y,COLOR,msx1,mxy1,msx2,msy 2,10)then
begin
mousebox(x,y,x,y,0);
if WaitUpText('Gold',RandomRange(150,250)) then
begin
clickmouse2(true);
end
end;
end;
Thank you so much, i give you some reputation
cause
01-10-2012, 08:14 AM
Maybe an easier way is to use:
Function Loot: boolean; //Returns true if successful, false if not
var
x, y: integer;
if FindObjCustom(x, y, ['old'], 1234, 5) then //1234 is the color of the looted and old is Gold without the first letter
begin
Mouse(x, y, 1, 1, true);
wait(100 + random(250));
WriteLn('Found and clicked!');
Result := true;
end
else
begin
WriteLn('Didn''t find :(');
Result := false;
end;
Belbn's procedure won't work because he forgot his variables :P
Helper
01-11-2012, 12:51 AM
Maybe an easier way is to use:
Function Loot: boolean; //Returns true if successful, false if not
var
x, y: integer;
if FindObjCustom(x, y, ['old'], 1234, 5) then //1234 is the color of the looted and old is Gold without the first letter
begin
Mouse(x, y, 1, 1, true);
wait(100 + random(250));
WriteLn('Found and clicked!');
Result := true;
end
else
begin
WriteLn('Didn''t find :(');
Result := false;
end;
Belbn's procedure won't work because he forgot his variables :P
It worked, thank you so much :norris:
Powered by vBulletin® Version 4.2.1 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.