I employed a number of tricks. The ones I am particularly proud of are:
- The title screen, which uses the iconic old-school wavy text effect. To make this fast in Bash, I ended up precomputing the table of sin that determines the offset of each slice:
- The rendering system required to get all this to run a smooth, consistent 60fps on both linux and macs, without blocking key reading. It sends itself an ALRM signal trap to run the game loop in a co-process, much similarly to how it's usually done with `requestAnimationFrame`:
It's packed with cool text graphics, animations, sound effects, paddle acceleration, side spin, and power-ups. Clone, inspect, play with Q and P keys.
https://github.com/zenoamaro/arkanoid.sh
I employed a number of tricks. The ones I am particularly proud of are:
- The title screen, which uses the iconic old-school wavy text effect. To make this fast in Bash, I ended up precomputing the table of sin that determines the offset of each slice:
https://github.com/zenoamaro/arkanoid.sh/blob/master/src/tit...
- The rendering system required to get all this to run a smooth, consistent 60fps on both linux and macs, without blocking key reading. It sends itself an ALRM signal trap to run the game loop in a co-process, much similarly to how it's usually done with `requestAnimationFrame`:
https://github.com/zenoamaro/arkanoid.sh/blob/master/arkanoi...
- The deferred frame-buffer drawing mode:
https://github.com/zenoamaro/arkanoid.sh/blob/master/src/gfx...
Hope you enjoy it :)