Spyke

Rust away!🤭 Actually it sounds reasonable, I guess in Rust 2D arrays are easier to work with than in Bash.

3
christosreply
lemmy.world

I don't understand what you are asking, please elaborate.

1

No worries. My bad.

miniserve, a popular command line program written in Rust to serve static files, also counts down (from three though) before launching the server, just like he counts down from five before someone rewrites your Hanoi Tower game in Rust.

http://crates.io/crates/miniserve

1
feddit.org

nice - do you know why using h+l is so much faster than the arrow keys?

3
Marty_TFreply
lemmy.zip

bcs u dont need to put one hand on the arrow keys and have to use the other hand for the rest of the keyboard or alternatively jump around with ur hands

of course this isnt a huge factor in a little game but vim people are used to it. i was sceptical of vim keybinding at first but then i started using it and dam it is true that it's superior

4
7eterreply
feddit.org

Agreed! But I also noticed a significant performance difference (in the time that the game take to update the selected stack). It might be due to my lack in cli-gaming, but I never noticed something like that before.

4
christosreply
lemmy.world

This bug is now fixed, its origin was escape code parsing while using the arrow keys: looped three times before getting the input. You can update the script to get the improved version. As I said, it is now fixed, plus the max level of disks is up to 13.

Recursion until hell freezes over.

2

You noticed correctly, I made the trade off because I wanted to have an extra disk level available (10 instead of 9), but I believe it was not worth it. I updated the script, it is now quite snappier I think, check it out if you wish, and let me know what you think.

Thanks for the feedback.

1

You reached the end

Terminal Tower of Hanoi, in Bash | Spyke