Refactors the list datatype to support composite lists. Adapts a lot of circuits to be able to properly use composite lists. Adds the dispenser shell (#61856)

Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>
Co-authored-by: Colovorat <35225170+Colovorat@users.noreply.github.com>
This commit is contained in:
Watermelon914
2021-10-06 22:51:36 -07:00
committed by GitHub
co-authored by Watermelon914 Colovorat
parent 001315f214
commit d15b305527
52 changed files with 966 additions and 300 deletions
+3 -3
View File
@@ -75,9 +75,9 @@
name = "[lowertext(display_name)] [COMPONENT_DEFAULT_NAME]"
populate_options()
populate_ports()
if(circuit_flags & CIRCUIT_FLAG_INPUT_SIGNAL)
if((circuit_flags & CIRCUIT_FLAG_INPUT_SIGNAL) && !trigger_input)
trigger_input = add_input_port("Trigger", PORT_TYPE_SIGNAL, order = 2)
if(circuit_flags & CIRCUIT_FLAG_OUTPUT_SIGNAL)
if((circuit_flags & CIRCUIT_FLAG_OUTPUT_SIGNAL) && !trigger_output)
trigger_output = add_output_port("Triggered", PORT_TYPE_SIGNAL, order = 2)
if(circuit_flags & CIRCUIT_FLAG_INSTANT)
ui_color = "orange"
@@ -252,7 +252,7 @@
if(!cell?.use(power_usage_per_input))
return FALSE
if((circuit_flags & CIRCUIT_FLAG_INPUT_SIGNAL) && !COMPONENT_TRIGGERED_BY(trigger_input, port))
if((!port || port.trigger == .proc/input_received) && (circuit_flags & CIRCUIT_FLAG_INPUT_SIGNAL) && !COMPONENT_TRIGGERED_BY(trigger_input, port))
return FALSE
return TRUE