DHM - Idle Again

Automate most of DHM features

当前为 2023-09-17 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name DHM - Idle Again
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.0
  5. // @description Automate most of DHM features
  6. // @author Felipe Dounford
  7. // @require https://code.jquery.com/jquery-3.6.0.min.js
  8. // @require https://code.jquery.com/ui/1.12.1/jquery-ui.js
  9. // @match https://dhm.idle-pixel.com/
  10. // @icon https://www.google.com/s2/favicons?sz=64&domain=greasyfork.org
  11. // @grant none
  12. // @license MIT
  13. // ==/UserScript==
  14.  
  15. (function() {
  16. 'use strict';
  17. $("head").append('<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script><script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script><link rel="stylesheet" href="https://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css" type="text/css">');
  18. //Toggles
  19. window.toggleGlobal = JSON.parse(localStorage.getItem('toggleGlobal')) || true
  20. window.toggleGeodeOpen = JSON.parse(localStorage.getItem('toggleGeodeOpen')) || false
  21. window.toggleMineralIdentify = JSON.parse(localStorage.getItem('toggleMineralIdentify')) || false
  22. window.toggleNecklaceCharge = JSON.parse(localStorage.getItem('toggleNecklaceCharge')) || false
  23. window.toggleTrain = JSON.parse(localStorage.getItem('toggleTrain')) || false
  24. window.toggleSmelting = JSON.parse(localStorage.getItem('toggleSmelting')) || true
  25. window.toggleRefinary = JSON.parse(localStorage.getItem('toggleRefinary')) || false
  26. window.toggleCharcoal = JSON.parse(localStorage.getItem('toggleCharcoal')) || false
  27. window.toggleWoodcutting = JSON.parse(localStorage.getItem('toggleWoodcutting')) || true
  28. window.toggleFarming = JSON.parse(localStorage.getItem('toggleFarming')) || false//
  29. window.toggleBones = JSON.parse(localStorage.getItem('toggleBones')) || false
  30. window.toggleDrink = JSON.parse(localStorage.getItem('toggleDrink')) || false//
  31. window.toggleBrew = JSON.parse(localStorage.getItem('toggleBrew')) || false//
  32. window.toggleExplore = JSON.parse(localStorage.getItem('toggleExplore')) || false
  33. window.toggleFight = JSON.parse(localStorage.getItem('toggleFight')) || false
  34. window.toggleCousin = JSON.parse(localStorage.getItem('toggleCousin')) || false
  35. window.toggleStatue = JSON.parse(localStorage.getItem('toggleStatue')) || false
  36. window.toggleArtifact = JSON.parse(localStorage.getItem('toggleArtifact')) || false
  37. window.toggleBoat = JSON.parse(localStorage.getItem('toggleBoat')) || true
  38. //Crafting Vars
  39. window.scriptSmeltingOre = JSON.parse(localStorage.getItem('scriptSmeltingOre')) || 'copper'
  40. window.scriptRefinaryBar = JSON.parse(localStorage.getItem('scriptRefinaryBar')) || 'gold'
  41. window.scriptFoundryWood = JSON.parse(localStorage.getItem('scriptFoundryWood')) || 'cheapest'
  42. //Woodicutting Vars
  43. window.scriptTreeIgnore = {tree:JSON.parse(localStorage.getItem('scriptTreeIgnore.tree'))||false,oakTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.oakTree'))||false,willowTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.willowTree'))||false,mapleTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.mapleTree'))||false,redwoodTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.redwoodTree'))||false,pineTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.pineTree'))||false,hauntedTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.hauntedTree'))||false,jungleTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.jungleTree'))||true,lavaTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.lavaTree'))||false,goldTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.goldTree'))||true,magicTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.magicTree'))||false,appleTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.appleTree'))||false,cactusTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.cactusTree'))||false,bananaTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.bananaTree'))||false,palmTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.palmTree'))||false,pineappleTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.pineappleTree'))||true,starfruitTree:JSON.parse(localStorage.getItem('scriptTreeIgnore.starfruitTree'))||false,none:true}
  44. //Farming Vars
  45. window.scriptBonesIgnore = {bones:JSON.parse(localStorage.getItem('scriptBonesIgnore.bones'))||true,ashes:JSON.parse(localStorage.getItem('scriptBonesIgnore.ashes'))||false,iceBones:JSON.parse(localStorage.getItem('scriptBonesIgnore.iceBones'))||true,zombieBones:JSON.parse(localStorage.getItem('scriptBonesIgnore.zombieBones'))||true,bloodBones:JSON.parse(localStorage.getItem('scriptBonesIgnore.bloodBones'))||true,fishBones:JSON.parse(localStorage.getItem('scriptBonesIgnore.fishBones'))||true}
  46. //Exploring Vars
  47. window.scriptAreaEnergy = {fields:50,forests:250,caves:1000,volcano:5000,northernFields:8000,hauntedMansion:20000,desert:50000,ocean:120000,jungle:200000,dungeonEntrance:500000,dungeon:1000000,castle:3000000,cemetery:7000000,factory:10000000,hauntedWoods:14000000,deepOcean:20000000}
  48. window.scriptArea = JSON.parse(localStorage.getItem('scriptArea')) || 'fields'
  49. window.scriptCousinArea = JSON.parse(localStorage.getItem('scriptCousinArea')) || 'fields'
  50. //Cooking Vars
  51. window.scriptBoatSend = {rowBoat:JSON.parse(localStorage.getItem('scriptBoatSend.rowBoat'))||true,canoeBoat:JSON.parse(localStorage.getItem('scriptBoatSend.canoeBoat'))||true,sailBoat:JSON.parse(localStorage.getItem('scriptBoatSend.sailBoat'))||true,highWind:JSON.parse(localStorage.getItem('scriptBoatSend.highWind'))||true,steamBoat:JSON.parse(localStorage.getItem('scriptBoatSend.steamBoat'))||true,trawler:JSON.parse(localStorage.getItem('scriptBoatSend.trawler'))||true}
  52. const oldHideAllTabs = hideAllTabs
  53.  
  54. function autoGeodeOpen() {
  55. if (geode1 > 0) {
  56. sendBytes('OPEN_MULTIPLE_GEODE=geode1~'+geode1)
  57. closeSmittysDialogue('dialogue-confirm')
  58. } else if (geode2 > 0) {
  59. sendBytes('OPEN_MULTIPLE_GEODE=geode2~'+geode2)
  60. closeSmittysDialogue('dialogue-confirm')
  61. } else if (geode3 > 0) {
  62. sendBytes('OPEN_MULTIPLE_GEODE=geode3~'+geode3)
  63. closeSmittysDialogue('dialogue-confirm')
  64. } else if (geode4 > 0) {
  65. sendBytes('OPEN_MULTIPLE_GEODE=geode4~'+geode4)
  66. closeSmittysDialogue('dialogue-confirm')
  67. } else if (geode5 > 0) {
  68. sendBytes('OPEN_MULTIPLE_GEODE=geode5~'+geode5)
  69. closeSmittysDialogue('dialogue-confirm')
  70. } else if (geode6 > 0) {
  71. sendBytes('OPEN_MULTIPLE_GEODE=geode6~'+geode6)
  72. closeSmittysDialogue('dialogue-confirm')
  73. }
  74. }
  75.  
  76. function autoIdentify() {
  77. if (limeQuartzMineralUnidentified > 0) {
  78. clicksItem('limeQuartzMineralUnidentified');
  79. closeSmittysDialogue('dialogue-confirm');
  80. } else if (fluoriteMineralUnidentified > 0) {
  81. clicksItem('fluoriteMineralUnidentified');
  82. closeSmittysDialogue('dialogue-confirm');
  83. } else if (topazMineralUnidentified > 0) {
  84. clicksItem('topazMineralUnidentified');
  85. closeSmittysDialogue('dialogue-confirm');
  86. } else if (blueMarbleMineralUnidentified > 0) {
  87. clicksItem('blueMarbleMineralUnidentified');
  88. closeSmittysDialogue('dialogue-confirm');
  89. } else if (sulferMineralUnidentified > 0) {
  90. clicksItem('sulferMineralUnidentified');
  91. closeSmittysDialogue('dialogue-confirm');
  92. } else if (purpleQuartzMineralUnidentified > 0) {
  93. clicksItem('purpleQuartzMineralUnidentified');
  94. closeSmittysDialogue('dialogue-confirm');
  95. } else if (limoniteMineralUnidentified > 0) {
  96. clicksItem('limoniteMineralUnidentified');
  97. closeSmittysDialogue('dialogue-confirm');
  98. } else if (crystalPrismeMineralUnidentified > 0) {
  99. clicksItem('crystalPrismeMineralUnidentified');
  100. closeSmittysDialogue('dialogue-confirm');
  101. } else if (typeof clearMarbleMineralUnidentified !== 'undefined' && clearMarbleMineralUnidentified > 0) {
  102. clicksItem('clearMarbleMineralUnidentified');
  103. closeSmittysDialogue('dialogue-confirm');
  104. } else if (denseMarbleMineralUnidentified > 0) {
  105. clicksItem('denseMarbleMineralUnidentified');
  106. closeSmittysDialogue('dialogue-confirm');
  107. } else if (jadeMineralUnidentified > 0) {
  108. clicksItem('jadeMineralUnidentified');
  109. closeSmittysDialogue('dialogue-confirm');
  110. } else if (opalMineralUnidentified > 0) {
  111. clicksItem('opalMineralUnidentified');
  112. closeSmittysDialogue('dialogue-confirm');
  113. } else if (amethystMineralUnidentified > 0) {
  114. clicksItem('amethystMineralUnidentified');
  115. closeSmittysDialogue('dialogue-confirm');
  116. } else if (tashmarineMineralUnidentified > 0) {
  117. clicksItem('tashmarineMineralUnidentified');
  118. closeSmittysDialogue('dialogue-confirm');
  119. } else if (tanzaniteMineralUnidentified > 0) {
  120. clicksItem('tanzaniteMineralUnidentified');
  121. closeSmittysDialogue('dialogue-confirm');
  122. } else if (seaCrystalMineralUnidentified > 0) {
  123. clicksItem('seaCrystalMineralUnidentified');
  124. closeSmittysDialogue('dialogue-confirm');
  125. } else if (amberMineralUnidentified > 0) {
  126. clicksItem('amberMineralUnidentified');
  127. closeSmittysDialogue('dialogue-confirm');
  128. } else if (smoothPearlMineralUnidentified > 0) {
  129. clicksItem('smoothPearlMineralUnidentified');
  130. closeSmittysDialogue('dialogue-confirm');
  131. }
  132. }
  133.  
  134. function autoNecklaceCharge() {
  135. changeMineralNecklace()
  136. }
  137.  
  138. function autoTrain() {
  139. if (train > 0 && trainTimer == 0 && oil == 500000 * train) {
  140. sendBytes('MANAGE_TRAIN='+train)
  141. closeSmittysDialogue('dialogue-confirm')
  142. }
  143. }
  144.  
  145. function autoSmelt() {
  146. if (smeltingCurrentOreType == 'none') {
  147. let scriptSmeltingOreLocal = scriptSmeltingOre
  148. if (scriptSmeltingOreLocal < 1 && scriptSmeltingOre !== 'rarest') {scriptSmeltingOre = 'rarest'}
  149. if (scriptSmeltingOreLocal == 'rarest') {
  150. ancientOre > 50 && plasma > 50 ? scriptSmeltingOreLocal = 'ancientOre'
  151. : titanium > 200 && charcoal > 200 ? scriptSmeltingOreLocal = 'titanium'
  152. : promethium > 500 && lava > 500 ? scriptSmeltingOreLocal = 'promethium'
  153. : gold > 500 ? scriptSmeltingOreLocal = 'gold'
  154. : silver > 1000 ? scriptSmeltingOreLocal = 'silver'
  155. : iron > 2000 ? scriptSmeltingOreLocal = 'iron'
  156. : scriptSmeltingOre = 'copper'
  157. }
  158. chooseOreForFurnace(scriptSmeltingOreLocal)
  159. startSmelting()
  160. closeSmittysDialogue('dialogue-furnace2')
  161. }
  162. }
  163.  
  164. function autoRefine() {
  165. if (scriptRefinaryBar == 'gold' && oil > 500000 && goldBars > 99) {
  166. sendBytes('REFINE_GOLD_BARS=goldBars')
  167. closeSmittysDialogue('dialogue-confirm')
  168.  
  169. } else if (oil > 2000000 && promethiumBars > 99) {
  170. sendBytes('REFINE_GOLD_BARS=promethiumBars')
  171. closeSmittysDialogue('dialogue-confirm')
  172. }
  173. }
  174.  
  175. function autoFoundry() {
  176. if (charcoalFoundryCurrentOreType == 0 || charcoalFoundryCurrentOreType == 'none') {
  177. let scriptFoundryWoodLocal = scriptFoundryWood
  178. if (scriptFoundryWoodLocal == 'cheapest') {
  179. logs > 100 ? scriptFoundryWoodLocal = 'logs'
  180. : oakLogs > 100 ? scriptFoundryWoodLocal = 'oakLogs'
  181. : willowLogs > 100 ? scriptFoundryWoodLocal = 'willowLogs'
  182. : mapleLogs > 100 ? scriptFoundryWoodLocal = 'mapleLogs'
  183. : redwoodLogs > 100 ? scriptFoundryWoodLocal = 'redwoodLogs'
  184. : pineLogs > 100 ? scriptFoundryWoodLocal = 'pineLogs'
  185. : hauntedLogs > 100 ? scriptFoundryWoodLocal = 'hauntedLogs'
  186. : jungleLogs > 100 ? scriptFoundryWoodLocal = 'jungleLogs'
  187. : lavaLogs > 100 ? scriptFoundryWoodLocal = 'lavaLogs'
  188. : goldLogs > 100 ? scriptFoundryWoodLocal = 'goldLogs'
  189. : magicLogs > 100 ? scriptFoundryWoodLocal = 'magicLogs'
  190. : scriptFoundryWoodLocal = 'none';
  191. }
  192. if (scriptFoundryWoodLocal > 20 && lava > 12 && scriptFoundryWoodLocal !== 'none') {
  193. sendBytes('CHARCOAL_FOUNDRY='+scriptFoundryWoodLocal+'~'+100)
  194. closeSmittysDialogue('dialogue-confirm')
  195. }
  196. }
  197. }
  198.  
  199. function autoLumber() {
  200. if (scriptTreeIgnore[tree6] === false && treeTimer6 == 1) {
  201. sendBytes('CHOP_TREE=6')}
  202. if (scriptTreeIgnore[tree5] === false && treeTimer5 == 1) {
  203. sendBytes('CHOP_TREE=5')}
  204. if (scriptTreeIgnore[tree4] === false && treeTimer4 == 1) {
  205. sendBytes('CHOP_TREE=4')}
  206. if (scriptTreeIgnore[tree3] === false && treeTimer3 == 1) {
  207. sendBytes('CHOP_TREE=3')}
  208. if (scriptTreeIgnore[tree2] === false && treeTimer2 == 1) {
  209. sendBytes('CHOP_TREE=2')}
  210. if (scriptTreeIgnore[tree1] === false && treeTimer1 == 1) {
  211. sendBytes('CHOP_TREE=1')}
  212. }
  213.  
  214. function autoPlant() {
  215. if (farmTimer1 < 2 || farmTimer2 < 2 || (farmTimer3 < 2 && farmUnlocked3 == 1) || (farmTimer4 < 2 && farmUnlocked4 == 1) || (farmTimer5 < 2 && farmUnlocked5 == 1) || (farmTimer6 < 2 && farmUnlocked6 == 1)) {
  216. var seedItems = document.getElementById("sortableSeeds").getElementsByTagName("li")
  217.  
  218. for (var i = 0; i < seedItems.length; i++) {
  219. var seedCheckbox = seedItems[i].querySelector(".seed-checkbox");
  220. var selectedSeed = seedItems[i].getAttribute("value"); // Obter o valor do atributo 'value'
  221.  
  222. if (seedCheckbox.checked) {
  223. setBobsAutoReplantSeed(selectedSeed);
  224. closeSmittysDialogue("dialogue-bob");
  225. sendBytes("HARVEST_AND_PLANT_ALL");
  226. closeSmittysDialogue("dialogue-confirm");
  227. }
  228. }
  229. }
  230. }
  231.  
  232. function autoBones() {
  233. if (scriptBonesIgnore.bones === false && bones > 0) {
  234. sendBytes('ADD_BONEMEAL=bones~'+bones)}
  235. if (scriptBonesIgnore.ashes === false && ashes > 0) {
  236. sendBytes('ADD_BONEMEAL=ashes~'+ashes)}
  237. if (scriptBonesIgnore.iceBones === false && iceBones > 0) {
  238. sendBytes('ADD_BONEMEAL=iceBones~'+iceBones)}
  239. if (scriptBonesIgnore.zombieBones === false && zombieBones > 0) {
  240. sendBytes('ADD_BONEMEAL=zombieBones~'+zombieBones)}
  241. if (scriptBonesIgnore.bloodBones === false && bloodBones > 0) {
  242. sendBytes('ADD_BONEMEAL=bloodBones~'+bloodBones)}
  243. if (scriptBonesIgnore.fishBones === false && fishBones > 9) {
  244. sendBytes('ADD_BONEMEAL=fishBones~'+(Math.floor(fishBones/10))*10)}
  245. }
  246.  
  247. function autoDrink() {
  248. var potionItems = document.getElementById("sortablePotions").getElementsByTagName("li")
  249.  
  250. for (var i = 0; i < potionItems.length; i++) {
  251. var drinkCheckbox = potionItems[i].querySelector(".drink-checkbox");
  252. var selectedPotion = potionItems[i].getAttribute("value"); // Obter o valor do atributo 'value'
  253.  
  254. if (drinkCheckbox.checked && window[selectedPotion] > 0 && window[selectedPotion+'Timer'] == 0) {
  255. sendBytes('DRINK='+selectedPotion);
  256. setTimeout(closeSmittysDialogue("dialogue-confirm"))
  257. }
  258. }
  259. }
  260.  
  261. function autoBrew() {
  262. var potionItems = document.getElementById("sortablePotions").getElementsByTagName("li")
  263.  
  264. for (var i = 0; i < potionItems.length; i++) {
  265. var drinkCheckbox = potionItems[i].querySelector(".drink-checkbox");
  266. var brewCheckbox = potionItems[i].querySelector(".brew-checkbox");
  267. var selectedPotion = potionItems[i].getAttribute("value"); // Obter o valor do atributo 'value'
  268.  
  269. if (brewCheckbox.checked && drinkCheckbox.checked && window[selectedPotion] == 0) {
  270. sendBytes('BREW='+selectedPotion+'~1');
  271. setTimeout(closeSmittysDialogue("dialogue-confirm"))
  272. }
  273. }
  274. }
  275.  
  276. function autoExplore() {
  277. if (explorerCooldown == 0) {
  278. let scriptAreaLocal = scriptArea
  279. if (energy < scriptAreaEnergy.scriptAreaLocal) {scriptAreaLocal = 'fields'}
  280. sendBytes('EXPLORE='+scriptAreaLocal)
  281. }
  282. }
  283.  
  284. function autoFight() {
  285. if (exploringArea !== 'none' && fightDone == 0) {
  286. sendBytes('LOOK_FOR_FIGHT')
  287. }
  288. }
  289.  
  290. function autoCousin() {
  291. if (typeof goblinExploringArea == 'undefined' || goblinExploringArea == 'none') {
  292. let scriptCousinAreaLocal = scriptCousinArea
  293. if (energy < scriptAreaEnergy.scriptCousinAreaLocal) {scriptCousinAreaLocal = 'fields'}
  294. goblinCousin=1;
  295. sendBytes('EXPLORE_GOBLIN='+scriptCousinAreaLocal)
  296. setTimeout(closeSmittysDialogue('dialogue-confirm'),1000)
  297. }
  298. }
  299.  
  300. function autoStatue() {
  301. sendBytes('SELL_ALL_STATUES')
  302. closeSmittysDialogue('dialogue-confirm')
  303. }
  304.  
  305. function autoArtifact() {
  306. sendBytes('CONVERT_ALL_ARTIFACTS')
  307. closeSmittysDialogue('dialogue-confirm')
  308. }
  309.  
  310. function autoBoat() {
  311. if (rowBoat == 1 && scriptBoatSend.rowBoat == true && rowBoatTimer < 2 && bait > 4) {
  312. sendBytes('CLICKS_BOAT=rowBoat')
  313. }
  314. if (canoeBoat == 1 && scriptBoatSend.canoeBoat == true && canoeBoatTimer < 2 && bait > 24) {
  315. sendBytes('CLICKS_BOAT=canoeBoat')
  316. }
  317. if (scriptBoatSend.highWind == true) {
  318. if (sailBoat == 1 && scriptBoatSend.sailBoat == true && currentWind > 1 && sailBoatTimer < 2 && bait > 99) {
  319. sendBytes('CLICKS_BOAT=sailBoat')
  320. }
  321. } else if (sailBoat == 1 && scriptBoatSend.sailBoat == true && sailBoatTimer < 2 && bait > 99) {
  322. sendBytes('CLICKS_BOAT=sailBoat')
  323. }
  324. if (steamBoat == 1 && scriptBoatSend.steamBoat == true && steamBoatTimer < 2 && bait > 249) {
  325. sendBytes('CLICKS_BOAT=steamBoat')
  326. }
  327. if (trawler == 1 && scriptBoatSend.trawler == true && trawlerTimer < 2 && bait > 499) {
  328. sendBytes('CLICKS_BOAT=trawler')
  329. }
  330. }
  331.  
  332. function autoCityUnlock() {
  333. sendBytes('CLICKS_SHOP_VOTE=9');
  334. sendBytes('CLICKS_SHOP_VOTE=6');
  335. closeSmittysDialogue('dialogue-confirm')
  336. }
  337.  
  338. function hideAllTabs2() {
  339. oldHideAllTabs()
  340. document.getElementById("tab-scriptConfig").style.display = "none";
  341. document.getElementById("tab-scriptConfigMining").style.display = "none";
  342. document.getElementById("tab-scriptConfigCrafting").style.display = "none";
  343. document.getElementById("tab-scriptConfigWoodcutting").style.display = "none";
  344. document.getElementById("tab-scriptConfigFarming").style.display = "none";
  345. document.getElementById("tab-scriptConfigSeeds").style.display = "none";
  346. document.getElementById("tab-scriptConfigBrewing").style.display = "none";
  347. document.getElementById("tab-scriptConfigPotions").style.display = "none";
  348. document.getElementById("tab-scriptConfigExploring").style.display = "none";
  349. document.getElementById("tab-scriptConfigCooking").style.display = "none";
  350. }
  351.  
  352. window.hideAllTabs = hideAllTabs2
  353.  
  354. function autoChangeVar(variName,variValue,id) {
  355. localStorage.setItem(variName, JSON.stringify(variValue))
  356. window[variName] = variValue
  357. if (typeof id !== 'undefined') {if (variValue == true) {document.getElementById(id).style.color = "green"} else {document.getElementById(id).style.color = "red"}
  358. console.log(id)}
  359. }
  360.  
  361. window.autoChangeVar2 = autoChangeVar;
  362.  
  363. function autoChangeObject(variName,variKey,variValue,id) {
  364. localStorage.setItem(variName+'.'+variKey, JSON.stringify(variValue))
  365. window[variName][variKey] = variValue
  366. if (typeof id !== 'undefined') {if (variValue == true) {document.getElementById(id).style.color = "green"} else {document.getElementById(id).style.color = "red"}}
  367. }
  368.  
  369. window.autoChangeObject2 = autoChangeObject
  370.  
  371. function scriptAddTabs() {
  372. var scriptConfBar = document.createElement("div");
  373. let miscTab = document.querySelectorAll("#tab-misc > .main-button");
  374. scriptConfBar.innerHTML = `<div onclick="navigate('scriptConfig')" class="main-button" style="cursor: pointer;">
  375. <table>
  376. <tbody><tr>
  377. <td><img src="images/whiteGear.png" class="img-small"></td>
  378. <td style="text-align:right;padding-right:20px;font-size:12pt;">SCRIPT CONFIG</td>
  379. </tr>
  380. </tbody></table>
  381. </div>`;
  382. miscTab[2].parentNode.insertBefore(scriptConfBar,miscTab[3]);
  383.  
  384. var scriptConfTab = document.createElement("div");
  385. var scriptConfMiningTab = document.createElement("div");
  386. var scriptConfCraftingTab = document.createElement("div");
  387. var scriptConfWoodcuttingTab = document.createElement("div");
  388. var scriptConfFarmingTab = document.createElement("div");
  389. var scriptConfSeedsTab = document.createElement("div");
  390. var scriptConfBrewingTab = document.createElement("div");
  391. var scriptConfPotionsTab = document.createElement("div");
  392. var scriptConfExploringTab = document.createElement("div");
  393. var scriptConfCookingTab = document.createElement("div");
  394. let gameScreen = document.querySelectorAll("#game-screen")[1];
  395. let logoutTab = document.getElementById('tab-logout');
  396. scriptConfTab.innerHTML = `<div id="tab-scriptConfig" style="display:none">
  397. <div class="main-button-lighter">
  398. <table><tbody><tr onclick="navigate('main');playPreviousMenuSound();" style="cursor: pointer;">
  399. <td><img src="images/back.png" class="img-small"></td>
  400. <td class="back-label">BACK</td></tr></tbody></table>
  401. </div>
  402. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptGlobalToggle" onclick="window.autoChangeVar2('toggleGlobal',!toggleGlobal,this.id)" style="cursor: pointer; color: green;">
  403. <td style="padding-left: 10px;"><img src="images/whiteGear.png" class="img-medium"></td>
  404. <td style="text-align:right;padding-right:20px;width:100%">SCRIPT TOGGLE</td></tr></tbody></table>
  405. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptMiningTogglesBar" onclick="navigate('scriptConfigMining')" style="cursor: pointer; color: white;">
  406. <td style="padding-left: 10px;"><img src="images/miningSkill.png" class="img-medium"></td>
  407. <td style="text-align:right;padding-right:20px;width:100%">MINING TOGGLES</td></tr></tbody></table>
  408. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptCraftingTogglesBar" onclick="navigate('scriptConfigCrafting')" style="cursor: pointer; color: white;">
  409. <td style="padding-left: 10px;"><img src="images/craftingSkill.png" class="img-medium"></td>
  410. <td style="text-align:right;padding-right:20px;width:100%">CRAFTING TOGGLES</td></tr></tbody></table>
  411. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptWoodcuttingTogglesBar" onclick="navigate('scriptConfigWoodcutting')" style="cursor: pointer; color: white;">
  412. <td style="padding-left: 10px;"><img src="images/woodcuttingSkill.png" class="img-medium"></td>
  413. <td style="text-align:right;padding-right:20px;width:100%">WOODCUTTING TOGGLES</td></tr></tbody></table>
  414. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptFarmingTogglesBar" onclick="navigate('scriptConfigFarming')" style="cursor: pointer; color: white;">
  415. <td style="padding-left: 10px;"><img src="images/farmingSkill.png" class="img-medium"></td>
  416. <td style="text-align:right;padding-right:20px;width:100%">FARMING TOGGLES</td></tr></tbody></table>
  417. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptBrewingTogglesBar" onclick="navigate('scriptConfigBrewing')" style="cursor: pointer; color: white;">
  418. <td style="padding-left: 10px;"><img src="images/brewingSkill.png" class="img-medium"></td>
  419. <td style="text-align:right;padding-right:20px;width:100%">BREWING TOGGLES</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptExploringTogglesBar" onclick="navigate('scriptConfigExploring')" style="cursor: pointer; color: white;">
  420. <td style="padding-left: 10px;"><img src="images/exploringSkill.png" class="img-medium"></td>
  421. <td style="text-align:right;padding-right:20px;width:100%">EXPLORING TOGGLES</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptCookingTogglesBar" onclick="navigate('scriptConfigCooking')" style="cursor: pointer; color: white;">
  422. <td style="padding-left: 10px;"><img src="images/cookingSkill.png" class="img-medium"></td>
  423. <td style="text-align:right;padding-right:20px;width:100%">COOKING TOGGLES</td></tr></tbody></table></div>`
  424.  
  425.  
  426. scriptConfMiningTab.innerHTML = `<div id="tab-scriptConfigMining" style="display:none">
  427. <div class="main-button-lighter">
  428. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  429. <td><img src="images/back.png" class="img-small"></td>
  430. <td class="back-label">BACK</td></tr></tbody></table>
  431. </div>
  432. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptGeodeToggle" onclick="window.autoChangeVar2('toggleGeodeOpen',!toggleGeodeOpen,this.id)" style="cursor: pointer; color: green;">
  433. <td style="padding-left: 10px;"><img src="images/geode5.png" class="img-small"></td>
  434. <td style="text-align:right;padding-right:20px;width:100%">GEODE OPENING</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptMineralToggle" onclick="window.autoChangeVar2('toggleMineralIdentify',!toggleMineralIdentify,this.id)" style="cursor: pointer; color: green;">
  435. <td style="padding-left: 10px;"><img src="images/tanzaniteMineral.png" class="img-small"></td>
  436. <td style="text-align:right;padding-right:20px;width:100%">MINERAL IDENTIFY</td></tr></tbody></table>
  437. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptNecklaceToggle" onclick="window.autoChangeVar2('toggleNecklaceCharge',!toggleNecklaceCharge,this.id)" style="cursor: pointer; color: red;">
  438. <td style="padding-left: 10px;"><img src="images/mineralNecklace.png" class="img-small"></td>
  439. <td style="text-align:right;padding-right:20px;width:100%">NECKLACE CHARGE</td></tr></tbody></table>
  440. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptTrainToggle" onclick="window.autoChangeVar2('toggleTrain',!toggleTrain,this.id)" style="cursor: pointer; color: red;">
  441. <td style="padding-left: 10px;"><img src="images/train.png" class="img-small"></td>
  442. <td style="text-align:right;padding-right:20px;width:100%">TRAIN</td></tr></tbody></table></div>`
  443.  
  444. scriptConfCraftingTab.innerHTML= `<div id="tab-scriptConfigCrafting" style="display:none">
  445. <div class="main-button-lighter">
  446. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  447. <td><img src="images/back.png" class="img-small"></td>
  448. <td class="back-label">BACK</td></tr></tbody></table>
  449. </div>
  450. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptSmeltingToggle" onclick="window.autoChangeVar2('toggleSmelting',!toggleSmelting,this.id)" style="cursor: pointer; color: green;">
  451. <td style="padding-left: 10px;"><img src="images/ancientFurnace.png" class="img-small"></td>
  452. <td style="text-align:right;padding-right:20px;width:100%">SMELTING</td></tr></tbody></table>
  453. <table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptSmeltingOre" style="color: white;">
  454. <td style="padding-left: 10px;"><img src="images/gold.png" class="img-small"></td>
  455. <td style="padding-left: 50px;"><select name="scriptSmeltingOreOptions" onchange="window.autoChangeVar2('scriptSmeltingOre',this.value)" id="scriptSmeltingOreOptions">
  456. <option value="rarest">Rarest</option>
  457. <option value="copper">Copper</option>
  458. <option value="iron">Iron</option>
  459. <option value="silver">Silver</option>
  460. <option value="gold">Gold</option><option value="promethium">Promethium</option><option value="titanium">Titanium</option><option value="ancientOre">Ancient</option></select></td><td style="text-align:right;padding-right:20px;width:100%">SMELTING ORE</td></tr></tbody></table>
  461. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptRefinaryToggle" onclick="window.autoChangeVar2('toggleRefinary',!toggleRefinary,this.id)" style="cursor: pointer; color: red;">
  462. <td style="padding-left: 10px;"><img src="images/goldBarRefinery.png" class="img-small"></td>
  463. <td style="text-align:right;padding-right:20px;width:100%">REFINARY</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptRefinaryBar" style="color: white;">
  464. <td style="padding-left: 10px;"><img src="images/refinedGoldBars.png" class="img-small"></td>
  465. <td style="padding-left: 50px;"><select name="scriptRefinaryBarOptions" onchange="window.autoChangeVar2('scriptRefinaryBar',this.value)" id="scriptRefinaryOptions">
  466. <option value="gold">Gold</option>
  467. <option value="promethium">Promethium</option>
  468. </select></td><td style="text-align:right;padding-right:20px;width:100%">REFINARY BAR</td></tr></tbody></table>
  469. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptFoundryToggle" onclick="window.autoChangeVar2('toggleCharcoal',!toggleCharcoal,this.id)" style="cursor: pointer; color: red;">
  470. <td style="padding-left: 10px;"><img src="images/charcoalFoundry.png" class="img-small"></td>
  471. <td style="text-align:right;padding-right:20px;width:100%">CHARCOAL FOUNDRY</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptFoundryWood" style="color: white;">
  472. <td style="padding-left: 10px;"><img src="images/lavaLogs.png" class="img-small"></td>
  473. <td style="padding-left: 50px;"><select name="scriptFoundryWoodOptions" onchange="window.autoChangeVar2('scriptFoundryWood',this.value)" id="scriptFoundryWoodOptions">
  474. <option value="cheapest">Cheapest</option>
  475. <option value="logs">Logs</option>
  476. <option value="oakLogs">Oak Logs</option>
  477. <option value="willowLogs">Willow Logs</option>
  478. <option value="mapleLogs">Maple Logs</option><option value="redwoodLogs">Redwood Logs</option><option value="pineLogs">Pine Logs</option><option value="hauntedLogs">Haunted Logs</option><option value="jungleLogs">Jungle Logs</option><option value="lavaLogs">Lava Logs</option><option value="goldLogs">Gold Logs</option><option value="magicLogs">Magic Logs</option></select></td><td style="text-align:right;padding-right:20px;width:100%">CHARCOAL LOG</td></tr></tbody></table></div>`
  479.  
  480. scriptConfWoodcuttingTab.innerHTML= `<div id="tab-scriptConfigWoodcutting" style="display:none">
  481. <div class="main-button-lighter">
  482. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  483. <td><img src="images/back.png" class="img-small"></td>
  484. <td class="back-label">BACK</td></tr></tbody></table>
  485. </div>
  486. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptLumberToggle" onclick="window.autoChangeVar2('toggleWoodcutting',!toggleWoodcutting,this.id)" style="cursor: pointer; color: green;">
  487. <td style="padding-left: 10px;"><img src="images/lumberjack.png" class="img-small"></td>
  488. <td style="text-align:right;padding-right:20px;width:100%">LUMBERJACK</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 20px;width: 97%;"><tbody style="display: block;"><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','tree',!scriptTreeIgnore.tree,this.id)" id="treeIgnoreToggle">
  489. <td style="padding-left: 10px;width: 5%;"><img src="images/tree.png" class="img-small"></td>
  490. <td style="text-align: center;width: 40%">TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','oakTree',!scriptTreeIgnore.oakTree,this.id)" id="oakTreeIgnoreToggle">
  491. <td style="padding-left: 10px;width: 5%;"><img src="images/oakTree.png" class="img-small"></td>
  492. <td style="text-align: center;width: 40%">OAK TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','willowTree',!scriptTreeIgnore.willowTree,this.id)" id="willowTreeIgnoreToggle">
  493. <td style="padding-left: 10px;width: 5%;"><img src="images/willowTree.png" class="img-small"></td>
  494. <td style="text-align: center;width: 40%">WILLOW TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','mapleTree',!scriptTreeIgnore.mapleTree,this.id)" id="mapleTreeIgnoreToggle">
  495. <td style="padding-left: 10px;width: 5%;"><img src="images/mapleTree.png" class="img-small"></td>
  496. <td style="text-align: center;width: 40%">MAPLE TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','redwoodTree',!scriptTreeIgnore.redwoodTree,this.id)" id="redwoodTreeIgnoreToggle">
  497. <td style="padding-left: 10px;width: 5%;"><img src="images/redwoodTree.png" class="img-small"></td>
  498. <td style="text-align: center;width: 40%">REDWOOD TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','pineTree',!scriptTreeIgnore.pineTree,this.id)" id="pineTreeIgnoreToggle">
  499. <td style="padding-left: 10px;width: 5%;"><img src="images/pineTree.png" class="img-small"></td>
  500. <td style="text-align: center;width: 40%">PINE TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','hauntedTree',!scriptTreeIgnore.hauntedTree,this.id)" id="hauntedTreeIgnoreToggle">
  501. <td style="padding-left: 10px;width: 5%;"><img src="images/hauntedTree.png" class="img-small"></td>
  502. <td style="text-align: center;width: 40%">HAUNTED TREE IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','jungleTree',!scriptTreeIgnore.jungleTree,this.id)" id="jungleTreeIgnoreToggle">
  503. <td style="padding-left: 10px;width: 5%;"><img src="images/jungleTree.png" class="img-small"></td>
  504. <td style="text-align: center;width: 40%">JUNGLE TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','lavaTree',!scriptTreeIgnore.lavaTree,this.id)" id="lavaTreeIgnoreToggle">
  505. <td style="padding-left: 10px;width: 5%;"><img src="images/lavaTree.png" class="img-small"></td>
  506. <td style="text-align: center;width: 40%">LAVA TREE IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','goldTree',!scriptTreeIgnore.goldTree,this.id)" id="goldTreeIgnoreToggle">
  507. <td style="padding-left: 10px;width: 5%;"><img src="images/goldTree.png" class="img-small"></td>
  508. <td style="text-align: center;width: 40%">GOLD TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','magicTree',!scriptTreeIgnore.magicTree,this.id)" id="magicTreeIgnoreToggle">
  509. <td style="padding-left: 10px;width: 5%;"><img src="images/magicTree.png" class="img-small"></td>
  510. <td style="text-align: center;width: 40%">MAGIC TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','appleTree',!scriptTreeIgnore.appleTree,this.id)" id="appleTreeIgnoreToggle">
  511. <td style="padding-left: 10px;width: 5%;"><img src="images/appleTree.png" class="img-small"></td>
  512. <td style="text-align: center;width: 40%">APPLE TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','cactusTree',!scriptTreeIgnore.cactusTree,this.id)" id="cactusTreeIgnoreToggle">
  513. <td style="padding-left: 10px;width: 5%;"><img src="images/cactusTree.png" class="img-small"></td>
  514. <td style="text-align: center;width: 40%">CACTUS TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','bananaTree',!scriptTreeIgnore.bananaTree,this.id)" id="bananaTreeIgnoreToggle">
  515. <td style="padding-left: 10px;width: 5%;"><img src="images/bananaTree.png" class="img-small"></td>
  516. <td style="text-align: center;width: 40%">BANANA TREE IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','palmTree',!scriptTreeIgnore.palmTree,this.id)" id="palmTreeIgnoreToggle">
  517. <td style="padding-left: 10px;width: 5%;"><img src="images/palmTree.png" class="img-small"></td>
  518. <td style="text-align: center;width: 40%">PALM TREE IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptTreeIgnore','pineappleTree',!scriptTreeIgnore.pineappleTree,this.id)" id="pineappleTreeIgnoreToggle">
  519. <td style="padding-left: 10px;width: 5%;"><img src="images/pineappleTree.png" class="img-small"></td>
  520. <td style="text-align: center;width: 40%">PINEAPPLE TREE IGNORE</td></tr><tr style="color: red;" onclick="window.autoChangeObject2('scriptTreeIgnore','starfuitTree',!scriptTreeIgnore.starfuitTree,this.id)" id="starfruitTreeIgnoreToggle">
  521. <td style="padding-left: 10px;width: 5%;"><img src="images/starfruitTree.png" class="img-small"></td>
  522. <td style="text-align: center;">STARFRUIT TREE IGNORE</td></tr></tbody></table></div>`
  523.  
  524. scriptConfFarmingTab.innerHTML= `<div id="tab-scriptConfigFarming" style="display:none">
  525. <div class="main-button-lighter">
  526. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  527. <td><img src="images/back.png" class="img-small"></td>
  528. <td class="back-label">BACK</td></tr></tbody></table>
  529. </div>
  530. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptFarmingToggle" onclick="window.autoChangeVar2('toggleFarming',!toggleFarming,this.id)" style="cursor: pointer; color: red;">
  531. <td style="padding-left: 10px;"><img src="images/farmer.png" class="img-small"></td>
  532. <td style="text-align:right;padding-right:20px;width:100%">HARVEST AND PLANT</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;cursor: pointer;"><tbody><tr id="scriptSeedToggleBar" onclick="navigate('scriptConfigSeeds')" style="color: white;">
  533. <td style="padding-left: 10px;"><img src="images/goldLeafSeeds.png" class="img-small"></td>
  534. <td style="text-align:right;padding-right:20px;width:100%">SEED SELECTOR</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptBonesToggle" onclick="window.autoChangeVar2('toggleBones',!toggleBones,this.id)" style="cursor: pointer; color: red;">
  535. <td style="padding-left: 10px;"><img src="images/bonemealBin.png" class="img-small"></td>
  536. <td style="text-align:right;padding-right:20px;width:100%">BONEMEAL</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 20px;width: 97%;"><tbody style="display: block;"><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBonesIgnore','bones',!scriptBonesIgnore.bones,this.id)" id="bonesIgnoreToggle">
  537. <td style="padding-left: 10px;width: 5%;"><img src="images/bones.png" class="img-small"></td>
  538. <td style="text-align: center;width: 40%">BONES IGNORE</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptBonesIgnore','ashes',!scriptBonesIgnore.ashes,this.id)" id="ashesIgnoreToggle">
  539. <td style="padding-left: 10px;width: 5%;"><img src="images/ashes.png" class="img-small"></td>
  540. <td style="text-align: center;width: 40%">ASHES IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBonesIgnore','iceBones',!scriptBonesIgnore.iceBones,this.id)" id="iceBonesIgnoreToggle">
  541. <td style="padding-left: 10px;width: 5%;"><img src="images/iceBones.png" class="img-small"></td>
  542. <td style="text-align: center;width: 40%">ICE BONES IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBonesIgnore','zombieBones',!scriptBonesIgnore.zombieBones,this.id)" id="zombieBonesIgnoreToggle">
  543. <td style="padding-left: 10px;width: 5%;"><img src="images/zombieBones.png" class="img-small"></td>
  544. <td style="text-align: center;width: 40%">ZOMBIE BONES IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBonesIgnore','bloodBones',!scriptBonesIgnore.bloodBones,this.id)" id="bloodBonesIgnoreToggle">
  545. <td style="padding-left: 10px;width: 5%;"><img src="images/bloodBones.png" class="img-small"></td>
  546. <td style="text-align: center;width: 40%">BLOOD BONES IGNORE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBonesIgnore','fishBones',!scriptBonesIgnore.fishBones,this.id)" id="fishBonesIgnoreToggle">
  547. <td style="padding-left: 10px;width: 5%;"><img src="images/fishBones.png" class="img-small"></td>
  548. <td style="text-align: center;width: 40%">FISH BONES IGNORE</td></tr></tbody></table></div>`
  549.  
  550. scriptConfSeedsTab.innerHTML= `<div id="tab-scriptConfigSeeds" style="display:none">
  551. <div class="main-button-lighter">
  552. <table><tbody><tr onclick="navigate('scriptConfigFarming');playPreviousMenuSound();" style="cursor: pointer;">
  553. <td><img src="images/back.png" class="img-small"></td>
  554. <td class="back-label">BACK</td></tr></tbody></table>
  555. </div>
  556. <table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptSeedsInfo" style="color: white;">
  557. <td style="padding-left: 10px;"></td>
  558. <td style="text-align: center;padding-right:20px;width: 100%;"><p>PRIORITY WILL BE DEFINED BASED ON THE POSITION OF THE SEED</p><p>DRAG AND DROP ONCE AFTER CHECKING BOXES</p></td></tr></tbody></table><ol id="sortableSeeds" style="list-style: none;padding: 0px;border: 1px solid grey;border-radius: 6px;margin: 10px;font-size: 25px;">
  559. <li class="ui-state-default" value="redMushroomSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  560. <input type="checkbox" class="seed-checkbox"> Red Mushroom Seeds<img src="images/redMushroomSeeds.png" class="img-small" style="padding-right: 10px;">
  561. </li><li class="ui-state-default" value="dottedGreenLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  562. <input type="checkbox" class="seed-checkbox"> Dotted Green Leaf Seeds<img src="images/dottedGreenLeafSeeds.png" class="img-small" style="padding-right: 10px;"></li>
  563. <li class="ui-state-default" value="greenLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  564. <input type="checkbox" class="seed-checkbox"> Green Leaf Seeds<img src="images/greenLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  565. </li>
  566. <li class="ui-state-default" value="limeLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  567. <input type="checkbox" class="seed-checkbox"> Lime Leaf Seeds<img src="images/limeLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  568. </li>
  569. <li class="ui-state-default" value="goldLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  570. <input type="checkbox" class="seed-checkbox"> Gold Leaf Seeds<img src="images/goldLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  571. </li>
  572. <li class="ui-state-default" value="crystalLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  573. <input type="checkbox" class="seed-checkbox"> Crystal Leaf Seeds<img src="images/crystalLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  574. </li>
  575. <li class="ui-state-default" value="stripedGreenLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  576. <input type="checkbox" class="seed-checkbox"> Striped Green Leaf Seeds<img src="images/stripedGreenLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  577. </li>
  578. <li class="ui-state-default" value="stripedGoldLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  579. <input type="checkbox" class="seed-checkbox"> Striped Gold Leaf Seeds<img src="images/stripedGoldLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  580. </li>
  581. <li class="ui-state-default" value="stripedCrystalLeafSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  582. <input type="checkbox" class="seed-checkbox"> Striped Crystal Leaf Seeds<img src="images/stripedCrystalLeafSeeds.png" class="img-small" style="padding-right: 10px;">
  583. </li>
  584. <li class="ui-state-default" value="treeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  585. <input type="checkbox" class="seed-checkbox"> Tree Seeds<img src="images/treeSeeds.png" class="img-small" style="padding-right: 10px;">
  586. </li>
  587. <li class="ui-state-default" value="oakTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  588. <input type="checkbox" class="seed-checkbox"> Oak Tree Seeds<img src="images/oakTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  589. </li>
  590. <li class="ui-state-default" value="willowTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  591. <input type="checkbox" class="seed-checkbox"> Willow Tree Seeds<img src="images/willowTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  592. </li>
  593. <li class="ui-state-default" value="mapleTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  594. <input type="checkbox" class="seed-checkbox"> Maple Tree Seeds<img src="images/mapleTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  595. </li>
  596. <li class="ui-state-default" value="redwoodTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  597. <input type="checkbox" class="seed-checkbox"> Redwood Tree Seeds<img src="images/redwoodTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  598. </li>
  599. <li class="ui-state-default" value="pineTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  600. <input type="checkbox" class="seed-checkbox"> Pine Tree Seeds<img src="images/pineTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  601. </li>
  602. <li class="ui-state-default" value="hauntedTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  603. <input type="checkbox" class="seed-checkbox"> Haunted Tree Seeds<img src="images/hauntedTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  604. </li>
  605. <li class="ui-state-default" value="jungleTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  606. <input type="checkbox" class="seed-checkbox"> Jungle Tree Seeds<img src="images/jungleTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  607. </li>
  608. <li class="ui-state-default" value="lavaTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  609. <input type="checkbox" class="seed-checkbox"> Lava Tree Seeds<img src="images/lavaTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  610. </li>
  611. <li class="ui-state-default" value="goldTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  612. <input type="checkbox" class="seed-checkbox"> Gold Tree Seeds<img src="images/goldTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  613. </li>
  614. <li class="ui-state-default" value="magicTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  615. <input type="checkbox" class="seed-checkbox"> Magic Tree Seeds<img src="images/magicTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  616. </li>
  617. <li class="ui-state-default" value="appleTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  618. <input type="checkbox" class="seed-checkbox"> Apple Tree Seeds<img src="images/appleTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  619. </li>
  620. <li class="ui-state-default" value="cactusTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  621. <input type="checkbox" class="seed-checkbox"> Cactus Tree Seeds<img src="images/cactusTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  622. </li>
  623. <li class="ui-state-default" value="bananaTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  624. <input type="checkbox" class="seed-checkbox"> Banana Tree Seeds<img src="images/bananaTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  625. </li>
  626. <li class="ui-state-default" value="palmTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  627. <input type="checkbox" class="seed-checkbox"> Palm Tree Seeds<img src="images/palmTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  628. </li>
  629. <li class="ui-state-default" value="pineappleTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  630. <input type="checkbox" class="seed-checkbox"> Pineapple Tree Seeds<img src="images/pineappleTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  631. </li>
  632. <li class="ui-state-default" value="starfruitTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  633. <input type="checkbox" class="seed-checkbox"> Starfruit Tree Seeds<img src="images/starfruitTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  634. </li>
  635. <li class="ui-state-default" value="goldAppleTreeSeeds" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  636. <input type="checkbox" class="seed-checkbox"> Gold Apple Tree Seeds<img src="images/goldAppleTreeSeeds.png" class="img-small" style="padding-right: 10px;">
  637. </li></ol></div>`
  638.  
  639. scriptConfBrewingTab.innerHTML= `<div id="tab-scriptConfigBrewing" style="display:none">
  640. <div class="main-button-lighter">
  641. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  642. <td><img src="images/back.png" class="img-small"></td>
  643. <td class="back-label">BACK</td></tr></tbody></table>
  644. </div>
  645. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptDrinkToggle" onclick="window.autoChangeVar2('toggleDrink',!toggleDrink,this.id)" style="cursor: pointer; color: red;">
  646. <td style="padding-left: 10px;"><img src="images/diamondBrewingKit.png" class="img-small"></td>
  647. <td style="text-align:right;padding-right:20px;width:100%">POTION DRINK</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptBrewToggle" onclick="window.autoChangeVar2('toggleBrew',!toggleBrew,this.id)" style="cursor: pointer; color: red;">
  648. <td style="padding-left: 10px;"><img src="images/goldLeaf.png" class="img-small"></td>
  649. <td style="text-align:right;padding-right:20px;width:100%">POTION BREW</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;cursor: pointer;"><tbody><tr id="scriptPotionToggleBar" onclick="navigate('scriptConfigPotions')" style="color: white;">
  650. <td style="padding-left: 10px;"><img src="images/researchSpeedPotion.png" class="img-small"></td>
  651. <td style="text-align:right;padding-right:20px;width:100%">POTION SELECTOR</td></tr></tbody></table></div>`
  652.  
  653. scriptConfPotionsTab.innerHTML= `<div id="tab-scriptConfigPotions" style="display:none">
  654. <div class="main-button-lighter">
  655. <table><tbody><tr onclick="navigate('scriptConfigBrewing');playPreviousMenuSound();" style="cursor: pointer;">
  656. <td><img src="images/back.png" class="img-small"></td>
  657. <td class="back-label">BACK</td></tr></tbody></table>
  658. </div>
  659. <table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptPotionsInfo" style="color: white;">
  660. <td style="padding-left: 10px;"></td>
  661. <td style="text-align: center;padding-right:20px;width: 100%;">IT WILL ONLY BREW IF DRINK IS ALSO SELECTED AND DOES NOT CHECK THE INGREDIENTS</td></tr></tbody></table><div class="ui-state-default" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;margin: 10px;font-size: 25px;">
  662. <p style="
  663. margin-top: 0px;
  664. margin-bottom: 0px;
  665. padding-left: 10px;
  666. ">DRINK</p>
  667. <p style="
  668. margin-top: 0px;
  669. margin-bottom: 0px;
  670. padding-left: 0px;
  671. padding-right: 10px;
  672. ">BREW</p></div><ol id="sortablePotions" style="list-style: none;padding: 0px;border: 1px solid grey;border-radius: 6px;margin: 10px;font-size: 25px;">
  673. <li class="ui-state-default" value="furnaceSpeedPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  674. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">FURNACE SPEED POTION<img src="images/furnaceSpeedPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  675. </li><li class="ui-state-default" value="seedFinderPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  676. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">SEED FINDER POTION<img src="images/seedFinderPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  677. </li>
  678.  
  679. <li class="ui-state-default" value="compostPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  680. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">COMPOST POTION<img src="images/compostPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  681. </li>
  682.  
  683. <li class="ui-state-default" value="treeCompostPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  684. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">TREE COMPOST POTION<img src="images/treeCompostPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  685. </li>
  686.  
  687. <li class="ui-state-default" value="fishingSpeedPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  688. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">FISHING SPEED POTION<img src="images/fishingSpeedPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  689. </li>
  690.  
  691. <li class="ui-state-default" value="woodcuttingXpPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  692. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">WOODCUTTING XP POTION<img src="images/woodcuttingXpPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  693. </li>
  694.  
  695. <li class="ui-state-default" value="exploringSpeedPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  696. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">EXPLORER SPEED POTION<img src="images/exploringSpeedPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  697. </li>
  698.  
  699. <li class="ui-state-default" value="baitPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  700. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">BAIT POTION<img src="images/baitPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  701. </li>
  702.  
  703. <li class="ui-state-default" value="farmingXpPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  704. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">FARMING XP POTION<img src="images/farmingXpPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  705. </li>
  706.  
  707. <li class="ui-state-default" value="superCompostPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  708. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">SUPER COMPOST POTION<img src="images/superCompostPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  709. </li>
  710.  
  711. <li class="ui-state-default" value="oilPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  712. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">OIL POTION<img src="images/oilPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  713. </li>
  714.  
  715. <li class="ui-state-default" value="coinPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  716. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">COIN POTION<img src="images/coinPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  717. </li>
  718.  
  719. <li class="ui-state-default" value="piratesPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  720. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">PIRATES POTION<img src="images/piratesPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  721. </li>
  722.  
  723. <li class="ui-state-default" value="promethiumPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  724. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">PROMETHIUM POTION<img src="images/promethiumPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  725. </li>
  726.  
  727. <li class="ui-state-default" value="rocketSpeedPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  728. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">ROCKET SPEED POTION<img src="images/rocketSpeedPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  729. </li>
  730.  
  731. <li class="ui-state-default" value="fruitTreePotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  732. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">FRUIT TREE POTION<img src="images/fruitTreePotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  733. </li>
  734.  
  735. <li class="ui-state-default" value="titaniumPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  736. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">TITANIUM POTION<img src="images/titaniumPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  737. </li>
  738.  
  739. <li class="ui-state-default" value="researchSpeedPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  740. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">RESEARCH SPEED POTION<img src="images/researchSpeedPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  741. </li>
  742.  
  743. <li class="ui-state-default" value="superRocketSpeedPotion" style="border-radius: 6px;background: #1a1a1a;color: white;justify-content: space-between;display: flex;">
  744. <input type="checkbox" class="drink-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">SUPER ROCKET SPEED POTION<img src="images/superRocketSpeedPotion.png" class="img-small" style="padding-right: 10px;"><input type="checkbox" class="brew-checkbox" style="margin-right: 30px;" onchange="window.savePotions2()">
  745. </li></ol></div>`
  746.  
  747. scriptConfExploringTab.innerHTML= `<div id="tab-scriptConfigExploring" style="">
  748. <div class="main-button-lighter">
  749. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  750. <td><img src="images/back.png" class="img-small"></td>
  751. <td class="back-label">BACK</td></tr></tbody></table>
  752. </div>
  753. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptExploreToggle" onclick="window.autoChangeVar2('toggleExplore',!toggleExplore,this.id)" style="cursor: pointer; color: red;">
  754. <td style="padding-left: 10px;"><img src="images/explorer.png" class="img-small"></td>
  755. <td style="text-align:right;padding-right:20px;width:100%">EXPLORER</td></tr></tbody></table>
  756. <table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptExplorerArea" style="color: white;">
  757. <td style="padding-left: 10px;"><img src="images/caves.png" class="img-small"></td>
  758. <td style="padding-left: 50px;"><select name="scriptAreaOptions" onchange="window.autoChangeVar2('scriptArea',this.value)" id="scriptAreaOptions">
  759. <option value="fields">Fields</option>
  760. <option value="forests">Forests</option>
  761. <option value="caves">Caves</option>
  762. <option value="volcano">Volcano</option>
  763. <option value="northernFields">Northern Fields</option>
  764. <option value="hauntedMansion">Haunted Mansion</option>
  765. <option value="desert">Desert</option>
  766. <option value="ocean">Ocean</option>
  767. <option value="jungle">Jungle</option>
  768. <option value="dungeonEntrance">Dungeon Entrance</option>
  769. <option value="dungeon">Dungeon</option>
  770. <option value="castle">Castle</option>
  771. <option value="cemetery">Cemetery</option>
  772. <option value="factory">Factory</option>
  773. <option value="hauntedWoods">Haunted Woods</option>
  774. <option value="deepOcean">Deep Ocean</option>
  775. </select></td><td style="text-align:right;padding-right:20px;width:100%">EXPLORER AREA</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptFightToggle" onclick="window.autoChangeVar2('toggleFight',!toggleFight,this.id)" style="cursor: pointer; color: red;">
  776. <td style="padding-left: 10px;"><img src="images/combat.png" class="img-small"></td>
  777. <td style="text-align:right;padding-right:20px;width:100%">FIGHT</td></tr></tbody></table>
  778. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptCousinToggle" onclick="window.autoChangeVar2('toggleCousin',!toggleCousin,this.id)" style="cursor: pointer; color: red;">
  779. <td style="padding-left: 10px;"><img src="images/goblinCousin.png" class="img-small"></td>
  780. <td style="text-align:right;padding-right:20px;width:100%">GOBLIN COUSIN</td></tr></tbody></table>
  781. <table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptCousinArea" style="color: white;">
  782. <td style="padding-left: 10px;"><img src="images/fields.png" class="img-small"></td>
  783. <td style="padding-left: 50px;"><select name="scriptCousinAreaOptions" onchange="window.autoChangeVar2('scriptCousinArea',this.value)" id="scriptCousinAreaOptions">
  784. <option value="fields">Fields</option>
  785. <option value="forests">Forests</option>
  786. <option value="caves">Caves</option>
  787. <option value="volcano">Volcano</option>
  788. <option value="northernFields">Northern Fields</option>
  789. <option value="hauntedMansion">Haunted Mansion</option>
  790. <option value="desert">Desert</option>
  791. <option value="ocean">Ocean</option>
  792. <option value="jungle">Jungle</option>
  793. <option value="dungeonEntrance">Dungeon Entrance</option>
  794. <option value="dungeon">Dungeon</option>
  795. <option value="castle">Castle</option>
  796. <option value="cemetery">Cemetery</option>
  797. <option value="factory">Factory</option>
  798. <option value="hauntedWoods">Haunted Woods</option>
  799. <option value="deepOcean">Deep Ocean</option>
  800. </select></td><td style="text-align:right;padding-right:20px;width:100%">COUSIN AREA</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptStatueToggle" onclick="window.autoChangeVar2('toggleStatue',!toggleStatue,this.id)" style="cursor: pointer; color: red;">
  801. <td style="padding-left: 10px;"><img src="images/bronzeStatueMetalDetector.png" class="img-small"></td>
  802. <td style="text-align:right;padding-right:20px;width:100%">STATUE SELL</td></tr></tbody></table><table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptArtifactToggle" onclick="window.autoChangeVar2('toggleArtifact',!toggleArtifact,this.id)" style="cursor: pointer; color: red;">
  803. <td style="padding-left: 10px;"><img src="images/skullArtifact.png" class="img-small"></td>
  804. <td style="text-align:right;padding-right:20px;width:100%">ARTIFACT CONVERT</td></tr></tbody></table></div>`
  805.  
  806. scriptConfCookingTab.innerHTML= `<div id="tab-scriptConfigCooking" style="display:none">
  807. <div class="main-button-lighter">
  808. <table><tbody><tr onclick="navigate('scriptConfig');playPreviousMenuSound();" style="cursor: pointer;">
  809. <td><img src="images/back.png" class="img-small"></td>
  810. <td class="back-label">BACK</td></tr></tbody></table>
  811. </div>
  812. <table style="cursor: pointer;border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 32px;"><tbody><tr id="scriptBoatToggle" onclick="window.autoChangeVar2('toggleBoat',!toggleBoat,this.id)" style="cursor: pointer; color: green;">
  813. <td style="padding-left: 10px;"><img src="images/sailBoat.png" class="img-small"></td>
  814. <td style="text-align:right;padding-right:20px;width:100%">BOAT</td></tr></tbody></table><table style="border: 1px solid grey;border-radius: 6px;margin: 10px 7px;background: #1a1a1a;font-size: 20px;width: 97%;"><tbody style="display: block;"><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBoatSend','rowBoat',!scriptBoatSend.rowBoat,this.id)" id="rowBoatSendToggle">
  815. <td style="padding-left: 10px;width: 5%;"><img src="images/rowBoat.png" class="img-small"></td>
  816. <td style="text-align: center;width: 40%">ROW BOAT</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBoatSend','canoeBoat',!scriptBoatSend.canoeBoat,this.id)" id="canoeBoatSendToggle">
  817. <td style="padding-left: 10px;width: 5%;"><img src="images/canoeBoat.png" class="img-small"></td>
  818. <td style="text-align: center;width: 40%">CANOE</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBoatSend','sailBoat',!scriptBoatSend.sailBoat,this.id)" id="sailBoatSendToggle">
  819. <td style="padding-left: 10px;width: 5%;"><img src="images/sailBoat.png" class="img-small"></td>
  820. <td style="text-align: center;width: 40%">SAIL BOAT</td></tr><tr style="display: inline-block; color: red; width: 50%;" onclick="window.autoChangeObject2('scriptBoatSend','highWind',!scriptBoatSend.highWind,this.id)" id="highWindSendToggle">
  821. <td style="padding-left: 10px;width: 5%;"><img src="images/windIcon.png" class="img-small"></td>
  822. <td style="text-align: center;width: 40%">WAIT HIGH WIND</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBoatSend','steamBoat',!scriptBoatSend.steamBoat,this.id)" id="steamBoatSendToggle">
  823. <td style="padding-left: 10px;width: 5%;"><img src="images/steamBoat.png" class="img-small"></td>
  824. <td style="text-align: center;width: 40%">STEAM BOAT</td></tr><tr style="display: inline-block; color: green; width: 50%;" onclick="window.autoChangeObject2('scriptBoatSend','trawler',!scriptBoatSend.trawler,this.id)" id="trawlerSendToggle">
  825. <td style="padding-left: 10px;width: 5%;"><img src="images/trawler.png" class="img-small"></td>
  826. <td style="text-align: center;width: 40%">TRAWLER</td></tr></tbody></table>
  827.  
  828.  
  829. </div>`;
  830. gameScreen.insertBefore(scriptConfTab,logoutTab);
  831. gameScreen.insertBefore(scriptConfMiningTab,logoutTab);
  832. gameScreen.insertBefore(scriptConfCraftingTab,logoutTab);
  833. gameScreen.insertBefore(scriptConfWoodcuttingTab,logoutTab);
  834. gameScreen.insertBefore(scriptConfFarmingTab,logoutTab);
  835. gameScreen.insertBefore(scriptConfSeedsTab,logoutTab);
  836. gameScreen.insertBefore(scriptConfBrewingTab,logoutTab);
  837. gameScreen.insertBefore(scriptConfPotionsTab,logoutTab);
  838. gameScreen.insertBefore(scriptConfExploringTab,logoutTab);
  839. gameScreen.insertBefore(scriptConfCookingTab,logoutTab);
  840. }
  841.  
  842. function scriptStyleTabs() {
  843. document.getElementById('scriptGlobalToggle').style.color = toggleGlobal ? 'green' : 'red';
  844. document.getElementById('scriptGeodeToggle').style.color = toggleGeodeOpen ? 'green' : 'red';
  845. document.getElementById('scriptMineralToggle').style.color = toggleMineralIdentify ? 'green' : 'red';
  846. document.getElementById('scriptNecklaceToggle').style.color = toggleNecklaceCharge ? 'green' : 'red';
  847. document.getElementById('scriptTrainToggle').style.color = toggleTrain ? 'green' : 'red';
  848. document.getElementById('scriptSmeltingToggle').style.color = toggleSmelting ? 'green' : 'red';
  849. document.getElementById('scriptSmeltingOreOptions').value = scriptSmeltingOre;
  850. document.getElementById('scriptRefinaryToggle').style.color = toggleRefinary ? 'green' : 'red';
  851. document.getElementById('scriptRefinaryOptions').value = scriptRefinaryBar;
  852. document.getElementById('scriptFoundryToggle').style.color = toggleCharcoal ? 'green' : 'red';
  853. document.getElementById('scriptFoundryWoodOptions').value = scriptFoundryWood;
  854. document.getElementById('scriptLumberToggle').style.color = toggleWoodcutting ? 'green' : 'red';
  855. document.getElementById('treeIgnoreToggle').style.color = scriptTreeIgnore.tree ? 'green' : 'red';
  856. document.getElementById('oakTreeIgnoreToggle').style.color = scriptTreeIgnore.oakTree ? 'green' : 'red';
  857. document.getElementById('willowTreeIgnoreToggle').style.color = scriptTreeIgnore.willowTree ? 'green' : 'red';
  858. document.getElementById('mapleTreeIgnoreToggle').style.color = scriptTreeIgnore.mapleTree ? 'green' : 'red';
  859. document.getElementById('redwoodTreeIgnoreToggle').style.color = scriptTreeIgnore.redwoodTree ? 'green' : 'red';
  860. document.getElementById('pineTreeIgnoreToggle').style.color = scriptTreeIgnore.pineTree ? 'green' : 'red';
  861. document.getElementById('hauntedTreeIgnoreToggle').style.color = scriptTreeIgnore.hauntedTree ? 'green' : 'red';
  862. document.getElementById('jungleTreeIgnoreToggle').style.color = scriptTreeIgnore.jungleTree ? 'green' : 'red';
  863. document.getElementById('lavaTreeIgnoreToggle').style.color = scriptTreeIgnore.lavaTree ? 'green' : 'red';
  864. document.getElementById('goldTreeIgnoreToggle').style.color = scriptTreeIgnore.goldTree ? 'green' : 'red';
  865. document.getElementById('magicTreeIgnoreToggle').style.color = scriptTreeIgnore.magicTree ? 'green' : 'red';
  866. document.getElementById('appleTreeIgnoreToggle').style.color = scriptTreeIgnore.appleTree ? 'green' : 'red';
  867. document.getElementById('cactusTreeIgnoreToggle').style.color = scriptTreeIgnore.cactusTree ? 'green' : 'red';
  868. document.getElementById('bananaTreeIgnoreToggle').style.color = scriptTreeIgnore.bananaTree ? 'green' : 'red';
  869. document.getElementById('palmTreeIgnoreToggle').style.color = scriptTreeIgnore.palmTree ? 'green' : 'red';
  870. document.getElementById('pineappleTreeIgnoreToggle').style.color = scriptTreeIgnore.pineappleTree ? 'green' : 'red';
  871. document.getElementById('starfruitTreeIgnoreToggle').style.color = scriptTreeIgnore.starfruitTree ? 'green' : 'red';
  872. document.getElementById('scriptFarmingToggle').style.color = toggleFarming ? 'green' : 'red';
  873. document.getElementById('scriptBonesToggle').style.color = toggleBones ? 'green' : 'red';
  874. document.getElementById('bonesIgnoreToggle').style.color = scriptBonesIgnore.bones ? 'green' : 'red';
  875. document.getElementById('ashesIgnoreToggle').style.color = scriptBonesIgnore.ashes ? 'green' : 'red';
  876. document.getElementById('iceBonesIgnoreToggle').style.color = scriptBonesIgnore.iceBones ? 'green' : 'red';
  877. document.getElementById('zombieBonesIgnoreToggle').style.color = scriptBonesIgnore.zombieBones ? 'green' : 'red';
  878. document.getElementById('bloodBonesIgnoreToggle').style.color = scriptBonesIgnore.bloodBones ? 'green' : 'red';
  879. document.getElementById('fishBonesIgnoreToggle').style.color = scriptBonesIgnore.fishBones ? 'green' : 'red';
  880. document.getElementById('scriptDrinkToggle').style.color = toggleDrink ? 'green' : 'red';
  881. document.getElementById('scriptBrewToggle').style.color = toggleBrew ? 'green' : 'red';
  882. document.getElementById('scriptExploreToggle').style.color = toggleExplore ? 'green' : 'red';
  883. document.getElementById('scriptAreaOptions').value = scriptArea;
  884. document.getElementById('scriptFightToggle').style.color = toggleFight ? 'green' : 'red';
  885. document.getElementById('scriptCousinToggle').style.color = toggleCousin ? 'green' : 'red';
  886. document.getElementById('scriptCousinArea').value = scriptCousinArea;
  887. document.getElementById('scriptStatueToggle').style.color = toggleStatue ? 'green' : 'red';
  888. document.getElementById('scriptArtifactToggle').style.color = toggleArtifact ? 'green' : 'red';
  889. document.getElementById('scriptBoatToggle').style.color = toggleBoat ? 'green' : 'red';
  890. document.getElementById('rowBoatSendToggle').style.color = scriptBoatSend.rowBoat ? 'green' : 'red';
  891. document.getElementById('canoeBoatSendToggle').style.color = scriptBoatSend.canoeBoat ? 'green' : 'red';
  892. document.getElementById('sailBoatSendToggle').style.color = scriptBoatSend.sailBoat ? 'green' : 'red';
  893. document.getElementById('highWindSendToggle').style.color = scriptBoatSend.highWind ? 'green' : 'red';
  894. document.getElementById('steamBoatSendToggle').style.color = scriptBoatSend.steamBoat ? 'green' : 'red';
  895. document.getElementById('trawlerSendToggle').style.color = scriptBoatSend.trawler ? 'green' : 'red';
  896. }
  897.  
  898. function saveSeedOrder() {
  899. var seedOrderList = document.getElementById("sortableSeeds");
  900. var seedItems = seedOrderList.getElementsByTagName("li");
  901. var seedOrder = [];
  902.  
  903. for (var i = 0; i < seedItems.length; i++) {
  904. var seedValue = seedItems[i].getAttribute("value");
  905. var seedCheckbox = seedItems[i].querySelector(".seed-checkbox");
  906. var isChecked = seedCheckbox.checked;
  907.  
  908. seedOrder.push({ value: seedValue, checked: isChecked });
  909. }
  910.  
  911. localStorage.setItem("seedOrder", JSON.stringify(seedOrder));
  912. }
  913.  
  914. function loadSeedOrder() {
  915. var seedOrderData = localStorage.getItem("seedOrder");
  916.  
  917. if (seedOrderData) {
  918. seedOrderData = JSON.parse(seedOrderData);
  919. var seedOrderList = document.getElementById("sortableSeeds");
  920.  
  921. for (var i = 0; i < seedOrderData.length; i++) {
  922. var seedValue = seedOrderData[i].value;
  923. var isChecked = seedOrderData[i].checked;
  924. var seedItem = seedOrderList.querySelector("[value='" + seedValue + "']");
  925. var seedCheckbox = seedItem.querySelector(".seed-checkbox");
  926.  
  927. if (isChecked) {
  928. seedCheckbox.checked = true;
  929. } else {
  930. seedCheckbox.checked = false;
  931. }
  932.  
  933. seedOrderList.appendChild(seedItem);
  934. }
  935. }
  936. }
  937.  
  938. function savePotions() {
  939. var potionList = document.getElementById("sortablePotions");
  940. var potionItems = potionList.getElementsByTagName("li");
  941. var potionState = [];
  942.  
  943. for (var i = 0; i < potionItems.length; i++) {
  944. var potionValue = potionItems[i].getAttribute("value");
  945. var drinkCheckbox = potionItems[i].querySelector(".drink-checkbox");
  946. var brewCheckbox = potionItems[i].querySelector(".brew-checkbox");
  947. var isDrinkChecked = drinkCheckbox.checked;
  948. var isBrewChecked = brewCheckbox.checked;
  949.  
  950. potionState.push({
  951. value: potionValue,
  952. drinkChecked: isDrinkChecked,
  953. brewChecked: isBrewChecked
  954. });
  955. }
  956.  
  957. localStorage.setItem("potionState", JSON.stringify(potionState));
  958. }
  959.  
  960. window.savePotions2 = savePotions
  961.  
  962. function loadPotions() {
  963. var potionState = localStorage.getItem("potionState");
  964.  
  965. if (potionState) {
  966. potionState = JSON.parse(potionState);
  967. var potionList = document.getElementById("sortablePotions");
  968. var potionItems = potionList.getElementsByTagName("li");
  969.  
  970. for (var i = 0; i < potionState.length; i++) {
  971. var potionValue = potionState[i].value;
  972. var drinkCheckbox = potionItems[i].querySelector(".drink-checkbox");
  973. var brewCheckbox = potionItems[i].querySelector(".brew-checkbox");
  974. var isDrinkChecked = potionState[i].drinkChecked;
  975. var isBrewChecked = potionState[i].brewChecked;
  976.  
  977. drinkCheckbox.checked = isDrinkChecked;
  978. brewCheckbox.checked = isBrewChecked;
  979. }
  980. }
  981. }
  982.  
  983. window.onload = function() {
  984. scriptAddTabs();
  985. scriptStyleTabs();
  986. $(function() {
  987. $("#sortableSeeds").sortable({
  988. update: function(event, ui) {saveSeedOrder()}
  989. });
  990. $("#sortableSeeds").disableSelection();
  991. });
  992. loadSeedOrder();
  993. loadPotions();
  994. };
  995.  
  996. function autoGameLoop() {
  997. if (toggleGlobal === true) {
  998. if (toggleGeodeOpen === true) autoGeodeOpen();
  999. if (toggleMineralIdentify === true) autoIdentify();
  1000. if (toggleNecklaceCharge === true) autoNecklaceCharge();
  1001. if (toggleTrain === true) autoTrain();
  1002. if (toggleSmelting === true) autoSmelt();
  1003. if (toggleRefinary === true) autoRefine();
  1004. if (toggleCharcoal === true) autoFoundry();
  1005. if (toggleWoodcutting === true) autoLumber();
  1006. if (toggleFarming === true) autoPlant();
  1007. if (toggleBones === true) autoBones();
  1008. if (toggleDrink === true) autoDrink();
  1009. if (toggleBrew === true) autoBrew();
  1010. if (toggleExplore === true) autoExplore();
  1011. if (toggleFight === true) autoFight();
  1012. if (toggleCousin === true) autoCousin();
  1013. if (toggleStatue === true) autoStatue();
  1014. if (toggleArtifact === true) autoArtifact();
  1015. if (toggleBoat === true) autoBoat();
  1016. }
  1017. }
  1018.  
  1019. setInterval(function(){
  1020. autoGameLoop()
  1021. }, 5000);
  1022. })();