Revert to flexible flood-fill scanning with geometric chevron placement
The exact-template approach from the last commit over-fit to the sample ASCII diagram, which was meant to teach the target shape, not be matched literally cell-for-cell. Back to flood-filling any connected, fully-enclosed ring the builder makes (any size/shape), but chevrons are no longer evenly spaced by scan order - the scanner walks the ring in geometric order and marks local maxima of distance from the interior's centroid, i.e. the blocks that stick out further than their ring-neighbours. That's where a real Stargate's chevrons sit (the 11-wide reference ring naturally produces 7 this way: the top apex, four shoulder elbows, two side bumps), without hardcoding a specific size. Falls back to the old evenly-spaced picker only if the ring isn't a simple single-thickness loop (each frame block should have exactly two in-plane neighbours) so odd/thick builds still work. gate.max-frame-blocks/max-iris-blocks/min-frame-blocks are back; gate.template is gone.
This commit is contained in:
@@ -26,38 +26,29 @@ cross-server:
|
||||
enabled: false
|
||||
|
||||
gate:
|
||||
# The exact shape of a gate, read top row to bottom row. This is matched precisely
|
||||
# against the world - no flood-fill guessing. Symbols:
|
||||
# * = frame block (never touched by the plugin)
|
||||
# 1 = chevron - a frame block that lights up to chevron-lit-material while
|
||||
# dialing/open, then reverts to whatever it looked like at rest when closed
|
||||
# 2 = interior ("iris") - filled with iris-material while open, air while closed
|
||||
# 0 = ignored - not part of the gate at all
|
||||
# Must be built in a single vertical plane, one block thick, aligned to the world's
|
||||
# X or Z axis (i.e. facing north/south/east/west, not built at an angle).
|
||||
template:
|
||||
- "00000000000"
|
||||
- "0000*1*0000"
|
||||
- "00012221000"
|
||||
- "00*22222*00"
|
||||
- "0*2222222*0"
|
||||
- "01222222210"
|
||||
- "0*2222222*0"
|
||||
- "00*22222*00"
|
||||
- "00012221000"
|
||||
- "0000***0000"
|
||||
- "00000000000"
|
||||
# Any of these materials satisfy a '*' or '1' cell above. Mix and match to match your
|
||||
# build (the default matches an obsidian/gilded-blackstone ring).
|
||||
# Any of these materials count as the ring's frame (and count as a valid chevron
|
||||
# material too, since chevrons are just frame blocks the plugin temporarily swaps).
|
||||
# Mix and match to match your build (the default matches an obsidian/gilded-blackstone
|
||||
# ring). The ring can be any size or shape, as long as it's a single connected loop
|
||||
# made only of these materials with a fully sealed hollow interior - no fixed template
|
||||
# or size is required.
|
||||
frame-materials:
|
||||
- OBSIDIAN
|
||||
- GOLD_BLOCK
|
||||
- GILDED_BLACKSTONE
|
||||
- BIRCH_PLANKS
|
||||
- OAK_PLANKS
|
||||
# Chevrons aren't a separate material you place. The plugin flood-fills the ring,
|
||||
# walks it in geometric order, and picks out the blocks that stick further outward
|
||||
# than their ring-neighbours - the "elbow" points of the shape, same as a real
|
||||
# Stargate's chevron placement - then swaps just those to chevron-lit-material while
|
||||
# dialing/open, restoring whatever they looked like at rest when the gate closes.
|
||||
chevron-lit-material: GILDED_BLACKSTONE
|
||||
# Material poured into the interior (the "event horizon") while the gate is open.
|
||||
iris-material: WATER
|
||||
max-frame-blocks: 300
|
||||
max-iris-blocks: 200
|
||||
min-frame-blocks: 8
|
||||
# After placing a "[Stargate]" sign, the owner has this long to left-click (punch) a
|
||||
# block of the actual gate frame to link it - the sign itself can sit anywhere, like a
|
||||
# DHD console away from the gate, instead of being mounted directly on the frame.
|
||||
|
||||
Reference in New Issue
Block a user