xtrapsp
2012-11-14 05:02:59
Hey guys,
I don't know if this is right or not, wrote it SUPER quickly as I'm fixing my Squeal of Fortune Script.
Thanks
I don't know if this is right or not, wrote it SUPER quickly as I'm fixing my Squeal of Fortune Script.
(*
ExitSquealOfFortunePage
~~~~~~~~~~~~~~~~~~~
.. code-block:: pascal
function ExitSquealOfFortunePage(): boolean;
Finds and exits the SquealOfFortune Page. Based on Coh3n & Ashaman88s snippet.
.. note::
Author: Coh3n & Ashaman88
Last Modified: July 28th, 2012 by Xtrapsp
Example:
.. code-block:: pascal
ExitSquealOfFortunePage();
*)
function ExitSquealOfFortunePage(): boolean;
var
w, h, x, y, xs, ys, xe, ye,SquealDTM: integer;
begin
if (SRL_ExitedSquealOfFortunepage) then
exit;
SquealCloseDTM := DTMFromString('mbQAAAHicY2VgYFjHwsCwCYhXAfFGKB0BFA+F4mgo/nfSgyFAR4AhwsONYXWDFoMlIyMDNsCIBYMBAAEWCk0=');
SquealCloseDTMHighlight := DTMFromString('mWAAAAHicY2FgYFjPxMCwCopB7CVAsZUMCPrfvyQgjgLi2Qz/DjkwoANGNAwCAB47Dqg=');
getClientDimensions(w, h);
// This DTM is the X in the top right. The Static for this is Mouse(754, 38-50,0,0,true);
if (findDTM(SquealCloseDTM,x,y,xs,ys,xe,ye)) then
begin
mouse(x, y, 1, 2, mouse_Move);
if (findDTM(SquealCloseDTMHighlight,x,y,xs,ys,xe,ye)) then
begin
mouse(x, y, 0, 0, mouse_Left);
result := true;
SRL_ExitedSquealOfFortunepage := true;
end;
end;
end;
FreeDTM(SquealCloseDTM);
FreeDTM(SquealCloseDTMHighlight);
end; Thanks