Jump to content

CAKE STACK - Tower of Hanoi with jelly physics clay cakes (three.js, 20 stages)


oreumgames
 Share

Recommended Posts

Hi all,

This one is a Tower of Hanoi where the discs are cakes. Three stands, twenty flavors from three tiers up to eight, some stages that start scrambled across all three stands, and an eight tier wedding cake at the end that takes 255 moves at minimum. Try to put a big tier on a small one and it boings back into your hand.

CAKE STACK oops

Tech, since this is a dev forum: three.js with no engine on top, and no model files. Every cake is built in code from lathe, torus and sphere shapes with a clay texture, piped cream rings and toppings. The wobble is a small spring system per tier, one spring for squash and two for lean, with the lean passed up the stack so the whole cake sways together. The scale keeps volume, so a squashed tier spreads out instead of just getting shorter. The scrambled stages come from a seeded generator, and the minimum move count for any scrambled position is computed from the largest tier down. Music and sound effects are generated with Web Audio.

CAKE STACK mint chocolate stage

The part that took longest was making it feel like cake and not rubber, and the part we did not expect was layout: six languages meant a long Russian flavor name broke the stage cards on phones until the card text learned to shrink itself. It runs on PC and phones with nothing to install. Feedback is welcome, and thanks for looking.

https://oreumgames.com/en/games/flash/cakehanoi/

Made by a very small indie team in Korea.

Link to comment
Share on other sites

The spring per tier with the lean passed up the stack is a neat way to get the whole cake swaying together. One idea for the 255 move wedding cake: since you already compute the minimum move count, show it next to the player's count when a stage ends. Landing close to the minimum gives people something to chase, and a retry loop on the shorter stages comes almost for free. How do you handle undo on the scrambled stages, or is every move final?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...