Making a bot that types code in a websites console

Posts 1–2 of 2 · Page 1 of 1
Making a bot that types code in a websites console
So I want to make a bot that when I run it, it types "game.earn('number')" in the console

specifically the game is cookie clicker
i would say with a Greasemonkey Script
Code:
function init() {
  var costumButton = document.createElement('input');
  costumButton.type = 'button';
  costumButton.value = 'My Secret Button';
  costumButton.addEventListener('click', () => game.earn('number'));
  
  var costumBar = document.createElement('div');  
  costumBar.appendChild(costumButton);
  
  document.body.appendChild(costumBar); 
}

var onload = window.addEventListener('load', init);
it will add a Button to the bottom and sends 'game.earn('number')' if you click on it
Posts 1–2 of 2 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us