Here's my script:
Code: Select all
;<=======================================================================================================>
;<=========================================== Game Launcher ===========================================>
;<=======================================================================================================>
#SingleInstance Force
#Persistent
#NoEnv
PID:=DllCall("GetCurrentProcessId") ;PID Of Script
Process, Priority, %PID%, Normal
SetControlDelay, -1
SetBatchLines, -1
SetWinDelay, -1
SetWorkingDir %A_ScriptDir%
;Menu, Tray, Icon, GameFloder.ico
SetWorkingDir, E:\Install Me\Auto Hot Key\My Auto Hotkey Scripts\Game Scripts
CoordMode, Mouse, Screen
C1:=Format("Aqua" Color)
C2:=Format("0xFFA500" Color) ;Orange
GUI, FONT, s15 c%C1% Bold
GUI, +LastFound -Caption +AlwaysOnTop +ToolWindow
GUI, Color, Blue
GUI, Show, H420 W220, SelectionMenu
WinSet, Transparent, 220, SelectionMenu
WinGetPos,,, WindowWidth, WindowHeight
MouseGetPos, x, y
x:=(x-WindowWidth//2),y:=(y-WindowHeight//4+90)
WinMove, x, y
Gui, Add, Text, y+1 w200 vText1 gSelectionMenu, Borderlands 2
Gui, Add, Text, y+1 w200 vText2 gSelectionMenu, Broforce
Gui, Add, Text, y+1 w200 vText3 gSelectionMenu, Code Vein
Gui, Add, Text, y+1 w200 vText4 gSelectionMenu, DBZ Kakarot
Gui, Add, Text, y+1 w200 vText5 gSelectionMenu, Destiny Warriors
Gui, Add, Text, y+1 w200 vText6 gSelectionMenu, Evoland
Gui, Add, Text, y+1 w200 vText7 gSelectionMenu, Middle Earth
Gui, Add, Text, y+1 w200 vText8 gSelectionMenu, Never Alone
Gui, Add, Text, y+1 w200 vText9 gSelectionMenu, Nine Parchments
Gui, Add, Text, y+1 w200 vText10 gSelectionMenu, Rocket League
Gui, Add, Text, y+1 w200 vText11 gSelectionMenu, SMITE
Gui, Add, Text, y+1 w200 vText12 gSelectionMenu, Sonic Racing
Gui, Add, Text, y+1 w200 vText13 gSelectionMenu, The Witcher 2
Gui, Add, Text, y+1 w200 vText14 gSelectionMenu, Who's That Flying?!
Gui, Add, Text, y+1 w200 vText15 gSelectionMenu, Worms W M D
Gui, Add, Text, y+1 w200 vText16 gSelectionMenu, ZSNES
WinWaitActive, SelectionMenu
SetTimer, Blinker, 100
~Esc::ExitApp
Return
;<=========================================== Selection Menu ===========================================>
SelectionMenu:
{ MouseGetPos,,,, Ctrl
If (MouseOver (Ctrl="Static1"))
{ Run, "steam://rungameid/49520" ;Borderlands 2
} If (MouseOver (Ctrl="Static2"))
{ Run, "steam://rungameid/274190" ;Broforce
} If (MouseOver (Ctrl="Static3"))
{ Run, "steam://rungameid/678960" ;Code Vein
} If (MouseOver (Ctrl="Static4"))
{Run, "DBZ Kakarot\DBZ Kakarot.ahk" ;DBZ Kakarot
} If (MouseOver (Ctrl="Static5"))
{ Run, "steam://rungameid/399790" ;Destiny Warriors
} If (MouseOver (Ctrl="Static6"))
{ Run, "steam://rungameid/233470" ;Evoland
} If (MouseOver (Ctrl="Static7"))
{ Run, "steam://rungameid/241930" ;Middle Earth
} If (MouseOver (Ctrl="Static8"))
{ Run, "steam://rungameid/295790" ;Never Alone
} If (MouseOver (Ctrl="Static9"))
{ Run, "steam://rungameid/471550" ;Nine Parchments
} If (MouseOver (Ctrl="Static10"))
{ Run, "steam://rungameid/252950" ;Rocket League
} If (MouseOver (Ctrl="Static11"))
{ Run, "SMITE\SMITE.ahk" ;SMITE
} If (MouseOver (Ctrl="Static12"))
{ Run, "steam://rungameid/212480" ;Sonic Racing
} If (MouseOver (Ctrl="Static13"))
{ Run, "steam://rungameid/20920" ;The Witcher 2
} If (MouseOver (Ctrl="Static14"))
{ Run, "steam://rungameid/57700" ;Who's That Flying?!
} If (MouseOver (Ctrl="Static15"))
{ Run, "steam://rungameid/327030" ;Worms W M D
} If (MouseOver (Ctrl="Static16"))
{ Run, "ZSNES\ZSNES.ahk" ;ZSNES EMU
} } ExitApp
;<============================================= Animations ============================================>
Blinker:
{ If !(WinActive("SelectionMenu"))
{ ExitApp
}
If (a||b||c||d||e||f||g||h||i||j||k||l||m||n||o||p||q||r||s||t||u||v||w||z) ;Don't use C1, C2, X, Y
{ DllCall("SetCursor","UInt",DllCall("LoadCursor", Uint, 0, Int, 32649)) ;Chang Mouse Pointer.
}
MouseGetPos,,,, Ctrl
If (MouseOver (Ctrl="Static1") AND !(a)) ;Borderlands 2
{ a:=!a
Gui, Font, s15
GuiControl, Font, Static1
GuiControl, +c%C2% +Redraw, Text1
} Else, If (MouseOver (Ctrl="Static1") AND (a))
{ GuiControl, +c%C1% +Redraw, Text1
a:=!a
If (a1)
a1:=!a1
} Else, If !(a1) ;Anti Text Flicker
{ a1:=!a1
Gui, Font, s12
GuiControl, Font, Static1
} If (MouseOver (Ctrl="Static2") AND !(b)) ;Broforce
{ b:=!b
Gui, Font, s15
GuiControl, Font, Static2
GuiControl, +c%C2% +Redraw, Text2
} Else, If (b)
{ GuiControl, +c%C1% +Redraw, Text2
b:=!b
If (b1)
b1:=!b1
} Else, If !(b1)
{ b1:=!b1
Gui, Font, s12
GuiControl, Font, Static2
} If (MouseOver (Ctrl="Static3") AND (!c)) ;Code Vein
{ c:=!c
Gui, Font, s15
GuiControl, Font, Static3
GuiControl, +c%C2% +Redraw, Text3
} Else, If (c)
{ GuiControl, +c%C1% +Redraw, Text3
c:=!c
If (3c)
3c:=!3c
} Else, If !(3c)
{ 3c:=!3c
Gui, Font, s12
GuiControl, Font, Static3
} If (MouseOver (Ctrl="Static4") AND (!d)) ;DBZ Kakarot
{ d:=!d
Gui, Font, s15
GuiControl, Font, Static4
GuiControl, +c%C2% +Redraw, Text4
} Else, If (d)
{ GuiControl, +c%C1% +Redraw, Text4
d:=!d
If (d1)
d1:=!d1
} Else, If !(d1)
{ d1:=!d1
Gui, Font, s12
GuiControl, Font, Static4
} If (MouseOver (Ctrl="Static5") AND (!e)) ;Destiny Warriors
{ e:=!e
Gui, Font, s15
GuiControl, Font, Static5
GuiControl, +c%C2% +Redraw, Text5
} Else, If (e)
{ GuiControl, +c%C1% +Redraw, Text5
e:=!e
If (e1)
e1:=!e1
} Else, If !(e1)
{ e1:=!e1
Gui, Font, s12
GuiControl, Font, Static5
} If (MouseOver (Ctrl="Static6") AND (!f)) ;Evoland
{ f:=!f
Gui, Font, s15
GuiControl, Font, Static6
GuiControl, +c%C2% +Redraw, Text6
} Else, If (f)
{ GuiControl, +c%C1% +Redraw, Text6
f:=!f
If (f1)
f1:=!f1
} Else, If !(f1)
{ f1:=!f1
Gui, Font, s12
GuiControl, Font, Static6
} If (MouseOver (Ctrl="Static7") AND (!g)) ;Middle Earth
{ g:=!g
Gui, Font, s15
GuiControl, Font, Static7
GuiControl, +c%C2% +Redraw, Text7
} Else, If (g)
{ GuiControl, +c%C1% +Redraw, Text7
g:=!g
If (g1)
g1:=!g1
} Else, If !(g1)
{ g1:=!g1
Gui, Font, s12
GuiControl, Font, Static7
} If (MouseOver (Ctrl="Static8") AND (!h)) ;Never Alone
{ h:=!h
Gui, Font, s15
GuiControl, Font, Static8
GuiControl, +c%C2% +Redraw, Text8
} Else, If (h)
{ GuiControl, +c%C1% +Redraw, Text8
h:=!h
If (h1)
h1:=!h1
} Else, If !(h1)
{ h1:=!h1
Gui, Font, s12
GuiControl, Font, Static8
} If (MouseOver (Ctrl="Static9") AND (!i)) ;Nine Parchments
{ i:=!i
Gui, Font, s15
GuiControl, Font, Static9
GuiControl, +c%C2% +Redraw, Text9
} Else, If (i)
{ GuiControl, +c%C1% +Redraw, Text9
i:=!i
If (i1)
i1:=!i1
} Else, If !(i1)
{ i1:=!i1
Gui, Font, s12
GuiControl, Font, Static9
} If (MouseOver (Ctrl="Static10") AND (!j)) ;Rocket League
{ j:=!j
Gui, Font, s15
GuiControl, Font, Static10
GuiControl, +c%C2% +Redraw, Text10
} Else, If (j)
{ GuiControl, +c%C1% +Redraw, Text10
j:=!j
If (j1)
j1:=!j1
} Else, If !(j1)
{ j1:=!j1
Gui, Font, s12
GuiControl, Font, Static10
} If (MouseOver (Ctrl="Static11") AND (!k)) ;SMITE
{ k:=!k
Gui, Font, s15
GuiControl, Font, Static11
GuiControl, +c%C2% +Redraw, Text11
} Else, If (k)
{ GuiControl, +c%C1% +Redraw, Text11
k:=!k
If (k1)
k1:=!k1
} Else, If !(k1)
{ k1:=!k1
Gui, Font, s12
GuiControl, Font, Static11
} If (MouseOver (Ctrl="Static12") AND (!l)) ;Sonic Racing
{ Gui, Font, s15
GuiControl, Font, Static12
l:=!l
GuiControl, +c%C2% +Redraw, Text12
} Else, If (l)
{ GuiControl, +c%C1% +Redraw, Text12
l:=!l
If (l1)
l1:=!l1
} Else, If !(l1)
{ l1:=!l1
Gui, Font, s12
GuiControl, Font, Static12
} If (MouseOver (Ctrl="Static13") AND (!m)) ;The Witcher 2
{ m:=!m
Gui, Font, s15
GuiControl, Font, Static13
GuiControl, +c%C2% +Redraw, Text13
} Else, If (m)
{ GuiControl, +c%C1% +Redraw, Text13
m:=!m
If (m1)
m1:=!m1
} Else, If !(m1)
{ m1:=!m1
Gui, Font, s12
GuiControl, Font, Static13
} If (MouseOver (Ctrl="Static14") AND (!n)) ;Who's That Flying?!
{ n:=!n
Gui, Font, s15
GuiControl, Font, Static14
GuiControl, +c%C2% +Redraw, Text14
} Else, If (n)
{ GuiControl, +c%C1% +Redraw, Text14
n:=!n
If (n1)
n1:=!n1
} Else, If !(n1)
{ n1:=!n1
Gui, Font, s12
GuiControl, Font, Static14
} If (MouseOver (Ctrl="Static15") AND (!o)) ;Worms W M D
{ o:=!o
Gui, Font, s15
GuiControl, Font, Static15
GuiControl, +c%C2% +Redraw, Text15
} Else, If (o)
{ GuiControl, +c%C1% +Redraw, Text15
o:=!o
If (o1)
o1:=!o1
} Else, If !(o1)
{ o1:=!o1
Gui, Font, s12
GuiControl, Font, Static15
} If (MouseOver (Ctrl="Static16") AND (!p)) ;ZSNES EMU
{ p:=!p
Gui, Font, s15
GuiControl, Font, Static16
GuiControl, +c%C2% +Redraw, Text16
} Else, If (p)
{ GuiControl, +c%C1% +Redraw, Text16
p:=!p
If (p1)
p1:=!p1
} Else, If !(p1)
{ p1:=!p1
Gui, Font, s12
GuiControl, Font, Static16
} } Return
;<=======================================================================================================>
;<=============================================== E N D ===============================================>
;<=======================================================================================================>