Jump to content

Desktop Game


Recommended Posts

#include <Misc.au3>

HotKeySet("{F1}", "terminate")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

SplashImageOn("", "C:\Documents and Settings\Owner\My Documents\My Pictures\desktop.JPG", 1023, 769, 0, 0, 1)
If _IsPressed("01") Then
$Pos0 = MouseGetPos()
$wherepic = GUICtrlCreatePic("C:\Documents and Settings\Owner\My Documents\My Pictures\bullet hole.bmp", $Pos0[0], $Pos0[1]) 
GUICtrlSetData($Pos0[0], MouseGetPos(0))
GUICtrlSetData($Pos0[1], MouseGetPos(1))
EndIf
sleep(2147483647)
SplashOff()
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

Func terminate()
SplashOff()
Exit 0
EndFunc

this is a program that is supposed to make a picture of my desktop appear and whenever I click make a bullet hole appear in the desktop picture. Problem is that whenever Iclick nothing happens. Any ideas?

The below statement is False.The above statement is True.a lesson I learned from Greenmachine; give a man a code and he'll solve one problem. Teach a man to code and he'll solve all his problems.P.S please don't use autoIt as a virus creator/spyware maker(keyLogger especially)Cick this and help me[center]My Scripts:[/center][center]Port Scanner[/center]

Link to comment
Share on other sites

Okay this is what I have now.

#include <Misc.au3>

HotKeySet("{F1}", "terminate")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

SplashImageOn("", "C:\Documents and Settings\Owner\My Documents\My Pictures\desktop.JPG", 1023, 769, 0, 0, 1)
If _IsPressed("01") Then
while 1
$Pos0 = MouseGetPos()
$wherepic = GUICtrlCreatePic("C:\Documents and Settings\Owner\My Documents\My Pictures\bullet hole.bmp", $Pos0[0], $Pos0[1]) 
GUICtrlSetData($Pos0[0], MouseGetPos(0))
GUICtrlSetData($Pos0[1], MouseGetPos(1))
WEnd
EndIf
sleep(2147483647)
SplashOff()
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

Func terminate()
SplashOff()
Exit 0
EndFunc

But for some reason it is not working. Why?

Edited by Infinitex0

The below statement is False.The above statement is True.a lesson I learned from Greenmachine; give a man a code and he'll solve one problem. Teach a man to code and he'll solve all his problems.P.S please don't use autoIt as a virus creator/spyware maker(keyLogger especially)Cick this and help me[center]My Scripts:[/center][center]Port Scanner[/center]

Link to comment
Share on other sites

Okay this is what I have now

#include <Misc.au3>

HotKeySet("{F1}", "terminate")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

SplashImageOn("", "C:\Documents and Settings\Owner\My Documents\My Pictures\desktop.JPG", 1023, 769, 0, 0, 1)
While 1
If _IsPressed("01") Then
$Pos0 = MouseGetPos()
$wherepic = GUICtrlCreatePic("C:\Documents and Settings\Owner\My Documents\My Pictures\bullet hole.bmp", $Pos0[0], $Pos0[1]) 
GUICtrlSetData($Pos0[0], MouseGetPos(0))
GUICtrlSetData($Pos0[1], MouseGetPos(1))
EndIf
WEnd
sleep(2147483647)
SplashOff()
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

Func terminate()
SplashOff()
Exit 0
EndFunc

but it still doesn't work. Any ideas?

The below statement is False.The above statement is True.a lesson I learned from Greenmachine; give a man a code and he'll solve one problem. Teach a man to code and he'll solve all his problems.P.S please don't use autoIt as a virus creator/spyware maker(keyLogger especially)Cick this and help me[center]My Scripts:[/center][center]Port Scanner[/center]

Link to comment
Share on other sites

I see, in that case what's that funtion used to set an image as a backround?

(I'm realy out of it)

Edited by Infinitex0

The below statement is False.The above statement is True.a lesson I learned from Greenmachine; give a man a code and he'll solve one problem. Teach a man to code and he'll solve all his problems.P.S please don't use autoIt as a virus creator/spyware maker(keyLogger especially)Cick this and help me[center]My Scripts:[/center][center]Port Scanner[/center]

Link to comment
Share on other sites

this is what I did

#include <Misc.au3>

HotKeySet("{F1}", "terminate")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
While 1
If _IsPressed("01") Then
$Pos0 = MouseGetPos()
;GUICreate("My GUI picture",350,300,-1,-1)
SplashImageOn ( "", @ScriptDir & "\test.bmp", 48, 48,$Pos0[0], $Pos0[1], 1  )
;$wherepic = GUICtrlCreatePic(@ScriptDir & "\test.bmp", $Pos0[0], $Pos0[1])
GUISetState ()

GUICtrlSetData($Pos0[0], MouseGetPos(0))
GUICtrlSetData($Pos0[1], MouseGetPos(1))
EndIf
sleep(100)
WEnd
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

Func terminate()
SplashOff()
Exit 0
EndFunc

[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Link to comment
Share on other sites

@zerocool

that works but you should change it to

GUICtrlSetData($Pos0[0] - 24, MouseGetPos(0))
GUICtrlSetData($Pos0[1] - 24, MouseGetPos(1))
to centre it
My Programs:AInstall - Create a standalone installer for your programUnit Converter - Converts Length, Area, Volume, Weight, Temperature and Pressure to different unitsBinary Clock - Hours, minutes and seconds have 10 columns each to display timeAutoIt Editor - Code Editor with Syntax Highlighting.Laserix Editor & Player - Create, Edit and Play Laserix LevelsLyric Syncer - Create and use Synchronised Lyrics.Connect 4 - 2 Player Connect 4 Game (Local or Online!, Formatted Chat!!)MD5, SHA-1, SHA-256, Tiger and Whirlpool Hash Finder - Dictionary and Brute Force FindCool Text Client - Create Rendered ImageMy UDF's:GUI Enhance - Enhance your GUIs visually.IDEA File Encryption - Encrypt and decrypt files easily! File Rename - Rename files easilyRC4 Text Encryption - Encrypt text using the RC4 AlgorithmPrime Number - Check if a number is primeString Remove - remove lots of strings at onceProgress Bar - made easySound UDF - Play, Pause, Resume, Seek and Stop.
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...