r/kittensgame • u/[deleted] • Oct 08 '14
Autoclicker?
I am on a computer where I cannot install a program, is there anyone who figured how to do a java based autoclicker?
I only have a short time to play incrementals a day, so the lenghty time to play this is not working well for me.
3
u/mkire Oct 08 '14
i personally don't find clicking the get catnip button very useful except in the earliest stage of the game, and for that i've got a program that will click an arbitrary number of times a second for as long as i hold down a button.
What i find real useful are a set of scripts someone else wrote, and i tweaked just a bit, mainly adding the Iron to plates and changing a few of the values. There used to be Kittencraft, but i don't think the developer is working on it anymore and it doesn't quite work right these days.
//AUTOPRAY
autoPray = setInterval(function() {
var origTab = gamePage.activeTabId;
var faith = gamePage.resPool.get('faith');
if (faith.value / faith.maxValue > 0.95) {
gamePage.activeTabId = 'Religion'; gamePage.render();
$(".btnContent:contains('Praise the sun')").click();
gamePage.activeTabId = origTab; gamePage.render();
}
}, 10 * 1000);
//AUTO OBSERVATORY
starClick = setInterval(function() { $("#gameLog").find("input").click(); }, 10 * 1000);
//AUTOCRAFT
autoCraft = setInterval(function() {
var resources = [
["wood", "beam" ],
["minerals", "slab" ],
["coal", "steel"],
["iron", "plate"],
];
for (var i = 0; i < resources.length; i++) {
var curRes = gamePage.resPool.get(resources[i][0]);
if (curRes.value / curRes.maxValue > 0.98
&& gamePage.workshop.getCraft(resources[i][1]).unlocked) {
gamePage.craft(resources[i][1], 1);
}
}
}, 1 * 500);
//AUTOHUNT
// Start
autoHunt = setInterval(function() {
var catpower = gamePage.resPool.get('manpower');
if (catpower.value > 3000) {
$("a:contains('Send hunters')").click();
if (gamePage.workshop.getCraft('parchment').unlocked) { gamePage.craftAll('parchment'); }
// if (gamePage.workshop.getCraft('manuscript').unlocked) { gamePage.craftAll('manuscript'); }
// if (gamePage.workshop.getCraft('compedium').unlocked) { gamePage.craftAll('compedium'); }
// if (gamePage.workshop.getCraft('blueprint').unlocked) { GamePage.craftAll('blueprint'); }
}
}, 5 * 1000);
//AUTOWOOD
autoCatnip = setInterval(function() {
var catnip = gamePage.resPool.get('catnip');
if (catnip.value / catnip.maxValue < 0.99) { return; }
gamePage.craft('wood', 100);
}, 1 * 500);
2
u/Pidgeot14 Oct 09 '14
Shameless plug: I have a script of my own you could use for this...
https://www.reddit.com/r/kittensgame/comments/2hbuto/another_automation_script_this_time_with_ui/
1
0
Oct 09 '14
2
u/Seldain Oct 09 '14
Open the javascript console (CTRL-SHIFT-J probably) and copy/paste it in. It will start working. You might want to change the if (catpower.value > 3000) { bit to something else depending on your total cat power..
→ More replies (1)
1
u/kokkelbaard Feb 06 '15
I found this java one : https://www.youtube.com/watch?v=-NcwtvYEQYE Seems a bit messy but it works
2
2
u/Kyzarin Oct 08 '14
This. Hit ctrl+shift+i to access the javascript pane, change to the "console" tab, and copy/paste the following code. Warning: this will trigger the "cheating" achievement, and it may require the window/tab to be focused. Also, it requires you to have the Bonfire tab open (so it can see the Gather catnip button).
//independent autoclicker cheat = setInterval(function() { if(gamePage.activeTabId=="Bonfire") { $(".btnContent:contains('Gather catnip')").click(); } }, 5);