make sim global; make nonessential queues optional

This commit is contained in:
Redo0
2021-05-25 17:11:48 -05:00
parent 53e9423ab1
commit d25893566e
8 changed files with 99 additions and 78 deletions

View File

@@ -149,7 +149,7 @@ while 1 do
local max = vectotable(data[i+4])
local bounds = {min[1], min[2], min[3], max[1], max[2], max[3]}
local wire = Wire.new(Wire, tonumber(data[i+1]), tonumber(data[i+2]), bounds, sim)
local wire = Wire.new(Wire, tonumber(data[i+1]), tonumber(data[i+2]), bounds)
Simulation.addwire(sim, wire)
i = i + 4
@@ -161,12 +161,12 @@ while 1 do
local position = vectotable(data[i+3])
local rotation = tonumber(data[i+4])
local gate = GateDefinition.constructgate(definition, objref, position, rotation, sim)
local gate = GateDefinition.constructgate(definition, objref, position, rotation)
Simulation.addgate(sim, gate)
--print(gate.objref)
Gate.init(gate)
Gate.logic(gate)
--Gate.init(gate)
--Gate.logic(gate)
i = i + 4
elseif data[i] == "RW" then