Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@e0da
Last active July 12, 2021 06:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save e0da/40d551e1302738d931d0c61c163acb22 to your computer and use it in GitHub Desktop.
Save e0da/40d551e1302738d931d0c61c163acb22 to your computer and use it in GitHub Desktop.
Use the vertical scrolling for zoom and horizontal scrolling for rotation when playing SimCity 2000 (SIMCITY.EXE)
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
; https://gist.github.com/e0da/40d551e1302738d931d0c61c163acb22
#IfWinActive ahk_exe SIMCITY.EXE
WheelUp::Send {Home}
WheelDown::Send {End}
WheelLeft::
XButton1::
Send {Delete}
KeyWait WheelLeft
KeyWait XButton1
return
WheelRight::
XButton2::
Send {PgDn}
KeyWait WheelRight
KeyWait XButton2
return
#IfWinActive
@e0da
Copy link
Author

e0da commented Jul 12, 2021

Updated because

  1. Events were not being constrained to SIMCITY.EXE
  2. Wheel events worked yesterday, but not today? Use Wheel(Left|Right)+XButton(1|2)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment