Skip to content

Instantly share code, notes, and snippets.

@pyxl-hacks
Forked from zbitname/particle-clicker-cheat.js
Created January 27, 2022 11:52
Show Gist options
  • Save pyxl-hacks/0af5bd71a6d3e0869444ea1c56f63612 to your computer and use it in GitHub Desktop.
Save pyxl-hacks/0af5bd71a6d3e0869444ea1c56f63612 to your computer and use it in GitHub Desktop.
ParticleClicker cheat
/*
Cheat code for http://particle-clicker.web.cern.ch/particle-clicker/
*/
(function(angular) {
var e = angular.element;
function c() {
e('#detector').scope().dc.click();
}
function u() {
var rcScope = e('#researchContent').scope().rc;
rcScope.research.forEach(function(r) {
if (rcScope.isAvailable(r)) {
rcScope.doResearch(r);
}
});
var hrScope = e('#hrContent').scope().hrc;
hrScope.workers.forEach(function(w) {
if (hrScope.isAvailable(w)) {
hrScope.hire(w);
}
});
var ucScope = e('#upgradesContent').scope().uc;
ucScope.upgrades.forEach(function(u) {
if (ucScope.isAvailable(u)) {
ucScope.upgrade(u);
}
});
}
setInterval(c, 10);
setInterval(u, 100);
})(angular);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment