You are a dwarf, and you're digging a hole.
You have X minutes before the dragon arrives (I haven't decided yet).
Get to the treasure, and when the dragon arrives, it will get the gold, and you won't get eaten.
Prevent goblins from plugging your holes with sand by bashing them with your mithril shovel forged by ancient dwarven artificers.
I use Pico-8. Here's what works so far: