blother
2012-03-25 18:23:25
Procedure ClickPieDish;
var
Dish, x, y: Integer;
begin
Dish := DTMFromString('m6wAAAHic42ZgYHBhZGAIAOIgIPYDYjcgtoBieyAOBGIfILYG4udA/BBKvwfij0D8BogfQ9mvgfgeVC7LXw9oOhNRmIsBP+CCYhEgZiQBIwEAuggOYg==');
If FindDTM(Dish, x, y, MSX1, MSY1, MSX2, MSY2) Then
begin
WriteLn('Found pie dish.');
MMouse(x, y, 5, 5);
If IsUpText('ish') Then
begin
WriteLn('Clicking Pie Dish');
Mouse(x, y, 0, 0, True);
end;
end;
FreeDTM(Dish);
end; It moves the mouse to the pie dish, but it won't click on it. I changed the first MMouse to Mouse and it worked, but it does not work if i check for uptext then click on it.