# Two-Button Idle Game

Two-Button Idle Game is a puzzle that was made for but not included in the Galactic Puzzle Hunt, and can be found here.

It was mentioned in the wrap-up (Caution: Spoilers!), but no solution was provided. I've tried to solve it but have failed.

## Can you help to solve it?

Note: the solution will probably fit one or two of the constraints from the metapuzzles, one from the first three and perhaps(?) one from the last

Since links can go down, here's an explanation:

The game looks like this:

• The tick counter increments every second (really 1000ms)
• You start with one Thingmaker I, on 0 ticks and with 0 things
• Each Thingmaker I makes 1 thing per tick, and each Thingmaker II makes 2 things per tick
• The two blue things are buttons, and getting a Thingmaker of either type costs a certain amount of things:
• A Thingmaker I costs $$\left\lceil2.037852523524990022707470416208^{\#number\_of\_Thingmaker\_I's\_bought}\right\rceil$$
• A Thingmaker II costs $$\left\lceil25\cdot1.636831037414898881721114776155^{\#number\_of\_Thingmaker\_II's\_bought}\right\rceil$$
• The game ends once you get at least 1000000000000 things:
• If you do it in at most 9032770134 ticks, you get the following message:
• If you do it in more than 9032770134 ticks, you get the following message:
• You get achievements for reaching certain milestones:
1. Maker Domination (Buy 70 total thingmakers)
2. Amazing Amount of Things (Have 500000000 things)
3. Nice Stash of Things (Have 800 things)
4. A Maker Collection (Buy 30 total thingmakers)
5. Insane Superabundance of Things (Have 1000000000 things)
6. First Dozen Makers (Buy 12 total thingmakers)
7. Big Number of Things (Have 2000000 things)
8. Huge Stockpile of Things (Have 65000 things)
9. Maker Commander (Buy 48 total thingmakers)
10. Crazy Endowment of Things (Have 8000000 things)
11. Maker Professional (Buy 60 total thingmakers)
12. Things Start to Happen (Have 25 things)
13. A Final Victory of Things (Have 1000000000000 things)

HTML:

<!DOCTYPE html>
<html lang="en"><script type="text/javascript">window["_gaUserPrefs"] = { ioo : function() { return true; } }</script><head>
<meta charset="utf-8">
<title>title</title>
<style>
body { background-color: #100; margin: 0; font-family: sans-serif; }
#wrap { background-color: #eee; margin-left: auto; margin-right: auto; max-width: 900px; }
#cont { padding: 2px 16px; }
h1, h2 { border-bottom: 1px solid #999; }
button {
margin: 6px;
cursor: pointer;
background-repeat: repeat-x;
border-color: #258;
box-shadow: inset 0 4px 0 rgba(255,255,255,.15),0 4px 4px >rgba(0,0,0,.075);
font-size: 18px;
line-height: 1.3333333;
color: #fff;
border: 2px solid #258;
background-color: #258;
}
button:hover {
background-position: 0 -45px;
}
button:active {
background-image: none;
background-color: #036;
box-shadow: inset 0 10px 10px rgba(0,0,0,.5);
}
button:disabled {
cursor: not-allowed;
background-color: #258;
background-image: none;
opacity: 0.5;
}
big { font-weight: bold; display: block; border: 2px solid #060; background-color: #cfc; padding: 8px; }
</style>
<body>
<div id="wrap">
<div id="cont">
<h1>Two-Button Idle Game</h1>
<div id="ticks">Ticks: 0</div>
<div id="things">Things: 0</div>
<button role="button" id="tis" disabled>
<p>Thingmaker I (owned: <strong class="owned">0</strong>)</p>
<p>Makes 1 thing per tick.</p>
<p class="cost">Cost: 3 things</p>
</button>
<button role="button" id="tiis" disabled>
<p>Thingmaker II (owned: <strong class="owned">0</strong>)</p>
<p>Makes 2 things per tick.</p>
<p class="cost">Cost: 25 things</p>
</button>
<br>
<p>Get 1000000000000 things to win!</p>
<p>Achievements:</p>
<ul id="achievements"></ul>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.1.1.js" integrity="sha256->16cdPddA6VdVInumRGo6IbivbERE8p7CQR3HzTBuELA=" crossorigin="anonymous"></script>
<script type="text/javascript">
var ticks = 0;
var things = 0;
var tickId = undefined;
{
name: "tis",
count: 1,
cost: function() {
return Math.ceil(Math.pow(2.037852523524990022707470416208, >this.count));
},
tick: function() { things += this.count; },
},
{
name: "tiis",
count: 0,
cost: function() {
return Math.ceil(25 * Math.pow(1.636831037414898881721114776155, >this.count));
},
tick: function() { things += 2 * this.count; },
},
];

function get(amount, name, victory) {
return {
name: name,
description: "Have " + amount + " things",
achieved: false,
check: function() {
if (!this.achieved && things >= amount) {
this.achieved = true;
return true;
}
return false;
},
victory: victory,
}
}
return {
name: name,
description: "Buy " + amount + " total thingmakers",
achieved: false,
check: function() {
if (!this.achieved
this.achieved = true;
return true;
}
return false;
},
victory: false,
}
}

var achievements = [
get(500000000, "Amazing Amount of Things"),
get(800, "Nice Stash of Things"),
get(1000000000, "Insane Superabundance of Things"),
get(2000000, "Big Number of Things"),
get(65000, "Huge Stockpile of Things"),
get(8000000, "Crazy Endowment of Things"),
get(25, "Things Start to Happen"),
get(1000000000000, "A Final Victory of Things", true),
];

if (finalTicks <= 9032770134) {
return "You won, and achieved a perfect runthrough!";
} else {
return "You won, but you can do better!";
}
}

function triggerVictory() {
window.clearInterval(tickId);
var $big =$(document.createElement('big')).text(grade(ticks));
$('#things').after($big);
$('#' + b.name).prop('disabled', true); }); } function checkAchievements() { achievements.map(function (achievement, index) { if (achievement.check()) { var atext = 'Achievement ' + (index + 1) + ': ' + achievement.name; atext += ' (' + achievement.description + ')'; var$li = $(document.createElement('li')).text(atext);$('#achievements').append($li); if (achievement.victory) { triggerVictory(); } } }); } function update() {$('#ticks').text("Ticks: " + ticks);
$('#things').text("Things: " + things); buyables.forEach(function (b) { var cost = b.cost(); var canBuy = cost <= things; var$elt = $('#' + b.name);$elt.prop('disabled', !canBuy);
$elt.find('.owned').text(b.count);$elt.find('.cost').text("Cost: " + cost + " things");
});
}
function tick() {
ticks += 1;
update();
checkAchievements();
}
$(function() { buyables.forEach(function (b) { var$elt = $('#' + b.name);$elt.click(function () {
var cost = b.cost();
var canBuy = cost <= things;
things -= cost;
b.count++;
update();
checkAchievements();
});
});
update();
tickId = window.setInterval(tick, 1000);
});
</script>

</body></html>