update logic functions to remove metatable OOP

This commit is contained in:
Redo
2020-09-10 12:58:25 -05:00
parent 4095d193ff
commit ab19de7333
206 changed files with 22726 additions and 3544 deletions

View File

@@ -23,16 +23,16 @@ datablock fxDtsBrickData(LogicGate_Buffer4_Data){
logicInput = "";
logicUpdate =
"return function(gate) " @
" if gate.ports[9].state then " @
" gate.ports[5]:setstate(gate.ports[1].state) " @
" gate.ports[6]:setstate(gate.ports[2].state) " @
" gate.ports[7]:setstate(gate.ports[3].state) " @
" gate.ports[8]:setstate(gate.ports[4].state) " @
" if Gate.getportstate(gate, 9) then " @
" Gate.setportstate(gate, 5, Gate.getportstate(gate, 1)) " @
" Gate.setportstate(gate, 6, Gate.getportstate(gate, 2)) " @
" Gate.setportstate(gate, 7, Gate.getportstate(gate, 3)) " @
" Gate.setportstate(gate, 8, Gate.getportstate(gate, 4)) " @
" else " @
" gate.ports[5]:setstate(false) " @
" gate.ports[6]:setstate(false) " @
" gate.ports[7]:setstate(false) " @
" gate.ports[8]:setstate(false) " @
" Gate.setportstate(gate, 5, false) " @
" Gate.setportstate(gate, 6, false) " @
" Gate.setportstate(gate, 7, false) " @
" Gate.setportstate(gate, 8, false) " @
" end " @
"end"
;