Skip to content

Instantly share code, notes, and snippets.

@desigens
Created September 23, 2014 08:20
Show Gist options
  • Save desigens/09bf2ab7c7d02f4c4378 to your computer and use it in GitHub Desktop.
Save desigens/09bf2ab7c7d02f4c4378 to your computer and use it in GitHub Desktop.
// Cheat for http://game.ioxapp.com/color/
(function () {
function detectUnique() {
var $boxes = $('#box span');
colors = {};
$boxes.each(function () {
var color = $(this).attr('style');
colors[color] = colors[color] ? colors[color] + 1 : 1;
});
for (color in colors) {
if (colors[color] === 1) {
$('[style="' + color + '"]').click();
}
};
}
setInterval(detectUnique, 1);
}());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment