Wall drags at 45° lay slopes; diagonal tubes drawn as one pipe; no side arrow on drag ghosts (t35, t36)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+14
-6
@@ -677,14 +677,17 @@ with sync_playwright() as p:
|
||||
check('bot cannot sit inside natural rock', ev(f'botOverlapSolid({bx}, {gy + 12})'))
|
||||
|
||||
# Slopes use the same mouse drag path as walls, with T for their corner.
|
||||
pg.click('[data-piece="slope"]'); settle(60)
|
||||
check('Sloped wall is next to Wall in the build menu', ev("piece().id === 'slope' && BUILD_CATS[0][1].slice(0,2).join(',') === 'wall,slope'"))
|
||||
ev('GAME.wallMat = RSTONE; GAME.pieceDir.slope = 0')
|
||||
pg.click('[data-piece="wall"]'); settle(60)
|
||||
check('Wall replaces the Sloped wall menu piece', ev("piece().id === 'wall' && !BUILD_ORDER.includes('slope') && !document.querySelector('[data-piece=\"slope\"]')"))
|
||||
ev('GAME.wallMat = RSTONE; GAME.pieceDir.wall = 0')
|
||||
drag(lambda: blk(bbx - 5, bby - 12), lambda: blk(bbx - 2, bby - 9))
|
||||
check('diagonal slope drag places four oriented blocks', ev(f'Array.from({{length:4}}, (_,k)=>blockP[({bby}-12+k)*BW+{bbx}-5+k]).every(c=>c===BP_SLOPE_BL)'))
|
||||
pg.keyboard.press('Control+z'); settle(60)
|
||||
pg.keyboard.press('t'); settle(60)
|
||||
check('T cycles the single slope corner', ev('GAME.pieceDir.slope === 1'))
|
||||
check('T cycles the single slope corner', ev('GAME.pieceDir.wall === 1 && pieceCode(piece()) === BP_SLOPE_BL'))
|
||||
for shape in [2, 3, 4, 0]:
|
||||
pg.keyboard.press('t'); settle(40)
|
||||
check(f'T cycles Wall shape {shape}', ev(f'GAME.pieceDir.wall === {shape} && pieceCode(piece()) === ' + ('BP_WALL' if shape == 0 else f'BP_SLOPE_BL+{shape}-1')))
|
||||
pg.mouse.move(*blk(bbx - 5, bby - 12)); settle(60); pg.mouse.down()
|
||||
pg.mouse.move(*blk(bbx - 2, bby - 9)); settle(60)
|
||||
pg.keyboard.press('t'); settle(60); pg.mouse.up(); settle(60)
|
||||
@@ -692,7 +695,7 @@ with sync_playwright() as p:
|
||||
pg.keyboard.press('Control+z'); settle(60)
|
||||
pg.click('[data-piece="wall"]'); settle(60)
|
||||
drag(lambda: blk(bbx - 5, bby - 12), lambda: blk(bbx - 2, bby - 9))
|
||||
check('square wall drag can also place a diagonal', ev(f'Array.from({{length:4}}, (_,k)=>blockP[({bby}-12+k)*BW+{bbx}-5+k]).every(c=>c===BP_WALL)'))
|
||||
check('Wall diagonal defaults back to solid below', ev(f'Array.from({{length:4}}, (_,k)=>blockP[({bby}-12+k)*BW+{bbx}-5+k]).every(c=>c===BP_SLOPE_BL)'))
|
||||
pg.keyboard.press('Control+z'); settle(60)
|
||||
|
||||
# Diagonal tubes use real mouse placement, preview arrows, R and picking.
|
||||
@@ -732,12 +735,17 @@ with sync_playwright() as p:
|
||||
check('three bars drop below the mold without F', ev('ents.every(e => e.m === BARCU && e.iy >= molds[0].y + molds[0].h)'), ev('ents.map(e => [e.ix, e.iy])'))
|
||||
pg.keyboard.press('2'); settle(60)
|
||||
ev("GAME.status = ''; GAME.statusT = 0")
|
||||
pg.mouse.move(*cell_to_screen(ev('molds[0].x') + 3, ev('molds[0].y') + 3)); settle(150)
|
||||
# Keep the camera still while aiming at a mold only four grains tall.
|
||||
lead = ev('SET.cameraLead')
|
||||
ev('SET.cameraLead = false; snapCamera()'); settle(100)
|
||||
pg.mouse.move(*cell_to_screen(ev('molds[0].x') + 8, ev('molds[0].y') + 2)); settle(150)
|
||||
check('mouse aims at the automatic ingot mold', ev('moldAt(Math.floor(GAME.aim.x), Math.floor(GAME.aim.y)) === molds[0]'))
|
||||
# count toasts made by the key press itself: counting the ones on screen also caught an older toast expiring
|
||||
ev("window._toastsMade = []; window._toastFn = toast; toast = function (t, o) { _toastsMade.push(t); return _toastFn(t, o); }; 0")
|
||||
pg.keyboard.press('f'); settle(150)
|
||||
made = ev("(() => { toast = _toastFn; return _toastsMade; })()")
|
||||
check('F on an automatic ingot mold stays quiet without a toast', ev("$('m-dialog').hidden") and made == [], made)
|
||||
ev(f'SET.cameraLead = {json.dumps(lead)}')
|
||||
ev("closeModal('m-dialog')")
|
||||
check('F with vacuum still uses what is in reach', ev("""(() => {
|
||||
$('toasts').innerHTML = '';
|
||||
|
||||
Reference in New Issue
Block a user