This is AHK script. Just copy n paste n enjoy
This script requires AcidRain's .bat file method of launching mods. Which has also bee updated now with a first option of "vanilla" to launch jk with no mods.
viewtopic.php?f=3&t=262368
SetKeyDelay 30, 30
SetControlDelay 0
SetTitleMatchMode, 3
mod = jke
gameName = omg game name
maxPlayers := 32
useScoreLimit := false
scoreLimit := 100
useTimeLimit := false
timeLimit := 1
useTeamPlay := false
useSingleLevelOnly := false
usePassword := true
password = haxor
maxJediRank := 8
z::
Run, C:Program Files (x86)LucasartsJedi Knightmod.bat, C:Program Files (x86)LucasartsJedi Knight
Sleep, 1000
IfWinActive, JK Launcher -:::-:::- by: AcidRain
{
Send, %mod%
Send, {ENTER}
Sleep, 2000
WinActivate, Jedi Knight - DevMode
}
else
{
MsgBox, Dont press shit
return
}
;Now select the player
CoordMode, Mouse, Relative
IfWinActive, Jedi Knight - DevMode
{
;click on the ok button
Sleep, 1000
MouseMove, 558, 468
Send, {LButton Down}
Send, {LButton Up}
;select multiplayer
Sleep, 500
MouseMove, 320, 273
Send, {LButton Down}
Send, {LButton Up}
;select host game
Sleep, 500
MouseMove, 463, 119
Send, {LButton Down}
Send, {LButton Up}
;select tcp/ip
Sleep, 500
MouseMove, 313, 244
Send, {LButton Down}
Send, {LButton Up}
;select ok button
Sleep, 500
MouseMove, 526, 471
Send, {LButton Down}
Send, {LButton Up}
;now select user defined game settings
;set game name
MouseMove, 280, 156
Send, {LButton Down}
Send, {LButton Up}
Loop, 16
{
Send, {BackSpace}
}
Send, %gameName%
;set max players
MouseMove, 278, 191
Send, {LButton Down}
Send, {LButton Up}
Loop, 2
{
Send, {BackSpace}
}
Send, %maxPlayers%
;using score limit?
PixelGetColor, color, 30, 233
if(color = 0x000000)
{
usingScoreLimit := true
} else {
usingScoreLimit := false
}
if(useScoreLimit == true && usingScoreLimit == false)
{
;turn on score limit
MouseMove, 30, 233
Send, {LButton Down}
Send, {LButton Up}
}
if(useScoreLimit == false && usingScoreLimit == true)
{
;turn off score limit
MouseMove, 30, 233
Send, {LButton Down}
Send, {LButton Up}
}
if(useScoreLimit == true)
{
;set the score limit
MouseMove, 280, 227
Send, {LButton Down}
Send, {LButton Up}
Loop, 4
{
Send, {BackSpace}
}
Send, %scoreLimit%
}
;using time limit?
PixelGetColor, color, 30, 268
if(color = 0x000000)
{
usingTimeLimit := true
} else {
usingTimeLimit := false
}
if(useTimeLimit == true && usingTimeLimit == false)
{
;turn on time limit
MouseMove, 30, 268
Send, {LButton Down}
Send, {LButton Up}
}
if(useTimeLimit == false && usingTimeLimit == true)
{
;turn off time limit
MouseMove, 30, 268
Send, {LButton Down}
Send, {LButton Up}
}
if(useTimeLimit == true)
{
;set the time limit
MouseMove, 280, 258
Send, {LButton Down}
Send, {LButton Up}
Loop, 4
{
Send, {BackSpace}
}
Send, %timeLimit%
}
;using team play?
PixelGetColor, color, 30, 303
if(color = 0x000000)
{
usingTeamPlay := true
} else {
usingTeamPlay := false
}
if(useTeamPlay == true && usingTeamPlay == false)
{
;turn on teamplay
MouseMove, 30, 303
Send, {LButton Down}
Send, {LButton Up}
}
if(useTeamPlay == false && usingTeamPlay == true)
{
;turn off team play
MouseMove, 30, 303
Send, {LButton Down}
Send, {LButton Up}
}
;using single-level only?
PixelGetColor, color, 30, 338
if(color = 0x000000)
{
usingSingleLevelOnly := true
} else {
usingSingleLevelOnly := false
}
if(useSingleLevelOnly == true && usingSingleLevelOnly == false)
{
;turn on SingleLevelOnly
MouseMove, 30, 338
Send, {LButton Down}
Send, {LButton Up}
}
if(useSingleLevelOnly == false && usingSingleLevelOnly == true)
{
;turn off SingleLevelOnly
MouseMove, 30, 338
Send, {LButton Down}
Send, {LButton Up}
}
;using password?
MouseMove, 282, 413
Send, {LButton Down}
Send, {LButton Up}
Loop, 16
{
Send, {BackSpace}
}
if(usePassword == true) {
Send, %password%
}
;set max jedi rank
MouseMove, 323, 155
Loop, 8
{
Send, {LButton Down}
Send, {LButton Up}
}
MouseMove, 354, 156
Loop, %maxJediRank%
{
Send, {LButton Down}
Send, {LButton Up}
}
}
else {
MsgBox, Dont press shit
}
Easily modified and turned into cmd line tool.
Topic starter
Posted : 07/04/2015 9:52 am
