Make electrocutions look nicer on the power monitor. (#16965)
This commit is contained in:
committed by
GitHub
parent
66aa0969ba
commit
042d3437e3
@@ -323,6 +323,10 @@ public sealed class ElectrocutionSystem : SharedElectrocutionSystem
|
|||||||
var electrocutionNode = Comp<NodeContainerComponent>(electrocutionEntity).GetNode<ElectrocutionNode>("electrocution");
|
var electrocutionNode = Comp<NodeContainerComponent>(electrocutionEntity).GetNode<ElectrocutionNode>("electrocution");
|
||||||
var electrocutionComponent = Comp<ElectrocutionComponent>(electrocutionEntity);
|
var electrocutionComponent = Comp<ElectrocutionComponent>(electrocutionEntity);
|
||||||
|
|
||||||
|
// This shows up in the power monitor.
|
||||||
|
// Yes. Yes exactly.
|
||||||
|
MetaData(electrocutionEntity).EntityName = MetaData(uid).EntityName;
|
||||||
|
|
||||||
electrocutionNode.CableEntity = sourceUid;
|
electrocutionNode.CableEntity = sourceUid;
|
||||||
electrocutionNode.NodeName = node.Name;
|
electrocutionNode.NodeName = node.Name;
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,17 @@
|
|||||||
# Special entity used to attach to power networks as load when somebody gets electrocuted.
|
# Special entity used to attach to power networks as load when somebody gets electrocuted.
|
||||||
|
- type: entity
|
||||||
|
id: VirtualElectrocutionLoadBase
|
||||||
|
noSpawn: true
|
||||||
|
components:
|
||||||
|
- type: Electrocution
|
||||||
|
- type: Icon
|
||||||
|
# Shows up inside the power monitoring console.
|
||||||
|
sprite: "Structures/Wallmounts/signs.rsi"
|
||||||
|
state: "shock"
|
||||||
|
|
||||||
- type: entity
|
- type: entity
|
||||||
id: VirtualElectrocutionLoadHVPower
|
id: VirtualElectrocutionLoadHVPower
|
||||||
name: ELECTROCUTION ENTITY YOU SHOULD NOT SEE THIS
|
parent: VirtualElectrocutionLoadBase
|
||||||
noSpawn: true
|
noSpawn: true
|
||||||
components:
|
components:
|
||||||
- type: NodeContainer
|
- type: NodeContainer
|
||||||
@@ -12,11 +22,10 @@
|
|||||||
- type: PowerConsumer
|
- type: PowerConsumer
|
||||||
voltage: High
|
voltage: High
|
||||||
drawRate: 50000
|
drawRate: 50000
|
||||||
- type: Electrocution
|
|
||||||
|
|
||||||
- type: entity
|
- type: entity
|
||||||
id: VirtualElectrocutionLoadMVPower
|
id: VirtualElectrocutionLoadMVPower
|
||||||
name: ELECTROCUTION ENTITY YOU SHOULD NOT SEE THIS
|
parent: VirtualElectrocutionLoadBase
|
||||||
noSpawn: true
|
noSpawn: true
|
||||||
components:
|
components:
|
||||||
- type: NodeContainer
|
- type: NodeContainer
|
||||||
@@ -27,11 +36,10 @@
|
|||||||
- type: PowerConsumer
|
- type: PowerConsumer
|
||||||
voltage: Medium
|
voltage: Medium
|
||||||
drawRate: 50000
|
drawRate: 50000
|
||||||
- type: Electrocution
|
|
||||||
|
|
||||||
- type: entity
|
- type: entity
|
||||||
id: VirtualElectrocutionLoadApc
|
id: VirtualElectrocutionLoadApc
|
||||||
name: ELECTROCUTION ENTITY YOU SHOULD NOT SEE THIS
|
parent: VirtualElectrocutionLoadBase
|
||||||
noSpawn: true
|
noSpawn: true
|
||||||
components:
|
components:
|
||||||
- type: NodeContainer
|
- type: NodeContainer
|
||||||
@@ -42,4 +50,3 @@
|
|||||||
- type: PowerConsumer
|
- type: PowerConsumer
|
||||||
voltage: Apc
|
voltage: Apc
|
||||||
drawRate: 50000
|
drawRate: 50000
|
||||||
- type: Electrocution
|
|
||||||
|
|||||||
Reference in New Issue
Block a user