Skip to content

Instantly share code, notes, and snippets.

@liamsnowdon
Last active September 2, 2021 13:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save liamsnowdon/cd8fdbf3a7d9e79afa056325110d93df to your computer and use it in GitHub Desktop.
Save liamsnowdon/cd8fdbf3a7d9e79afa056325110d93df to your computer and use it in GitHub Desktop.
Cookie Clicker Autoclicker
const DefinitelyNotCheats = (function () {
return {
bigCookieAutoClickerInterval: null,
goldenCookieAutoClickerInterval: null,
initAutoClickers () {
this.initBigCookieAutoClicker();
this.initGoldenCookieAutoClicker();
},
destroyAutoClickers () {
this.destroyBigCookieAutoClicker();
this.destroyGoldenCookieAutoClicker();
},
initBigCookieAutoClicker (interval = 100) {
this.bigCookieAutoClickerInterval = setInterval(Game.ClickCookie, interval);
},
destroyBigCookieAutoClicker () {
clearInterval(this.bigCookieAutoClickerInterval);
},
initGoldenCookieAutoClicker () {
this.goldenCookieAutoClickerInterval = setInterval(() => {
Game.shimmers.forEach(shimmer => {
if (shimmer.type === "golden" && shimmer.wrath === 0) {
shimmer.pop();
}
});
}, 500);
},
destroyGoldenCookieAutoClicker () {
clearInterval(this.goldenCookieAutoClickerInterval);
},
};
})();

Cookie Clicker Autoclicker

A script for automatically clicking the big cookie as well as golden cookies that appear in Cookie Clicker. That is all.

Just paste the JS into the console and run DefinitelyNotCheats.initAutoClickers();.

Note: the default behaviour will click the big cookie every 100 milliseconds to simulate a real person's normal clicking speed, so you feel better about yourself that you're cheating. If you want to change this, you can run the autoclicker init functions separately: DefinitelyNotCheats.initBigCookieAutoClicker(<interval>); where <interval> is the number of milliseconds to use in the interval.

Important: always make sure to backup your save data before doing something like this, you never know :) Options > Save to file/Export save.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment