make linking logic gates 1000% better (#25041)

* make door status use SendSignal

* LastSignals and logic, add ClearSignal api too

* make everything outputting a logic signal default to false

* refactor ops

* :trollface:

* :trollface:

* protoid for LastSignals

* oop

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
This commit is contained in:
deltanedas
2024-02-12 06:45:51 +00:00
committed by GitHub
parent 16b56c7f45
commit f41ece37c3
12 changed files with 146 additions and 68 deletions

View File

@@ -95,6 +95,8 @@
- type: DeviceLinkSource
ports:
- DoorStatus
lastSignals:
DoorStatus: false
- type: SoundOnOverload
- type: SpawnOnOverload
- type: UserInterface

View File

@@ -90,6 +90,8 @@
- type: DeviceLinkSource
ports:
- DoorStatus
lastSignals:
DoorStatus: false
- type: InteractionPopup
interactSuccessString: comp-window-knock
messagePerceivedByOthers: comp-window-knock

View File

@@ -59,6 +59,8 @@
- type: DeviceLinkSource
ports:
- DoorStatus
lastSignals:
DoorStatus: false
- type: Damageable
damageContainer: Inorganic
damageModifierSet: Glass

View File

@@ -30,6 +30,10 @@
- AirDanger
- AirWarning
- AirNormal
lastSignals:
AirDanger: false
AirWarning: false
AirNormal: false
- type: AtmosAlarmable
syncWith:
- AirAlarm

View File

@@ -34,6 +34,8 @@
- On
- Off
- Status
lastSignals:
Status: false
- type: entity
id: SignalButton

View File

@@ -34,6 +34,8 @@
- type: DeviceLinkSource
ports:
- Output
lastSignals:
Output: false
- type: Construction
graph: LogicGate
node: logic_gate
@@ -65,6 +67,9 @@
ports:
- OutputHigh
- OutputLow
lastSignals:
OutputHigh: false
OutputLow: false
- type: Construction
graph: LogicGate
node: edge_detector
@@ -108,6 +113,9 @@
ports:
- PowerCharging
- PowerDischarging
lastSignals:
PowerCharging: false
PowerDischarging: false
- type: Construction
graph: LogicGate
node: power_sensor