-2

A user claimed to have gotten such script running without having to leave the computer i.e. the auto-clicking action happens hidden in the browser:

http://forum.dashnet.org/discussion/206/autoclickers/p2#Comment_8954

Is that possible? If so, could the experts show me some pointers so I could learn to do some scripting for that purpose?

bunalz
  • 57
  • 1
  • 2
  • 2
  • This is entirely off topic here, but if you're curious, just inspect the `Game` javascript variable from the console if memory serves me well. – David Mulder Jul 12 '14 at 08:19
  • 1
    unattended events could be triggered via iMacro firefox addon. – yaqoob Jul 12 '14 at 08:21
  • 1
    I think this is what you are looking for. http://stackoverflow.com/a/6158050/3802940 – etr Jul 12 '14 at 08:26

2 Answers2

2

It is a very simple task to dispatch and event with javascript.

For a modern method see MouseEvent

var clickMe = document.getElementById('clickMe');

clickMe.addEventListener('click', function() {
  console.log('I was clicked');
}, true);

setTimeout(function() {
  var event = new MouseEvent('click'),
    canceled = !clickMe.dispatchEvent(event);

  if (canceled) {
    console.log('Click event was canceled');
  }
}, 5000);
<div id="clickMe">Click Me</div>

Output after 5 seconds

I was clicked 
Xotic750
  • 22,914
  • 8
  • 57
  • 79
0

var clickMe = document.getElementById('clickMe');

clickMe.addEventListener('click', function() {
  console.log('I was clicked');
}, true);

setTimeout(function() {
  var event = new MouseEvent('click'),
    canceled = !clickMe.dispatchEvent(event);

  if (canceled) {
    console.log('Click event was canceled');
  }
}, 5000);
<div id="clickMe">Click Me</div>