Advertisement
Guest User

Untitled

a guest
Oct 19th, 2016
316
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 13.30 KB | None | 0 0
  1. ; <COMPILER: v1.1.24.01>
  2. #SingleInstance, Force
  3. #Persistent
  4. #NoEnv
  5. #Warn
  6. SendMode, Input
  7. SetWorkingDir, %A_ScriptDir%
  8. Application := {Name: "OverJoint 1920x1080", Version: "9.0"}
  9. Window := {Width: 600, Height: 400, Title: Application.Name}
  10. Navigation := {Label: ["Aim Key", "Aim Settings", "Aim Speed", "FoV Range", "Pause Settings", "---", "Help", "---"]}
  11. Box_Init(C="FF0000") {
  12. Gui, 96: -Caption +ToolWindow +E0x20
  13. Gui, 96: Color, % C
  14. Gui, 97: -Caption +ToolWindow +E0x20
  15. Gui, 97: Color, % C
  16. Gui, 98: -Caption +ToolWindow +E0x20
  17. Gui, 98: Color, % C
  18. Gui, 99: -Caption +ToolWindow +E0x20
  19. Gui, 99: Color, % C
  20. }
  21. Box_Draw(X, Y, W, H, T="1", O="I") {
  22. If(W < 0)
  23. X += W, W *= -1
  24. If(H < 0)
  25. Y += H, H *= -1
  26. If(T >= 2)
  27. {
  28. If(O == "O")
  29. X -= T, Y -= T, W += T, H += T
  30. If(O == "C")
  31. X -= T / 2, Y -= T / 2
  32. If(O == "I")
  33. W -= T, H -= T
  34. }
  35. Gui, 96: Show, % "x" X " y" Y " w" W " h" T " NA", Horizontal 1
  36. Gui, 96:+AlwaysOnTop
  37. Gui, 98: Show, % "x" X " y" Y + H " w" W " h" T " NA", Horizontal 2
  38. Gui, 98:+AlwaysOnTop
  39. Gui, 97: Show, % "x" X " y" Y " w" T " h" H " NA", Vertical 1
  40. Gui, 97:+AlwaysOnTop
  41. Gui, 99: Show, % "x" X + W " y" Y " w" T " h" H " NA", Vertical 2
  42. Gui, 99:+AlwaysOnTop
  43. }
  44. Box_Destroy() {
  45. Loop, 4
  46. Gui, % A_Index + 95 ": Destroy"
  47. }
  48. Box_Hide() {
  49. Loop, 4
  50. Gui, % A_Index + 95 ": Hide"
  51. }
  52. Box_Init_Target(C="FF0000") {
  53. Gui, 90: -Caption +ToolWindow +E0x20
  54. Gui, 90: Color, % C
  55. Gui, 91: -Caption +ToolWindow +E0x20
  56. Gui, 91: Color, % C
  57. Gui, 92: -Caption +ToolWindow +E0x20
  58. Gui, 92: Color, % C
  59. Gui, 93: -Caption +ToolWindow +E0x20
  60. Gui, 93: Color, % C
  61. }
  62. Box_Draw_Target(X, Y, W, H, T="1", O="I") {
  63. If(W < 0)
  64. X += W, W *= -1
  65. If(H < 0)
  66. Y += H, H *= -1
  67. If(T >= 2)
  68. {
  69. If(O == "O")
  70. X -= T, Y -= T, W += T, H += T
  71. If(O == "C")
  72. X -= T / 2, Y -= T / 2
  73. If(O == "I")
  74. W -= T, H -= T
  75. }
  76. Gui, 90: Show, % "x" X " y" Y " w" W " h" T " NA", Horizontal 1
  77. Gui, 90:+AlwaysOnTop
  78. Gui, 92: Show, % "x" X " y" Y + H " w" W " h" T " NA", Horizontal 2
  79. Gui, 92:+AlwaysOnTop
  80. Gui, 91: Show, % "x" X " y" Y " w" T " h" H " NA", Vertical 1
  81. Gui, 91:+AlwaysOnTop
  82. Gui, 93: Show, % "x" X + W " y" Y " w" T " h" H " NA", Vertical 2
  83. Gui, 93:+AlwaysOnTop
  84. }
  85. Box_Destroy_Target() {
  86. Loop, 4
  87. Gui, % A_Index + 89 ": Destroy"
  88. }
  89. Box_Hide_Target() {
  90. Loop, 4
  91. Gui, % A_Index + 89 ": Hide"
  92. }
  93. Box_Show_Target() {
  94. Loop, 4
  95. Gui, % A_Index + 89 ": Show"
  96. }
  97. inicount := 9
  98. fileread,settings,settings.ini
  99. stringsplit,settings,settings,`n
  100. if !(fileexist("settings.ini")) || (settings0-3 != inicount){
  101. iniread,sen_Short,settings.ini,settings,senShort, 5
  102. iniread,sen_Long,settings.ini,settings,senLong, 3
  103. iniread,Fov_X,settings.ini,settings,FovX, 4.5
  104. iniread,Fov_Y,settings.ini,settings,FovY, 3
  105. iniread,AimShort_X,settings.ini,settings,AimShortX, 58
  106. iniread,AimShort_Y,settings.ini,settings,AimShortY, 85
  107. iniread,AimLong_X,settings.ini,settings,AimLongX, 40
  108. iniread,AimLong_Y,settings.ini,settings,AimLongY, 70
  109. }
  110. Menu, Tray, Icon, Shell32.dll, 175
  111. Menu, Tray, Tip, % Application.Name
  112. Menu, Tray, NoStandard
  113. Gui, +LastFound -Resize +HwndhGui1
  114. Gui, Color, FFFFFF
  115. Gui, Add, Tab2, % " x" -999999 " y" -999999 " w" 0 " h" 0 " -Wrap +Theme vTabControl", % ""
  116. Gui, Tab
  117. Gui, Add, Picture, % "x" -999999 " y" -999999 " w" 4 " h" 32 " vpMenuHover +0x4E +HWNDhMenuHover",
  118. Gui, Add, Picture, % "x" 0 " y" 18 " w" 4 " h" 32 " vpMenuSelect +0x4E +HWNDhMenuSelect",
  119. Gui, Font, s9 c808080, Segoe UI
  120. Loop, % Navigation.Label.Length() {
  121. GuiControl,, TabControl, % Navigation.Label[A_Index] "|"
  122. If (Navigation.Label[A_Index] = "---") {
  123. Continue
  124. }
  125. Gui, Add, Text, % "x" 18 " y" (32*A_Index)-14 " h" 32 " +0x200 gMenuClick vMenuItem" . A_Index, % Navigation.Label[A_Index]
  126. Gui, Add, Text, x18 y280 w150, [F1] To Start
  127. Gui, Add, Text, x18 y300 h150, [F2] To Reload
  128. }
  129. Gui, Font
  130. Gui, Font, s11 c000000, Segoe UI
  131. Gui, Add, Text, % "x" 192 " y" 18 " w" (Window.Width-192)-14 " h" 32 " +0x200 vPageTitle", % ""
  132. Gui, Font
  133. Gui, Add, Picture, % "x" 192 " y" 50 " w" (Window.Width-192)-14 " h" 1 " +0x4E +HWNDhDividerLine",
  134. Gui, Tab, 1
  135. Gui, Add, Checkbox, x192 y60 w150 vaimtype, Left Mouse Button
  136. Gui, Add, Checkbox, x192 y80 w150 vaimtype1, Right Mouse Button
  137. Gui, Add, Checkbox, x192 y100 w150 vaimtype3, Mouse Button 4
  138. Gui, Add, Checkbox, x192 y120 w150 vaimtype4, Mouse Button 5
  139. Gui, Add, Checkbox, x192 y140 w150 vaimtype5, Middle Mouse Button
  140. Gui, Add, ActiveX, x192 y200 w308 h110, mshtml:<img src='http://overjoint.com/styles/pbtech/theme/images/logoui.png' />
  141. Gui, Tab, 2
  142. Gui, Add, Text, % "x" 192 " y" 66 " w" (Window.Width-192)-14, % "Short Range -"
  143. Gui, Add, Text, % "x" 272 " y" 66 " w" (Window.Width-192)-14, % "X:"
  144. Gui, Add, Edit, x292 y61 w30 vxa, % AimShort_X
  145. Gui, Add, Text, % "x" 342 " y" 66 " w" (Window.Width-192)-14, % "Y:"
  146. Gui, Add, Edit, x362 y61 w30 vxy, % AimShort_Y
  147. Gui, Add, Text, % "x" 192 " y" 106 " w" (Window.Width-192)-14, % "Long Range -"
  148. Gui, Add, Text, % "x" 272 " y" 106 " w" (Window.Width-192)-14, % "X:"
  149. Gui, Add, Edit, x292 y101 w30 vxxa, % AimLong_X
  150. Gui, Add, Text, % "x" 342 " y" 106 " w" (Window.Width-192)-14, % "Y:"
  151. Gui, Add, Edit, x362 y101 w30 vxxy, % AimLong_Y
  152. Gui, Add, ActiveX, x192 y200 w308 h110, mshtml:<img src='http://overjoint.com/styles/pbtech/theme/images/logoui.png' />
  153. Gui, Tab, 3
  154. Gui, Add, Text, % "x" 192 " y" 66 " w" (Window.Width-192)-14, % "Short Range Speed -"
  155. Gui, Add, Edit, x302 y61 w30 vrx, % sen_Short
  156. Gui, Add, Text, % "x" 192 " y" 106 " w" (Window.Width-192)-14, % "Long Range Speed -"
  157. Gui, Add, Edit, x302 y101 w30 vrxl, % sen_Long
  158. Gui, Add, ActiveX, x192 y200 w308 h110, mshtml:<img src='http://overjoint.com/styles/pbtech/theme/images/logoui.png' />
  159. Gui, Tab, 4
  160. Gui, Add, Text, % "x" 192 " y" 66 " w" (Window.Width-192)-14, % "X - Axis :"
  161. Gui, Add, Edit, x302 y61 w30 vxrange, % Fov_X
  162. Gui, Add, Text, % "x" 192 " y" 106 " w" (Window.Width-192)-14, % "Y - Axis :"
  163. Gui, Add, Edit, x302 y101 w30 vyrange, % Fov_Y
  164. Gui, Add, Text, % "x" 192 " y" 150 " w" (Window.Width-192)-14, % "Lower the Number Larger the FoV"
  165. Gui, Add, Checkbox, x250 y180 w150 voverlayActive, FoV Overlay
  166. Gui, Add, ActiveX, x192 y200 w308 h110, mshtml:<img src='http://overjoint.com/styles/pbtech/theme/images/logoui.png' />
  167. Gui, Tab, 5
  168. Gui, Add, Text, % "x" 192 " y" 66 " w" (Window.Width-192)-14, % "Here you can select your own Pause key,"
  169. Gui, Add, Text, % "x" 192 " y" 86 " w" (Window.Width-192)-14, % "Please Note: You have to use a Key combo"
  170. Gui, Add, Text, % "x" 192 " y" 106 " w" (Window.Width-192)-14, % "For Example: ALT+A"
  171. Gui, Add, Hotkey, x192 y135 w45 h20 vHK gPauseKey,
  172. Gui, Show,,Dynamic Hotkeys
  173. Gui, Add, ActiveX, x192 y200 w308 h110, mshtml:<img src='http://overjoint.com/styles/pbtech/theme/images/logoui.png' />
  174. Gui, Tab, 6
  175. Gui, Tab, 7
  176. Gui, Add, Link, x192 y66, Need help? `n`nPlease visit the <a href="http://www.overjoint.com/faq.html">Hack FAQ Page</a>, `n`nIf your problem is not solved by the Hack FAQ `nplease post on <a href="http://overjoint.com/forum"> These Forums</a>
  177. Gui, Add, ActiveX, x192 y200 w308 h110, mshtml:<img src='http://overjoint.com/styles/pbtech/theme/images/logoui.png' />
  178. Gui, Tab, 8
  179. Gui, Show, % " w" Window.Width " h" Window.Height, % Window.Title
  180. GoSub, OnLoad
  181. return
  182. OnLoad:
  183. SetPixelColor("fcc87b", hMenuHover)
  184. SetPixelColor("f9a01b", hMenuSelect)
  185. SetPixelColor("D8D8D8", hDividerLine)
  186. SelectMenu("MenuItem1")
  187. OnMessage(0x200, "WM_MOUSEMOVE")
  188. return
  189. MenuClick:
  190. SelectMenu(A_GuiControl)
  191. return
  192. SelectMenu(Control) {
  193. Global
  194. CurrentMenu := Control
  195. Loop, % Navigation.Label.Length() {
  196. SetControlColor("808080", Navigation.Label[A_Index])
  197. }
  198. SetControlColor("000000", Control)
  199. GuiControl, Move, pMenuSelect, % "x" 0 " y" (32*SubStr(Control, 9, 2))-14 " w" 4 " h" 32
  200. GuiControl, Choose, TabControl, % SubStr(Control, 9, 2)
  201. GuiControl,, PageTitle, % Navigation.Label[SubStr(Control, 9, 2)]
  202. }
  203. WM_MOUSEMOVE(wParam, lParam, Msg, Hwnd) {
  204. Global
  205. If (InStr(A_GuiControl, "MenuItem") = true && A_GuiControl != CurrentMenu) {
  206. GuiControl, Move, pMenuHover, % "x" 0 " y" (32*SubStr(A_GuiControl, 9, 2))-14 " w" 4 " h" 32
  207. } Else If (InStr(A_GuiControl, "MenuItem") = false || A_GuiControl = CurrentMenu) {
  208. GuiControl, Move, pMenuHover, % "x" -999999 " y" -999999 " w" 4 " h" 32
  209. }
  210. }
  211. SetControlColor(Color, Control) {
  212. Global
  213. GuiControl, % "+c" Color, % Control
  214. GuiControlGet, ControlText,, % Control
  215. GuiControlGet, ControlHandle, Hwnd, % Control
  216. DllCall("SetWindowText", "Ptr", ControlHandle, "Str", ControlText)
  217. }
  218. SetPixelColor(Color, Handle) {
  219. VarSetCapacity(BMBITS, 4, 0), Numput("0x" . Color, &BMBITS, 0, "UInt")
  220. hBM := DllCall("Gdi32.dll\CreateBitmap", Int, 1, Int, 1, UInt, 1, UInt, 24, Ptr, 0)
  221. hBM := DllCall("User32.dll\CopyImage", Ptr, hBM, UInt, 0, Int, 0, Int, 0, UInt, 0x2008)
  222. DllCall("Gdi32.dll\SetBitmapBits", Ptr, hBM, UInt, 3, Ptr, &BMBITS)
  223. return DllCall("User32.dll\SendMessage", Ptr, Handle, UInt, 0x172, Ptr, 0, Ptr, hBM)
  224. }
  225. F1::
  226. #Persistent
  227. #KeyHistory, 0
  228. #NoEnv
  229. #HotKeyInterval 1
  230. #MaxHotkeysPerInterval 127
  231. #InstallKeybdHook
  232. #UseHook
  233. #SingleInstance, Force
  234. SetKeyDelay,-1, 8
  235. SetControlDelay, -1
  236. SetMouseDelay, 0
  237. SetWinDelay,-1
  238. SendMode, InputThenPlay
  239. SetBatchLines,-1
  240. ListLines, Off
  241. CoordMode, Mouse, client
  242. PID := DllCall("GetCurrentProcessId")
  243. Process, Priority, %PID%, Normal
  244. ZeroX := 960
  245. ZeroY := 540
  246. CFovX := 80
  247. CFovY := 200
  248. ScanL := 660
  249. ScanR := 1250
  250. ScanT := 280
  251. ScanB := 610
  252. GuiControlget, rX
  253. GuiControlget, xa
  254. GuiControlget, ya
  255. GuiControlget, xrange
  256. GuiControlget, yrange
  257. Loop, {
  258. Gui,Submit, Nohide
  259. if (aimtype=1)
  260. {
  261. GetKeyState, Mouse2, LButton, P
  262. GoSub MouseMoves2
  263. }
  264. if (aimtype1=1)
  265. {
  266. GetKeyState, Mouse2, RButton, P
  267. GoSub MouseMoves2
  268. }
  269. if (aimtype3=1)
  270. {
  271. GetKeyState, Mouse2, XButton1, P
  272. GoSub MouseMoves2
  273. }
  274. if (aimtype4=1)
  275. {
  276. GetKeyState, Mouse2, XButton2, P
  277. GoSub MouseMoves2
  278. }
  279. if (aimtype5=1)
  280. {
  281. GetKeyState, Mouse2, MButton, P
  282. GoSub MouseMoves2
  283. }
  284. imageSearch, AimPixelX, AimPixelY, 0 + (A_Screenwidth * (xrange/10)), 0 + (A_Screenheight * (yrange/10)), A_Screenwidth - (A_Screenwidth * (xrange/10)), A_Screenheight - (A_Screenheight * (yrange / 10)), *4 hhp2.bmp
  285. GoSub GetAimOffset1
  286. GoSub GetAimMoves1
  287. if(ErrorLevel = 1){
  288. imageSearch, AimPixelX, AimPixelY, 0 + (A_Screenwidth * (xrange/10)), 0 + (A_Screenheight * (yrange/10)), A_Screenwidth - (A_Screenwidth * (xrange/10)), A_Screenheight - (A_Screenheight * (yrange / 10)), *4 hhp.bmp
  289. GoSub GetAimOffset2
  290. GoSub GetAimMoves1
  291. }
  292. Box_Init("FF0000")
  293. X := 0 + (A_Screenwidth * (xrange/10))
  294. Y := 0 + (A_Screenheight * (yrange/10))
  295. W := (A_Screenwidth - (A_Screenwidth * (xrange/10))) - X
  296. H := (A_Screenheight - (A_Screenheight * (yrange / 10))) -Y
  297. Box_Draw(X, Y , W, H)
  298. if(AimPixelX != "" && AimPixelY != ""){
  299. Box_Init_Target("00ff00")
  300. Box_Draw_Target(AimPixelX-5, AimPixelY -10, 155, 20)
  301. }
  302. if(overlayActive=0){
  303. Box_Hide()
  304. Box_Hide_Target()
  305. }
  306. }
  307. MouseMoves2:
  308. If ( Mouse2 == "D" ) {
  309. DllCall("mouse_event", uint, 1, int, MoveX, int, MoveY, uint, 0, int, 0)
  310. }
  311. Return
  312. MouseMoves11:
  313. If ( Mouse2 == "U" ) {
  314. DllCall("mouse_event", uint, 1, int, MoveX, int, MoveY, uint, 0, int, 0)
  315. }
  316. GetAimOffset1:
  317. Gui,Submit, Nohide
  318. AimX := AimPixelX - ZeroX +xa
  319. AimY := AimPixelY - ZeroY +xy
  320. If ( AimX+5 > 0) {
  321. DirX := rx / 10
  322. }
  323. If ( AimX+5 < 0) {
  324. DirX := (-rx) / 10
  325. }
  326. If ( AimY+2 > 0 ) {
  327. DirY := rX /10 *0.5
  328. }
  329. If ( AimY+2 < 0 ) {
  330. DirY := (-rx) /10 *0.5
  331. }
  332. AimOffsetX := AimX * DirX
  333. AimOffsetY := AimY * DirY
  334. Return
  335. GetAimOffset2:
  336. Gui,Submit, Nohide
  337. AimX := AimPixelX - ZeroX +xxa
  338. AimY := AimPixelY - ZeroY +xxy
  339. If ( AimX+5 > 0) {
  340. DirX := rxl / 10
  341. }
  342. If ( AimX+5 < 0) {
  343. DirX := (-rxl) / 10
  344. }
  345. If ( AimY+2 > 0 ) {
  346. DirY := rxl /10 *0.5
  347. }
  348. If ( AimY+2 < 0 ) {
  349. DirY := (-rxl) /10 *0.5
  350. }
  351. AimOffsetX := AimX * DirX
  352. AimOffsetY := AimY * DirY
  353. Return
  354. GetAimMoves1:
  355. RootX := Ceil(( AimOffsetX ** ( 1 )))
  356. RootY := Ceil(( AimOffsetY ** ( 1 )))
  357. MoveX := RootX * DirX
  358. MoveY := RootY * DirY
  359. Return
  360. reload:
  361. SleepF1:
  362. SleepDuration = 1
  363. TimePeriod = 1
  364. DllCall("Winmm\timeBeginPeriod", uint, TimePeriod)
  365. Iterations = 1
  366. StartTime := A_TickCount
  367. Loop, %Iterations% {
  368. DllCall("Sleep", UInt, TimePeriod)
  369. }
  370. DllCall("Winmm\timeEndPeriod", UInt, TimePeriod)
  371. Return
  372. DebugTool1:
  373. MouseGetPos, MX, MY
  374. ToolTip, %AimOffsetX% | %AimOffsetY%
  375. ToolTip, %AimX% | %AimY%
  376. ToolTip, %IntAimX% | %IntAimY%
  377. ToolTip, %RootX% | %RootY%
  378. ToolTip, %MoveX% | %MoveY% || %MX% %MY%
  379. Return
  380. PauseKey:
  381. If HK in +,^,!,+^,+!,^!,+^!
  382. return
  383. Gui, Submit, NoHide
  384. If StrLen(HK) = 1
  385. HK := "~" HK
  386. Hotkey, %HK%, NewPauseKey, On
  387. savedHK := HK
  388. return
  389. NewPauseKey:
  390. pause,toggle,1
  391. {
  392. if(A_IsPaused=0)
  393. {
  394. Gui, Add, Text, % "x" (Window.Width-170)-10 " y" (Window.Height-24)-10 " w" 80 " h" 24, % "Hack Running"
  395. Soundbeep
  396. }
  397. if(A_IsPaused=0)
  398. {
  399. Gui, Add, Text, % "x" (Window.Width-170)-10 " y" (Window.Height-24)-10 " w" 80 " h" 24, % "Hack Running"
  400. Soundbeep
  401. }
  402. }
  403. if(A_IsPaused=1)
  404. {
  405. Gui, Add, Text, % "x" (Window.Width-170)-10 " y" (Window.Height-24)-10 " w" 80 " h" 24, % "Hack Paused"
  406. Soundbeep
  407. }
  408. if(A_IsPaused=1)
  409. {
  410. Gui, Add, Text, % "x" (Window.Width-170)-10 " y" (Window.Height-24)-10 " w" 80 " h" 24, % "Hack Paused"
  411. Soundbeep
  412. }
  413. return
  414. F2::
  415. Reload
  416. GuiClose:
  417. gui,submit
  418. iniwrite,%rx%,settings.ini,settings,senShort
  419. iniwrite,%rxl%,settings.ini,settings,senLong
  420. iniwrite,%xrange%,settings.ini,settings,FovX
  421. iniwrite,%yrange%,settings.ini,settings,FovY
  422. iniwrite,%xa%,settings.ini,settings,AimShortX
  423. iniwrite,%xy%,settings.ini,settings,AimShortY
  424. iniwrite,%xxa%,settings.ini,settings,AimLongX
  425. iniwrite,%xxy%,settings.ini,settings,AimLongY
  426. ExitApp
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement