Thank you Wayne, but the bug persists. I inserted your two ctx code lines in the prototype, around the existing this... code line.
The bug is that after the demo.nod is saved, when the demo.nod is reloaded, the NC output dot, and the output dot below it,
appear as numarrays, teal in color. (Yet the two gold wires are still connected to them.) The SwDPDT works initially, but the two numarray outputs
do not act as gold objects.
- Brian
It seems odd that Max's code for Switch, works fine on reload, but the modified code does not.
Maybe check some other node with two or three outputs?
For another node, I tried doing a "push button" "rotary" switch, with one output, and several inputs, sequentially individually connected to the output by mouse click,
but code would need some major alterations, not to mention understanding the existing code. The button option would probably not be appropriated for rotary.
Not a very standard switch. Maybe call it SinglePole4Throw? SP4T or SP5T, etc.?
|