Advertisement
Guest User

Ark Scripts

a guest
Feb 14th, 2016
470
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.13 KB | None | 0 0
  1. ; This Script was made by Kenneth "Modernkennnern" Hoff. It is still a W.I.P
  2. ; This Script is
  3.  
  4.  
  5. ; ------------ Changing Variables via GUI -----------
  6. F2::
  7.  
  8. InputBox, NumberOfUses, How Many Items Are In A Stack?,
  9. (
  10. Raw Meat = 20 / Cooked Meat = 30 / Berries = 100
  11.  
  12. This can always be changed with F2
  13. ), , , , ,
  14. MsgBox You set current stack amount to: %NumberOfUses%.
  15. FileDelete, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  16. FileAppend, %NumberOfUses%, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  17. Return
  18.  
  19.  
  20. ; ------------ Remote Using X amounts of Food -----------
  21. F3::
  22.  
  23. FileRead, NumberOfUses, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  24. IfNotExist, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  25. {
  26. MsgBox, 1,, There is no stacksize set, do you want to set it? [This can always be changed with "F2"]
  27. IfMsgBox OK
  28. {
  29. FileDelete, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  30. InputBox, NumberOfUses, How Many Items Are In A Stack?,
  31. (
  32. Raw Meat = 20 / Cooked Meat = 30 / Berries = 100
  33.  
  34. This can always be changed with F2
  35. )
  36.  
  37. , , , , ,
  38.  
  39. FileAppend, %NumberOfUses%, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  40. MsgBox, Stacksize is now %NumberofUses%
  41. }
  42. IfMsgBox Cancel
  43. {
  44. MsgBox, Cannot continue without a Stacksize.
  45. }
  46. }
  47.  
  48. While GetKeyState("F3","P")
  49. {
  50. MouseGetPos, RemotePosX1, RemotePosY1 ; Stores the position of your Cursor.
  51.  
  52. Click %RemotePosX%, %RemotePosY% ; Position of your Cursor.
  53. Click 1100, 765, %NumberOfUses% ; Remote use Button X times (where X = Variable you choose with F2 )
  54.  
  55. MouseMove, %RemotePosX1%, %RemotePosY1% ; Position of your Cursor.
  56. }
  57.  
  58. Return
  59.  
  60.  
  61. ; ------------ Splitting stacks into ones. --------------
  62. F4::
  63.  
  64. While GetKeyState("F4","P")
  65. {
  66. SendInput {Ctrl Down}
  67. MouseGetPos, StackPosX, StackPosY
  68. MouseClickDrag, left, 0, 0, -35, 0, 2, R
  69. ;Sleep, 20
  70. SendInput {Ctrl Up}
  71. MouseMove, %StackPosX%, %StackPosY%
  72. }
  73. Return
  74.  
  75.  
  76. ; ------------ Checking Current Stack Amount. ------------
  77. F5::
  78.  
  79. MsgBox You set current stack amount to: %NumberOfUses%
  80.  
  81.  
  82. ; ------------ GUI ---------------------------------------
  83. F6::
  84. FileRead, NumberOfUses, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  85.  
  86. Gui, Add, Button, x15 y50 w100 gStacksize, Stacksize: %NumberOfUses%
  87. Gui, Add, Button, x+20 w225 gRemoteUse, Location of "Remote Use Item" Button. [NYI]
  88. Gui, Font, s11 cRed, Verdana
  89. Gui, Add, Text, x25 y15, Which Variable to change?
  90. Gui, Show, Center, Variables
  91.  
  92. Return
  93.  
  94. Stacksize:
  95.  
  96. InputBox, NumberOfUses, How Many Items Are In A Stack?,
  97. (
  98. Raw Meat = 20 / Cooked Meat = 30 / Berries = 100
  99.  
  100. This can always be changed with F2
  101. ), , , , ,
  102. MsgBox You set current stack amount to: %NumberOfUses%.
  103. FileDelete, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  104. FileAppend, %NumberOfUses%, %A_WorkingDir%\Stored Variables\(Ark)ScriptVariables.txt
  105.  
  106. Return
  107.  
  108. RemoteUse:
  109. Msgbox, This is not yet implemented :(
  110. Return
  111.  
  112. GuiClose:
  113. Reload
  114. Return
  115.  
  116.  
  117. ; ------------ Additional Macros ---------------------------------------
  118.  
  119. Pause::reload
  120. ^Pause::reload
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement