Code: Select all
#singleinstance force
Process, Priority, , High
;Mouse Positions X/Y Coordinates, change them if needed.
X1=684 ; melee prayer
Y1=396 ; mouse position
X2=643 ; range prayer
y2=396 ; mouse position
x3=608 ; mage prayer
y3=396 ; mouse position
x4=681 ; steel skin
y4=359 ; mouse position
x5=570 ; item protect
y5=354 ; mouse position
x6=571 ; mystic might
y6=430 ; mouse position
x7=639 ; final Mouse Position
y7=237 ; after finishing prayer clicks
x8=641 ; Run icon
y8=480 ; mouse position
offset=4
F1Downs := "Melee"
F2Downs := "Range"
F3Downs := "Mage"
F4Downs := "Melees"
F5Downs := "Rangers"
F6Downs := "Magers"
goto ^g
return
^g:: ; Control+G to reopen GUI
Gui, Margin, 10, 10
Gui, Add, Text, center Ym+20 w280 h15, OSRS Prayer: By Samerdl
Gui, Add, Text, w50 h15 xm ym+60 section, F1 - key
Gui, Add, Text, w50 h15 yp+30, F2 - Key
Gui, Add, Text, w50 h15 yp+30, F3 - Key
Gui, Add, Text, w70 h15 xp+15 yp+30, F4 - Key
Gui, Add, Text, w70 h15 xp+65, F5 - Key
Gui, Add, Text, w70 h15 xp+65, F6 - Key
Gui, Add, Text, xp+55 yp+30 w300 h20, < Overheads Only
Gui, Add, Text, w50 h15 xs+60 ys, OverHead:
Gui, Add, Text, w50 h15 yp+30, OverHead:
Gui, Add, Text, w50 h15 yp+30, OverHead:
Gui, Add, DropDownList, w60 xs+120 ys-3 vF1Downs choose1, Melee|Range|Mage
Gui, Add, DropDownList, w60 yp+30 vF2Downs choose2, Melee|Range|Mage
Gui, Add, DropDownList, w60 yp+30 vF3Downs choose3, Melee|Range|Mage
Gui, Add, DropDownList, w60 xp-120 yp+60 vF4Downs choose1, Melees|Ranges|Magers
Gui, Add, DropDownList, w60 xp+70 vF5Downs choose2, Melees|Rangers|Magers
Gui, Add, DropDownList, w60 xp+70 vF6Downs choose3, Melees|Rangers|Magers
Gui, Add, Text, w50 ys-10 xs+200, Protections:
Gui, Add, CheckBox, yp+20 vSteelskins checked, Steel Skin
Gui, Add, CheckBox, yp+20 vItemProtects checked, Item Protect
Gui, Add, CheckBox, yp+20 vMysticMight, Mystic Might
Gui, Add, CheckBox, yp+20 vFRunning checked, ~ toggles run
Gui, Add, Text, xm ys+150 w300 h20 section center, Mouse Position When Done:
Gui, Add, Radio, w100 h15 ys+20 xm+30 vInv, Inventory Icon
Gui, Add, Radio, w100 h15 ys+20 xm+160 vOrigin checked, Original Position
Gui, Add, Button, w280 ys+50 xm, Ok
Gui, Add, Button, Xs YM w10, About
Gui, Show, w300, OSRS Prayer: By Samerdl
Return
GuiClose:
ExitApp
ButtonOK:
Gui, Submit
return
ButtonAbout:
MsgBox, 1,OSRS Prayer, This is a utility meant to speed up Prayer & Run activation and deactivation on Oldschool RS, click ok to learn about re-arranging mouse coordinates and to learn more about the output of the FKeys. DO NOT USE THIS PROGRAM ON A BROWSER (CHROME/Firefox/I.E/whatever) CLIENTS ONLY!
IfMsgBox Ok
MsgBox, 1,OSRS Prayer,Default coordinates are for the Orion client!, click Ok to continue.
IfMsgBox Ok
MsgBox, 1,OSRS Prayer, You can change the Coordinates for the Mouse clicks from the script file, simply right click your AHK file and select edit, use your Windows Spy utility from AutoHotKey to grab all the needed coordinates and replace them accordingly to each statement, Click Continue To learn about F1-F6 Keys.
IfMsgBox Ok
MsgBox, 1,OSRS Prayer,F1-F3 Keys will make use of Steel Skin, Item Protect & Mystic might once activated (All keys F1-F3 will) they are designed to perform as Full on Prayer Keys. F4-F6 will only acivavte the Overheads: Melee, Mage, Range - No protections prayers. Click Continue to learn about Run Toggle Key.
IfMsgBox Ok
MsgBox, 1,OSRS Prayer,Although the Gui shows the tilde (~) key is required for activation, you dont need to press shift to activate it - as the key bind is set to the backtick key (backquote, the tilde without shift I.E "`",`. Its just too hard to see it. Click Continue for an explaination regarding Mouse position when done.
IfMsgBox Ok
MsgBox, 1,OSRS Prayer, There are two options for the mouse position once the script finishes performing prayer/run toggles, it can eiher be the same position you've had it before, or it will move To X7/Y7 coords - the top of inventory close to the Inventory icon, you can change that within the script to any position you please. Click ok to learn about a secret command not in use - but existent in the script.
IfMsgBox Ok
MsgBox, 1,OSRS Prayer, Its not exactly so special, if you press your windows Key+F6 the script will perform a prayer activation, whats different about this once is that it has a random range of sleep time between each click, this is for all of you that are worried about banning/not too confident that you want it this fast, you can change it to whatever sleep time you want, and you can also change the mouse speed to whatever you wan, default is zero which is instant, sleep is in MS not Seconds. Click Ok for a closing remak - better usage of the utility.
IfMsgBox Ok
MsgBox, 1,OSRS Prayer, Be-very careful when you use this utility, obviously the first activation should work, but if yo run it 3-5 times in a row with no pause interval inbetween, you could mess up the clicks. Moreover - remember when you are binding and you have your bind cast ready the first click on overhead will not register: the script doesn't use mouse movements to switch to inventory tabs, it uses Fkeys (F5 for prayer F10 For Run toggle screen) To switch tabs, so be sure to have binds cancelled out when your about to pray, just click bind any where cancel it then trigger the prayer!. That is all. Remember DO NOT USE THIS PROGRAM ON A BROWSER (CHROME/Firefox/I.E/whatever) CLIENTS ONLY!
else
return
return
#If WinActive("Orion") or WinActive("Old School RuneScape") or WinActive("OSBot") or WinActive("Runescape") or WinActive("Tribot")
F1::
gosub %F1Downs%
return
F2::
gosub %F2Downs%
return
F3::
gosub %F3Downs%
return
F4::
gosub %F4Downs%
return
F5::
gosub %F5Downs%
return
F6::
gosub %F6Downs%
return
`::
if FRunning
{
MouseGetPos, XX, YY
send {f10}
;Random, Rand, 400, 600
;gsleep %rand%
MouseClick , Left , X8+ Ran(offset), Y8+ Ran(offset)
send {esc}
gosub MouseArea
}
return
Melees:
MouseGetPos, XX, YY
send {f5}
MouseClick , Left , X1+ Ran(offset), Y1+ Ran(offset)
send {esc}
gosub MouseArea
return
Rangers:
MouseGetPos, XX, YY
send {f5}
MouseClick , Left , X2+ Ran(offset), Y2+ Ran(offset)
send {esc}
gosub MouseArea
return
Magers:
MouseGetPos, XX, YY
send {f5}
MouseClick , Left , X3+ Ran(offset), Y3+ Ran(offset)
send {esc}
gosub MouseArea
return
Melee:
MouseGetPos, XX, YY
send {f5}
MouseClick , Left , X1+ Ran(offset), Y1+ Ran(offset)
gosub checkboxes
send {esc}
gosub MouseArea
return
Range:
MouseGetPos, XX, YY
send {f5}
MouseClick , Left , X2+ Ran(offset), Y2+ Ran(offset)
gosub checkboxes
send {esc}
gosub MouseArea
return
Mage:
MouseGetPos, XX, YY
send {f5}
MouseClick , Left , X3+ Ran(offset), Y3+ Ran(offset)
gosub checkboxes
send {esc}
gosub MouseArea
return
checkboxes:
if SteelSkins
{
MouseClick , Left , X4+ Ran(offset), Y4+ Ran(offset) ; steel skin
}
if ItemProtects
{
MouseClick , Left , X5+ Ran(offset), Y5+ Ran(offset) ; item prot
}
if MysticMight
{
MouseClick , Left , X6+ Ran(offset), Y6+ Ran(offset) ; mystic might
}
return
Mousearea:
if Inv
{
MouseMove, X7+ Ran(offset), Y7+ Ran(offset), 0
}
if Origin
{
MouseMove, XX+ Ran(offset), YY+ Ran(offset), 0
}
return
#F6::
send {f5}
Random, Rand, 25, 50
sleep %rand%
MouseClick , Left , X1+ Ran(offset), Y1+ Ran(offset)
Random, Rand, 25, 50
sleep %rand%
MouseClick , Left , X4+ Ran(offset), Y4+ Ran(offset)
Random, Rand, 25, 50
sleep %rand%
MouseClick , Left , X5+ Ran(offset), Y5+ Ran(offset)
Random, Rand, 25, 50
sleep %rand%
MouseClick , Left , X6+ Ran(offset), Y6+ Ran(offset)
send {esc}
MouseMove, X7+ Ran(offset), Y7+ Ran(offset), 0
return
Ran(Num)
{
Random, r, -1*Num, Num
Return r
}
Script, line 94 wrote:This is a utility meant to speed up Prayer & Run activation and deactivation on Oldschool RS