Sticky materials slide freely on built surfaces (t61)
Stickiness gated every diagonal step, so clay lumps, snow, wood chunks, ash and dirt crawled down sloped walls (a clay grain never got down a 20-piece slope). It now applies only grain against grain: a grain resting on anything built always tries its diagonal step, so chutes carry every material while heaps keep their shape. The random draw is unchanged, so generated worlds stay the same. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -471,6 +471,12 @@ above, including:
|
||||
but make it about what's on screen, so anything the player can see and aim at builds directly
|
||||
and anything beyond stays a blueprint built when the bot comes near. No limit at all would let
|
||||
players build in places they've never been and link far claims instantly. Not built yet.
|
||||
- **Sticky materials slide freely on built surfaces (t61, 2026-10-27).** Stickiness (STICK) is the
|
||||
chance per tick a grain takes a diagonal step, which made clay lumps, snow, wood chunks, ash and
|
||||
dirt creep down sloped walls (a single clay grain never got down a 20-piece slope). The owner
|
||||
chose to make stickiness grain against grain only: on anything built, every material slides
|
||||
freely, so slopes are useful for every material, while heaps keep their shape. Real chutes clog
|
||||
with sticky material and need cleaning, but that is micromanagement the game doesn't need.
|
||||
|
||||
## Ideas not built yet
|
||||
|
||||
|
||||
@@ -4,6 +4,16 @@ What agents have done, newest first. Add an entry for every piece of work: the d
|
||||
note or request it was for, what changed, the files touched, the tests run, and anything left
|
||||
open or not verified. Keep each entry short; the git history has the details.
|
||||
|
||||
## 2026-10-27: t61 sticky materials slide freely on built surfaces (Claude Code)
|
||||
|
||||
- The owner's video showed clay lumps creeping down a sloped wall; removing a piece was
|
||||
unrelated. Cause: STICK gates every diagonal step, so cohesive materials crawl on 45°. In
|
||||
`powder()` (`src/sim/cells.js`) a grain resting on a built solid (not F_NAT) now always tries
|
||||
the diagonal; the random draw is unchanged, so generated worlds are identical.
|
||||
- Measured: a clay grain down a 20-piece built slope took 77 ticks, same as sand (before: never
|
||||
arrived in 2000 ticks). Heaps on a built floor and on natural ground are unchanged.
|
||||
- Test: `t_slopes.js` clay vs sand transit. `python3 test/run_all.py --browser`: ALL PASSED.
|
||||
|
||||
## 2026-10-27: Unremovable one-cell belt left after cutting slopes (Claude Code)
|
||||
|
||||
- The owner's exported save had a lone belt cell no block owned, so nothing could build there or
|
||||
|
||||
+3
-1
@@ -95,7 +95,9 @@ function powder(i, x, y, m, barriers = cleatChunks[(y >> 5) * CW + (x >> 5)]) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (rnd() < STICK[m]) {
|
||||
// stickiness is grain against grain: on anything built (a wall, a slope, a belt) every material
|
||||
// slides freely, so a chute carries clay as well as sand while clay heaps stay steep
|
||||
if (rnd() < STICK[m] || (PH[t] === PH_SOLID && !(flags[b] & F_NAT))) {
|
||||
const d = (RS & 2) ? 1 : -1;
|
||||
let nx = x + d;
|
||||
if (nx >= 0 && nx < W && (!CORNER_SEAL || (PH[mat[b]] !== PH_SOLID && (!barriers || !cleatMask[b])) || (PH[mat[i + d]] !== PH_SOLID && (!barriers || !cleatMask[i + d]))) && (!barriers || (!cleatMask[i] && !cleatMask[b + d])) && enterFree(m, PH_POWDER, b + d, d, 1)) { move(i, b + d, x, y, nx, y + 1); return; }
|
||||
|
||||
@@ -114,4 +114,9 @@ globalThis.legacySlopeSave = legacy;
|
||||
run('deserializeWorld(legacySlopeSave.meta,legacySlopeSave.buffers)');
|
||||
check('old save loads all four slope corners unchanged',run('Array.from({length:4},(_,k)=>{const b=6*BW+2+k*3;return blockP[b]===15+k && blockV[b]===RSTONE && blockIntegrity(b)===10 && PIECE_BY_CODE[blockP[b]].id===\'wall\';}).every(Boolean)'));
|
||||
delete globalThis.legacySlopeSave;
|
||||
// Stickiness is grain against grain: on a built slope sticky clay lumps run as fast as sand.
|
||||
const slide=m=>{flatWorld(run,256,224,208);run('for(let k=0;k<20;k++)placeBlock(BP_SLOPE_BL,RSTONE,10+k,10+k,true);');
|
||||
return run(`(()=>{setCell(39*W+42,${m},20,0);for(let t=0;t<2000;t++){simTick();for(let i=0;i<N;i++)if(mat[i]===${m}&&i%W>=118)return t;}return -1;})()`);};
|
||||
const sandT=slide('SAND'),clayT=slide('LCLAY');
|
||||
check('clay lumps slide down a built slope as fast as sand',clayT>0 && clayT<=sandT+4,JSON.stringify([sandT,clayT]));
|
||||
done();
|
||||
|
||||
Reference in New Issue
Block a user