PDA

View Full Version : Flag problem ?



DaWu
12-10-2006, 02:53 PM
function KAttackMonsterM(Color1, Color2, Color3, Tolerance: Integer; MonsterName: String): Boolean;
var
i, x, y: Integer;
begin
FFlag(1);
for i:= 1 to 5 do
begin
if(FindColorTolerance(x, y, Color1, MSX1, MSY1, MSX2, MSY2, Tolerance + i))and
(FindColorTolerance(x, y, Color2, MSX1, MSY1, MSX2, MSY2, Tolerance + i))and
(FindColorTolerance(x, y, Color3, MSX1, MSY1, MSX2, MSY2, Tolerance + i))then
begin
MMouse(x, y, 3, 3);
wait(80 + random(60));
if(IsUpText('Attack '+MonsterName))then
begin
result:= true;
GetMousePos(x, y);
Mouse(x, y, 0, 0, true);
wait(40 + random(20));
FFlag(1);
OutFightO; //Waits Until Out Of Fight..
exit;
end;
end;
end;
end;

Theres a problem, there comes a flag on minimap, but sometimes it doesn't move into there ? How to Fix it ? There is the Kanesattack modified by me.
As you might have seen Im working hard on improving my script, and this thing is really a pain in my ass :/