Commit graph

7 commits

Author SHA1 Message Date
1acd790806 Pipe barriers now reach the top of the screen
On a tall phone the game world sits in the lower part of the display, so
the upper pipe column used to stop in mid-air with dead sky above it -
and the bird could actually fly up past the wall into that gap.

The upper column is now drawn from above the top edge of the screen down
to the gap, and its collision box matches, so the ceiling is always
where the player expects it on any screen shape.
2026-10-23 20:16:39 +02:00
43db37e63b Service worker: network-first for the app shell
Cache-first meant players kept loading the previous build until their
second visit - a redeploy was invisible. The shell is now fetched from
the network first and falls back to the cache when offline; the icons and
manifest stay cache-first. Cache name bumped to v2 to drop old copies.
2026-10-23 20:10:09 +02:00
15b37e7cc9 Mobile: tappable bird picker + rendering performance
Touch:
- tapping the big bird portrait now cycles to the next unlocked bird
  instead of falling through and starting the run
- added on-screen < > arrows either side of the portrait row, so the
  picker works without a keyboard
- the picker no longer starts or restarts the game on a miss

Performance (the lag on mid-range phones):
- every block texture is now pre-rendered once and blitted, instead of
  redrawing 4 speckles + 4 bevels per block per frame (~540 fillRects
  a frame -> ~60 drawImage calls)
- pipe textures are anchored to the pipe, so they no longer shimmer as
  it scrolls
- the backbuffer is capped at 2x DPR with a pixel budget, so a 3x
  phone renders 1.3M pixels a frame instead of 3M

Measured 101fps on a 390x844 viewport after the change.
2026-10-23 20:07:39 +02:00
bc72c5dc30 Fullscreen PWA: no border, installs as an app, works offline
- canvas fills the entire screen on any device; the 480x640 world is
  scaled to fit and bottom-aligned so the ground always sits on the
  bottom edge, with the sky painted full-bleed behind it
- the canvas buffer now always matches its laid-out size, so the drawing
  can never drift out of step with the screen
- HUD (score, badge, buffs, toasts, biome banner) moved to screen space
  so it stays pinned to the real screen edges
- sun and stars drawn in screen space so the sky above the play area is
  not empty
- PWA: manifest, service worker (offline), generated app icons and an
  in-game INSTALL APP button
- overlays now dim the whole screen, not just the game strip
2026-10-23 19:52:18 +02:00
33c156a7dd Fix Coolify 502 Bad Gateway: serve on port 3000 as well as 80
Coolify routes to port 3000 when 'Ports exposes' is left blank, but nginx
only listened on 80 - so Traefik found nothing and returned 502 while the
container itself was healthy and passing its healthcheck.

nginx now listens on both 80 and 3000, so the game is served whichever port
the proxy routes to. README documents setting Ports exposes = 80.
2026-10-23 19:24:53 +02:00
8179ea4672 Mobile: enlarge touch targets for fingers
- portrait slots 24->30px wide, spaced 56px apart (was 44) so each bird is
  a reliable tap target on a phone
- ability badge hit area now scales with the canvas so it stays >=44 CSS px
  at any zoom level
- settings rows get a proportional vertical hit area
- portrait taps select a bird without starting the run; tapping elsewhere
  still starts it

Verified with a 390x844 touch emulation: tap-to-flap, tap-to-select,
tap-to-ability, cooldown refusal and no page scroll all pass.
2026-10-23 19:21:00 +02:00
54f94097e1 Mineflappy: Minecraft Flappy Bird with 6 birds, abilities, biomes and Docker deployment
Single-file HTML5 canvas game - sprites, bitmap font, music and sound are
all generated in code, no external assets.

Game:
- 6 playable birds, each with a unique ability (Double Flap, Teleport,
  Allay Magnet, Melt, Phase, Howl)
- 5 score-driven biomes (Plains, Desert, Mineshaft, Nether, Ice Peaks)
- Day/night cycle, weather (rain, snow, embers), camera drift
- Pickups: gold, bubble shield, elytra wings, lucky cube buffs
- Difficulty settings, bird unlocks, per-bird bests, advancement toasts
- Daily challenge with a shareable code and a ghost of your best run
- 2-player on one screen

Deployment:
- Dockerfile (nginx:alpine) serving the single file
- nginx.conf with no-cache headers, gzip and a /healthz endpoint
- docker-compose.yml and Coolify instructions in the README
2026-10-23 19:14:43 +02:00