Harry
2011-11-18 12:58:47
{*******************************************************************************
function FindPopup: Boolean;
by: Harry
Description: A simple functinds and closes the "please buy RS Members" popup
that happens when you reach lvl 10 in any skill.
*******************************************************************************}
function FindPopup: Boolean;
begin
Result := False;
if (GetColor(485, 40) = 2569093) then // Parts of red X, checked in two different spots to reduce false-positives
if (GetColor(488, 40) = 11189720) then
begin
Result := True;
TakeScreen('Found Popup');
AddToSRLLog('******** FOUND POPUP ********');
MouseBox(482, 35, 492, 44, 1); // Box around the X, to close it.
Wait(1000+Random(3000));
end;
end;Handles the dwarfen axe popup. Works great, tested it on a few accounts. The colors nor the position changes, and the mousebox is the outside border of the popup red X. I'm honestly surprised no one has made this yet. Also needs to also be added to FindNormalRandoms. :)