feat(fishing): eleven methods over 66 spots, on the shared skilling clock #120
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/fishing"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Phase 2's fourth gathering skill. Eleven methods over 66 spots, nine tools, six
baits, the Angler's outfit, the Fishing Guild and barbarian fishing.
Full suite 4507 passed, zero failures (seed 1, fresh test database). Format,
compile --warnings-as-errors, Credo and Dialyzer all clean. The world boots.The three findings that outlive the branch
The roll period belongs to the METHOD. Third arrangement of one field and
the one that settles it. A small fishing net rolls every 6 ticks for shrimp and
every 2 for minnow — same item id, same tool row — which kills "the tool
owns it"; a harpoon rolls every 6 bronze or dragon, which kills "the skill owns
it". So
tickslives on the method andWorld.Fishing.tools_among/2stamps itonto the tool at lookup.
Contract.Skilling.best/2needed no change: toolssharing a method share a period, so
{factor, -period}falls through to factor.Cascade is a real mechanic and the wiki's own chart proves it. Raw shrimps
carry
high: 256— a certainty at 99 — and the published figure is 49.61%.The missing half is anchovies, rolled first at
(1 + 128) / 256 = 50.39%, and1 - 0.5039 = 0.4961exactly. Rolling independently would be wrong by a factorof two at the top of the curve and look perfectly right at the bottom, since
anchovies are not eligible until 15. Pinned by walking all 256 dice faces:
129 anchovies, 127 shrimp, none empty.
Contract.Skilling.interpolate/3truncates where the published formularounds — 902 of 2,178 mining combinations.
Contract.Fishingcarries its ownrounded interpolation over raw wiki parameters and reproduces every published
fishing figure checked against it. Woodcutting and mining are deliberately not
moved; that is #117, and the question to answer first is which rounding
mining's own charts were generated with.
Two corrections to what was written down
622 and 623 are the two halves of one animation, not two candidates for it.
623 is the pole held in the water (2 frames / 32 cycles), 622 the initial swing
(19 / 238). Three independently maintained symbol tables agree on 623 and the
cache's own frame shapes confirm it. The barbarian rod was on 622 with no
source and is now on 623 with three.
A fishing spot stands ON the water and is worked from the bank. Measured:
194 of the dump's own 197 are blocked, and the derivation's own validator — the
barbarian-rod tiles at
2500, 3504..3513— is blocked too. The prose said theopposite in three places; the derivation was right and only the sentence was
wrong, so "fixing" it would have moved 28 correct rows onto the shore. The test
now asserts reachability, not walkability — 30 of 30 against the dump's
196 of 197.
Tick manipulation
Fishing is the first of the three skills the skilling clock was waiting for
(Herblore, Cooking, Fishing), and it inherited the mechanic with no engine
change by being ordinary. Measured by driving the real loop a tick at a time:
All three are tests. What it exposed is that the delay items are thinner than
the real game's:
Production.start/4is the only:inventoryarm and isreached only when a recipe exists, so knife-and-teak — canonical precisely
because it makes nothing and never fills the pack — does nothing here at all.
Behavioural rather than structural, and it belongs to
Productionrather thanto fishing.
Fly fishing
Every one of this cache's 17
Lure/Baitdefinitions had zero spawns, sotrout, salmon, pike and rainbow fish were absent from the world entirely and the
skill had a hole from 20 to 58. Thirty rows across five areas fill it, derived
from the collision map rather than typed. The ids are ours and the assignment is
arbitrary because all 17 definitions are identical — which a test now asserts,
so it stays arbitrary. The durable fix for the whole class is #118:
Cache.MapSquarethrows the overlay id away and water is an overlay.Also in this branch
bait?gate inContract.Skilling's chain besidetool, because a rodwith no bait and no rod at all are the same class of problem — in the
contract so fishing cannot grow a second, differently ordered copy of the
gate order.
npc_spawns.exsa syntax error. A green suite missed it becausemix testwas reading a stale
_build/testcopy of the priv file.yield/3claimed to stop at the first fish that will not fit and did not, soa big net into a nearly-full pack said "You can't carry any more fish."
three times. Now a
reduce_while, with a test on the message count.Filed rather than folded in
Cache.MapSquarediscards the overlay id, so nothing can askwhether a tile is water.
World.Content.LightTestis seed-flaky, and it is not thisbranch's.
mix test --seed 12on that file alone fails, as do 15 and 20.Light.run/2rolls its own dice, ExUnit seeds:randfrom the run seed, andthe test needs a roll that fails only 191 times in 256. Adding any file
reshuffles the order and re-rolls the lottery, which is why it looked like
this branch's.
Not done
The live sitting, narrowed to five things: whether the rod's initial swing
is worth playing before the held pose; that the five fly-spot clusters render on
water rather than in a wall; that the catch lines read correctly; that the guild
door toggles the boost; and that a big net attempt visibly lands several fish at
once.
Declined with a reason each, in the table's own header: spot relocation (wants a
tile set nothing states), the single-fish bait spots, karambwan and karambwanji,
dark crab, minnow, and big net junk (rates published nowhere).