## About The Pull Request
In `shell.dm`:
When immobile shells were unsecured it would just directly set
`attached_circuit.on` to whatever the shell anchor state was, which
bypassed sending the signal `set_on()` sends. By instead using
`attached_circuit.set_on()` this state change should actually propagate
to the inner modules, rather than say letting an inner module with a
clock run regardless of the shell's anchor state.
Similarly, adding a circuit to an unsecured immobile shell would try to
set `attached_circuit.on` to the shell anchor state, but in addition to
not propagating to inner modules this simply did not work because the
`attached_circuit.set_shell(parent_atom)` called later would set it to
be on anyway. We resolve this by just, moving the state change until
*after* set_shell.
Finally removes the `attached_circuit.on = TRUE` from the
`remove_circuit()` proc, because
`attached_circuit.remove_current_shell()` immediately sets this to false
again anyway.
More related but separate bits probably tomorrow.
## Why It's Good For The Game
Makes immobile shells actually work only when anchored, and resolved
some related jank.
## Changelog
🆑
fix: Immobile shells no longer work regardless of anchor state if you
put the circuit in while it's unanchored.
fix: Immobile shells properly propagate their on/off state after
wrenching to inner modules.
/🆑
Loosely adapted from /vg/. This is an entity component system for adding behaviours to datums when inheritance doesn't quite cut it. By using signals and events instead of direct inheritance, you can inject behaviours without hacky overloads. It requires a different method of thinking, but is not hard to use correctly. If a behaviour can have application across more than one thing. Make it generic, make it a component. Atom/mob/obj event? Give it a signal, and forward it's arguments with a SendSignal() call. Now every component that want's to can also know about this happening.