Shift-drag draws a line for belts and other transport pieces

Belts, filters, screw conveyors, shafts and pipe pieces never fill a rectangle;
a diagonal belt drag stays sloped with Shift held.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-26 23:27:06 -04:00
co-authored by Claude Opus 5.5
parent 664e086969
commit 18528a7f73
10 changed files with 36 additions and 12 deletions
+2
View File
@@ -32,6 +32,8 @@ function slopeCode(dx, dy, orientation) {
return dx * dy > 0 ? (orientation >= 2 ? BP_SLOPE_TR : BP_SLOPE_BL) : (orientation >= 2 ? BP_SLOPE_TL : BP_SLOPE_BR);
}
function isPipeCode(c) { return c === BP_PIPE || c === BP_PUMP || c === BP_OUTLET; }
// pieces that carry something along a run: a Shift-drag still draws a line, never a filled rectangle
function lineOnly(c) { return isBelt(c) || isFilter(c) || c === BP_SCREW || c === BP_SHAFT || isPipeCode(c); }
// Filters: each filter block has a set of materials and a mode. In drop mode (inv 0)
// the chosen materials fall through and everything else rides along on top; in carry
// mode (inv 1) the chosen ones ride along and everything else falls through. The block