今天研究了一下AutoHotKey工具,发现个人懒病真是愈来愈严重了,如今玩war3打电脑居然连几个秘籍都不想花精力输入了。我写了一个脚本,具有如下两个功能:工具
利用热字符串(Hotstring)简化秘籍的输入,好比在输入框中输入radar,AutoHostKey会自动将其转换为“iseedeadpeople”
spa
利用热键(Hotkey)在开局阶段快速输入指定的一组秘籍,包括:增长资源、无敌、地图全开、魔法无限、人口无限、快速建造code
我用的AutoHotKey版本为1.1.23.05,脚本文件 war3cheat.ahk 代码以下:游戏
; 快速输入魔兽争霸III秘籍 ; Tsybius2014 2016/04/23 ; 魔兽争霸III秘籍(混乱之治 & 冰封王座) resx = greedisgood 1000000 ;加1000000单位金钱和木材 money = keysersoze 1000000 ;加1000000单位金钱 wood = leafittome 1000000 ;加1000000单位木材 power = whosyourdaddy ;神话模式 radar = iseedeadpeople ;地图全开 magic = thereisnospoon ;法力无限 food = pointbreak ;人口无限(最高100) fast = warpten ;快速建造 win = allyourbasearebelongtous ;快速胜利 lose = somebodysetupusthebomb ;快速失败 #IfWinActive Warcraft III ; 常规缩写 ::resx::greedisgood 1000000 ::money::keysersoze 1000000 ::wood::leafittome 1000000 ::power::whosyourdaddy ::radar::iseedeadpeople ::magic::thereisnospoon ::food::pointbreak ::fast::warpten ::win::allyourbasearebelongtous ::lose::somebodysetupusthebomb ; 组合输入 - 开局适用 ^t:: Send, {enter}%resx%{space}{enter} Send, {enter}%power%{space}{enter} Send, {enter}%radar%{space}{enter} Send, {enter}%magic%{space}{enter} Send, {enter}%food%{space}{enter} Send, {enter}%fast%{space}{enter} Return #IfWinActive
双击此脚本运行便可,这些热键与热字符串只会在魔兽争霸III(war3)程序中起做用。资源
脚本既可用于混乱之治,也可用于冰封王座。但只能用于“单人模式”中的“自定义游戏”中。字符串
下图为游戏开始时按下Ctrl+T后连续输入6个秘籍的效果图:
string
ENDit