Moon Logic deprecated

by mk-fg

Adds Lua-programmable circuit network combinator. Based on Sandboxed LuaCombinator and LuaCombinator2 mods. Probably won't work in multiplayer games.

Content
2 years ago
1.0 - 1.1
4.97K
Circuit network

b [fixed] lua # operator not working for input/output tables

4 years ago

hi,

i noticed that the # function is not working on the red and green signal table.
I wrote a function to count the number of items that is working.

Demo: https://imgur.com/a/rt6gGPI

4 years ago

Yeah, can be changed to count non-zero signals, as an easy "are there any signals?" check.

Demo: https://imgur.com/a/rt6gGPI

Doesn't work in my browser, even with ublock/umatrix disabled, so not sure what is there.

4 years ago
(updated 4 years ago)

Added # in 0.0.39 for input and output tables, counting only non-zero signals there.

Note that if you use e.g. out.wood = #out, it can produce somewhat unintuitive result, as "out" table is persistent, and "wood" signal itself will be counted after being set when any other signal was present in that table, and will always be >=1 after that.

Thanks for reporting!

4 years ago

sorry, you can try this link:
https://imgur.com/UaTtXgL
don't know what happend there.

also, after update i get this error:
https://imgur.com/a/QIQB1nq
(in case you cant open again, it says:
RuntimeError: Moon_Logic/control.lua:79: [ENC Error] Forbidden global read:{key = "cn_wire_signal"}

4 years ago

https://imgur.com/UaTtXgL
https://imgur.com/a/QIQB1nq

Yeah, sorry, I think it's just imgur not working in my FF 68, and I was lazy to open it in another browser.
Doesn't seem to be a big deal, as issue seem to be understandable anyway, but should've clarified.

And my bad on the error, changed function there to a wrong name and forgot to test it. Should be fixed in 0.0.40.

4 years ago

seems to be working. Thank you :)

New response