Look for optic_lens_emit group instead of explicit
lens_on node, to support multiple lens beam emitting
nodes (e.g. glued/unglued) for firestarting, door
ablation, etc.
Lenses enter a "glowing" state to propagate signal
immediately as before, but now they don't actually
produce light until powered steadily for 2 seconds.
This should mitigate the risk of "strobe" circuits that
cause excess lighting recalculations and irritate some
sensitive players.
The old system effectively cached cross-block
boundary information forever and never expired
them, even if the node creating them was
removed (that would have been easy to fix) or
an obstacle placed in the path (that would have
been difficult to fix with the old method).
Instead just do the simplest thing and split this
into a separate loop, and run a 2-second DNT with
a separate forward-trace from all active optic
nodes.
Doing a second forward trace for each node output
may not be as efficient but ultimately we create more
problems than we solve when we try to be too clever.
Apparently as oilboi pointed out, node metadata
is kinda gross, and in this case we didn't actually
need it, since the information could actually
always have been inferred from the nodes
themselves.
Instead of storing output state in node meta,
just register a callback on the node definition to
interrogate the node itself about its power output.
- Lenses no longer produce light from sun at all;
artificial light is always needed.
- Grass and trees survive, don't do dual-time check.
- Breeze sounds work in twilight.
- Sponge drying only requires twilight, now also can
happen under artificial light.
- Peat to grass happens under twilight.
Lenses work from sunlight up to roughly y = -10.
You can now have unlimited optic power from the sun,
but conducting it all the way down from the surface is
more of a pain than having a loop at depth.
- No day/night cycle, no sun/moon.
- Get rid of clouds too.
- Skybox is now 100% texture-packable.
- Natural light diminishes with depth.
Night-time no longer disrupts gameplay topside, but
skylights are no longer useful to an infinite depth and
artificial light is necessary for all deep mining.
Prefer shining state when fed from below even if given
sunlight above. This should make open-air circuits
easier to build and less likely to act up under sunlight.
The sunlight_propagates flag indicates that a node
can MOSTLY transmit light, like wooden frames, items,
or torches, but there are no purely transparent things
that are flammable, and all existing flammable things
are at least opaque at their centers, where lens light
would focus.
When lenses face one another and are each fed light to
become active, they now prefer the active state over the
shining state.
Interestingly, inline vs. angled configurations have different
numbers of stable configurations...
It's barely usable/playable.
I'm not happy with how disjoint it is from the existing crafting
system, for little gain; there's a lot of on_nodepunch logic that
was added for this.
It also doesn't play very well. Major issues:
- Awkward collision with existing logic, e.g. taking things from
shelves, then drawing on side of shelf. Probably need a group
specifically for writable sufaces.
- Single action to rotate through all glyphs is bad. Probably
want one to change through the 8 shapes, and another to change
rotation/reflection.
- Erasure is awkward, inconsistent, and not necessarily reliable.
Should make it possible to recover charcoal in most cases, and
use a unified set of hooks for it...
Should glyphs be pointable and run logic directly on node, or
should we keep it point-through...?
- Expanded fire api, added "check" varieties of things that also
perform relevant checks for eligibility. Standardized testing
for ventilation.
- Snuff embers to coals as fuel.
- Fuel is consumed randomly by flames. This means that fuel that
are surrounded by flame burn out quicker, while flames
surrounded by fuel consume fuel from each node slower. This
adds subtlety to furnace design for efficiency.
- Clean up registered_* usage patterns.
- Reduce tendancy of leaves to create stack nodes.
Now they tend to stack up properly in-world more often.
- Tweak damage system to create "headroom" where minor
damage doesn't cost inv slots immediately.
- Make player hand skin color match model skin.
- Cleanup/unify grass abm logic.
- Start installing new sounds by MagikEh
Sound source:
https://github.com/MagikEh/SoundsOfWarr
- Make lens not flicker with light level dithering by using
histerisis in threshold.
- Optical nodes always read the past world snapshot for creating
the next snapshot, so there are no accidental fast paths
through optical logic leading to glitches (hopefully).
There seems to be an issue triggering events, so a lot of work
is being done by the abm to cover over this problem...
Much like my earlier work with sz_rotary, I suspect a lot of
fine-tuning will be needed.