Add autoclicker functionality
See original GitHub issueYou can easily start and stop autoclicking functionality using setInterval and Game.clickCookie(). If you could put this on a button in the UI it would be very helpful, especially since the current meta requires autoclicking. I don’t consider this to be cheating since you could download a program to simulate fast mouse clicks anyways.
I’ve written some code to encapsulate the autoclicking functionality:
function Autoclicker () {
var clicking = false;
var autoClicker = null;
// shouldClick (optional) - boolean value representing whether to click or not.
// if not included will toggle current status.
this.toggleClicking = function(shouldClick) {
clicking = shouldClick != null ? shouldClick : !clicking;
if (clicking) {
// the previous interval may still be going, so clear it just in case
if (autoClicker) {
clearInterval(autoClicker);
}
autoClicker = setInterval(Game.ClickCookie, 0);
}
else {
clearInterval(autoClicker);
}
};
};
Usage example:
var clicker = new Autoclicker();
clicker.toggleClicking();
Issue Analytics
- State:
- Created 7 years ago
- Comments:6
Top Results From Across the Web
How to use an AutoClicker? - Google Sites
Auto-Clicker is a robust software that can easily automate repetitive and ... First, click on the 'Add Robot' button to add the Auto...
Read more >*New* Auto Clicker - 6 Best Automatic clickers Tools [2021]
This is one of the best free auto-clicker for PC – and its features make it way better and different than most of...
Read more >Creating a Simple Autoclicker - CodeProject
The first thing to do is to create a new Windows Form. Then we add our variable to hold the click location. C#....
Read more >How to set up Auto Clicker? - Gamers Suffice
For Windows and Mac Users ... Step 1. Download the software and open the auto-clicker file from the download section. Step 2. When...
Read more >All About Auto clicker for Chromebook - Battersea Web Expert
An auto clicker is a tool that is designed to automate your mouse click when your cursor remains steady for a certain point...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
So far CookieMonster is mostly informational. I think the only real game interaction it has is popping wrinklers and even that requires a direct user action and can hardly be used to cheat. Allowing the game to do actions on its own is not really what CookieMonster is about in my opinion. So I vote against this.
Sorry, I’ve decided to not add this functionality to Cookie Monster.