Macro

This page contains help on making simple and powerful macro system in NetHack.

Installation
This was tested on: WinXP SP3 ^m::run macro.bat @echo off taskkill /IM "autohotkey.exe" /FI "STATUS ne RUNNING" cls echo.Add new NetHack 3.4.3 macro set /p key=Input macro trigger key: if (%key%)== start macro.ahk if (%key%)== exit set /p macro=Input macro action: find /v "%key%::" < macro.ahk > macro.ah0 copy macro.ah0 macro.ahk del macro.ah0 echo %key%::send %macro% >> macro.ahk start macro.ahk It's used to run script file first then start NetHack and finally close AutoHotkey. @echo off start macro.ahk nethackw.exe taskkill /IM "autohotkey.exe" /FI "STATUS ne RUNNING" Set WshShell = CreateObject("WScript.Shell") WshShell.Run chr(34) & "run.bat" & Chr(34), 0 Set WshShell = Nothing
 * Download AutoHotkey Basic installer http://www.autohotkey.com/download/
 * Install AutoHotkey Basic
 * Create macro.ahk AutoHotkey script in your NetHack directory that contains following code:
 * Create macro.bat batch file in your NetHack directory that contains following code:
 * Create run.bat batch file in your NetHack directory that contains following code:
 * If you don't want to see black command window while running run.bat simply create a VBS script named NetHackW.vbs that contains code below: