Fix door electronics configurator usage (#26888)

* allow usage of network configurator for door electronics

* add checks for "allowed" items
This commit is contained in:
Jark255
2024-04-11 15:21:15 +03:00
committed by GitHub
parent 9eb1e12022
commit 2bcdb608a3
4 changed files with 18 additions and 5 deletions

View File

@@ -93,6 +93,9 @@ public sealed partial class ActivatableUISystem : EntitySystem
if (component.InHandsOnly) if (component.InHandsOnly)
return; return;
if (component.AllowedItems != null)
return;
args.Handled = InteractUI(args.User, uid, component); args.Handled = InteractUI(args.User, uid, component);
} }
@@ -104,6 +107,9 @@ public sealed partial class ActivatableUISystem : EntitySystem
if (component.RightClickOnly) if (component.RightClickOnly)
return; return;
if (component.AllowedItems != null)
return;
args.Handled = InteractUI(args.User, uid, component); args.Handled = InteractUI(args.User, uid, component);
} }

View File

@@ -18,7 +18,7 @@
key: enum.DoorElectronicsConfigurationUiKey.Key key: enum.DoorElectronicsConfigurationUiKey.Key
allowedItems: allowedItems:
tags: tags:
- Multitool - DoorElectronicsConfigurator
- type: UserInterface - type: UserInterface
interfaces: interfaces:
- key: enum.DoorElectronicsConfigurationUiKey.Key - key: enum.DoorElectronicsConfigurationUiKey.Key

View File

@@ -225,6 +225,7 @@
- type: Tag - type: Tag
tags: tags:
- Multitool - Multitool
- DoorElectronicsConfigurator
- type: PhysicalComposition - type: PhysicalComposition
materialComposition: materialComposition:
Steel: 100 Steel: 100
@@ -266,6 +267,9 @@
- type: ActivatableUI - type: ActivatableUI
key: enum.NetworkConfiguratorUiKey.List key: enum.NetworkConfiguratorUiKey.List
inHandsOnly: true inHandsOnly: true
- type: Tag
tags:
- DoorElectronicsConfigurator
- type: UserInterface - type: UserInterface
interfaces: interfaces:
- key: enum.NetworkConfiguratorUiKey.List - key: enum.NetworkConfiguratorUiKey.List
@@ -343,13 +347,13 @@
description: The rapid construction device can be used to quickly place and remove various station structures and fixtures. Requires compressed matter to function. description: The rapid construction device can be used to quickly place and remove various station structures and fixtures. Requires compressed matter to function.
components: components:
- type: RCD - type: RCD
availablePrototypes: availablePrototypes:
- WallSolid - WallSolid
- FloorSteel - FloorSteel
- Plating - Plating
- Catwalk - Catwalk
- Grille - Grille
- Window - Window
- WindowDirectional - WindowDirectional
- WindowReinforcedDirectional - WindowReinforcedDirectional
- ReinforcedWindow - ReinforcedWindow
@@ -398,7 +402,7 @@
- type: LimitedCharges - type: LimitedCharges
charges: 0 charges: 0
- type: RCD - type: RCD
availablePrototypes: availablePrototypes:
- WallSolid - WallSolid
- FloorSteel - FloorSteel
- Plating - Plating

View File

@@ -523,6 +523,9 @@
- type: Tag - type: Tag
id: DoorElectronics id: DoorElectronics
- type: Tag
id: DoorElectronicsConfigurator
- type: Tag - type: Tag
id: DrinkBottle id: DrinkBottle
@@ -1177,7 +1180,7 @@
- type: Tag - type: Tag
id: SuitEVA id: SuitEVA
- type: Tag - type: Tag
id: Sunglasses id: Sunglasses