concego/bites-and-baits — explained in plain English
Analysis updated 2026-05-18
See a working example of controlling a web game with phone tilt and shake gestures.
Study how to generate game sound effects in real time with the Web Audio API instead of audio files.
Learn a pattern for making a fast-paced web game accessible to screen reader users via ARIA live regions.
| concego/bites-and-baits | 00kaku/gallery-slider-block | 3rd-eden/ircb.io | |
|---|---|---|---|
| Stars | 0 | — | — |
| Language | JavaScript | JavaScript | JavaScript |
| Last pushed | — | 2021-05-19 | 2016-11-16 |
| Maintenance | — | Dormant | Dormant |
| Setup difficulty | easy | easy | easy |
| Complexity | 2/5 | 2/5 | 2/5 |
| Audience | developer | general | developer |
Figures from each repo's GitHub metadata at analysis time.
Playable directly in a browser via GitHub Pages, no build step or install needed.
Bites and Baits is a small browser fishing game built as a proof of concept for using a phone's physical sensors, accelerometer, gyroscope, vibration, and audio, directly in a web page without installing anything. The point of the project is not really the game itself but showing that immersive, accessible experiences can be built with standard web APIs alone. It runs on a phone with motion sensors or on a computer with a keyboard, and it was designed from the start to work with screen readers. On a phone, tilting forward casts the line, tilting back reels in the fish, and shaking the phone sets the hook when a fish bites, using the DeviceOrientationEvent and DeviceMotionEvent browser APIs. On iOS this requires the user to explicitly grant permission. Game events also trigger distinct vibration patterns through the Vibration API, so a player can feel when a fish bites, when the hook is set, or when the line snaps, without needing to look at the screen. All of the game's sound, ambient water noise, reel pitch, bite sounds, and the line snapping, is generated in real time with the Web Audio API rather than played from audio files. Accessibility is built into the core design rather than added afterward. The game relies on the phone's own screen reader, TalkBack on Android or VoiceOver on iOS, to narrate events through ARIA live regions, and it uses a double animation frame technique to make sure urgent messages like a fish biting interrupt whatever the screen reader was already announcing. When the game is actively being played, the rest of the interface is hidden from the screen reader so only the relevant announcements come through. The game moves a player through states such as waiting, a fish biting, reeling it in, and either catching it or having the line snap. Five fish species are defined with different rarity, resistance, and timing windows, from the common and easy Lambari to the rare Pirarucu, which acts as a boss fish that resists longer and barely tires. When no accelerometer is available, the game automatically falls back to arrow key and spacebar controls. It is built with plain HTML, CSS, and JavaScript, with no frameworks or external dependencies, and is released under the MIT license.
Bites and Baits is a browser fishing game demo that uses a phone's accelerometer, vibration, and audio APIs for physical immersion, built with screen reader accessibility as a core design goal.
Mainly JavaScript. The stack also includes JavaScript, HTML5, CSS3.
MIT license, free to study, adapt, and reuse the code.
Setup difficulty is rated easy, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Don't trust strangers blindly. Verify against the repo.