Jump to content

OK for fun


stampy
 Share

Recommended Posts

My daughter thought it would be more fun to have it work when the mouse wasn't over it... so I tried it. Sometimes being goofy is fun lol.

;original by:
;HackerZer0     
;post Oct 30 2006, 08:02 PM
;http://www.autoitscript.com/forum/index.php?showtopic=35443&hl=

;reworked by stampy for mouse over

$x = Run("notepad.exe")
ProcessWait($x)

$window = WinGetTitle('')
$window = WinGetHandle($window)

$magnitude = 1
WinWaitActive($window)
$startpos = WinGetPos($window)

Sleep(6000)

While 1
    $state = WinGetState("Untitled - Notepad", "")
    If $state = 0 Then 
        Exit
    Else
        $WinPos = WinGetPos($window)
        $mousepos = MouseGetPos()
        If $mousepos[0] > $WinPos[0] And $mousepos[0] < $WinPos[0]+$WinPos[2]And $mousepos[1] > $WinPos[1] And $mousepos[1] < $WinPos[1]+$WinPos[3] Then
            WinMove($window, "", $startpos[0], $startpos[1])
        Else
            $WinPos[0] = $WinPos[0] + Random($magnitude*-1, $magnitude, 1)
            $WinPos[1] = $WinPos[1] + Random($magnitude*-1, $magnitude, 1)
            WinMove($window, "", $WinPos[0], $WinPos[1])
        EndIf
    EndIf
WEnd
Link to comment
Share on other sites

lol this is varry cool... it will be a funny joke ill send to my little sister. its hacker ish....

instead of notepad why not just what ever window is active...

there should be a fun and jokes tab were people can put there funny little scripts

Edited by onedayillpay
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...