# Fishing

Start with one bank, two fish and one decision worth making. Let the player spot a fish, follow it to the float, land it and understand what they earned.

## Make the river playable

1. Locate the water surface, navigation, save clock, inventory and input handlers. Trace a cast through them. Give each swimmer a stable ID separate from its render instance.
2. Pick a reachable standing point and a water hit inside casting range. Reject dry ground and blocked banks before moving the character. Recheck the spot on arrival. Allow touch players to cancel a misplaced cast.
3. Give one controller the sequence `idle → approach → cast → wait → bite → land → decide`. Reserve one eligible swimmer. Keep its identity through the reward screen. Clear the lock, line and prompt on a miss or cancellation.
4. Sample wave height at the float. Draw the line from the animated rod tip to the float. Relax it during the wait and pull it taut on the bite. Turn the fish, dip the float once, make a small ring and expose **Reel in** with a sound and a visible cue.
5. Measure the response window in active play seconds. Freeze it during pause and keep it independent of village fast-forward. Offer auto-reel for a relaxed mode.

## Make gear and species matter

These starting values come from Bellwater. Keep them in data shared by the shop, river and journal.

| Choice | Effect |
| --- | --- |
| Bamboo pole → ash rod → brass reel | 9 → 11 → 13 seconds to reel in |
| River carp | Available year-round, worth 5 food |
| Ayu | Available in summer and fall, worth 3 food and 2 gold |

Show the next upgrade’s actual change beside its cost. Give each rod a different silhouette. Let players recognize a species by its proportions and swimming pattern before reading its name. When a species leaves for the season, suggest an available alternative.

## Settle a catch once

Record species, length and personal best on landing. Save the pending basket even if the panel closes. Preview **Keep**, **Release** and **Cook**. Keeping pays the listed reward. Releasing lets the fish return after a rest. Cooking transfers it to the kitchen. If the kitchen is full, leave the decision open.

Commit the basket, swimmer cooldown, journal and rewards together. Use a fresh catch ID each time a swimmer returns so a stale button cannot consume the next fish.

[Catch example](scripts/fishing.mjs) implements the reel deadline and basket transaction. Run `node --test scripts/fishing.test.mjs` from this folder. The example hands cooking a raw fish in a reserved slot. Adapt that slot to the game's inventory. Call the deadline check on each tick even without input.

## Check in play

Cast by a bank and under a bridge. Compare the first and final rods with the same fish. Miss a bite, pause during another, reload with a full basket and press Keep twice. Check the visible swimmer, best length, rewards and kitchen against the saved state.

---

Copyright (c) 2026 Meng To

The license files are attached. [MIT](https://knowen.md/f/3c02f208-fea4-4055-a09c-593a4f764a38)

The attached ZIP contains the pinned supporting files and applicable license notices.