Integrated Circuitry

by judos

Status bars, compact-combinators to hide your gigantic circuitry inside a 2x2 entity with has 12 io-ports, circuit-poles, optimized lamps for displays. (All UPS friendly)

Content
4 years ago
0.15 - 0.18
54
Circuit network

b crash on deconstruct [fixed in 0.18.0]

4 years ago
(updated 4 years ago)

This mod has a lot of potential, thank you! I just ran into a crash when I tried putting some notes/sign posts inside the circuit (using ptx0's Attach Notes for 0.18 mod). Creating the circuit is fine, but deconstructing it crashes game. Game also crashes if I put one of your status bars inside and deconstruct:

The mod Integrated Circuitry (0.1.8) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event integratedCircuitry::on_pre_player_mined_item (ID 11)
Unknown item name: ic-status-panel-sprite
stack traceback:
integratedCircuitry/control/compact-combinator.lua:208: in function 'premine'
integratedCircuitry/libs/control/entities.lua:303: in function 'entities_pre_mined'
integratedCircuitry/control.lua:87: in function <integratedCircuitry/control.lua:86>
stack traceback:
[C]: in function 'insert'
integratedCircuitry/control/compact-combinator.lua:208: in function 'premine'
integratedCircuitry/libs/control/entities.lua:303: in function 'entities_pre_mined'
integratedCircuitry/control.lua:87: in function <integratedCircuitry/control.lua:86>

4 years ago
(updated 4 years ago)

Not using ptx0's Attach Notes (as it caused errors in other mods I use) but I'm also getting a full crash from this mod when mining it.

<code>
496.991 Error MainLoop.cpp:1202: Exception at tick 2921400: The mod Integrated Circuitry (0.1.8) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event integratedCircuitry::on_pre_player_mined_item (ID 11)
Unknown item name: hiddenlight-16
stack traceback:
integratedCircuitry/control/compact-combinator.lua:208: in function 'premine'
integratedCircuitry/libs/control/entities.lua:303: in function 'entities_pre_mined'
integratedCircuitry/control.lua:87: in function <integratedCircuitry/control.lua:86>
stack traceback:
[C]: in function 'insert'
integratedCircuitry/control/compact-combinator.lua:208: in function 'premine'
integratedCircuitry/libs/control/entities.lua:303: in function 'entities_pre_mined'
integratedCircuitry/control.lua:87: in function <integratedCircuitry/control.lua:86>
</code>

4 years ago
(updated 4 years ago)

In my case the hiddenlight-16 is created by Inbuilt Lighting as a hidden entity created when a power pole is built. Your circuit pole counts. The hiddenlight doesn't have an item and should just be destroyed.

4 years ago

Ok quick fix works on my end. In control\compact-combinator.lua starting at line 208 I added a test to check if the item being placed into the players inventory is nil. I added another line at the end of the block to close out the if.

<snippet lines 208-216>
if game.item_prototypes[item] ~= nil then -- ADDED BY SIDELIA
local inserted = player and player.get_main_inventory().insert{name=item, count=count} or 0
itemsReceived = itemsReceived + count
if inserted < count then
allReceived = false
local remaining = count - inserted
entity.surface.spill_item_stack(entity.position, {name=item, count=remaining}, true, player and nil or entity.force, false)
end
end -- ADDED BY SIDELIA
</snippet>

4 years ago

Thanks for the report.
My code was plain wrong. For every entity it tried to give you an item with the same name as the entity. However no entity is required to have an item with the same name.
Will be fixed with 0.18.0 (soon to be released)

New response