Piping angle fixes (#3442)
* Moves piping prototypes to own folder * Fixes pipe direction angles
This commit is contained in:
@@ -77,10 +77,10 @@ namespace Content.Shared.GameObjects.Components.Atmos
|
|||||||
{
|
{
|
||||||
return shape switch
|
return shape switch
|
||||||
{
|
{
|
||||||
PipeShape.Half => PipeDirection.East,
|
PipeShape.Half => PipeDirection.South,
|
||||||
PipeShape.Straight => PipeDirection.Lateral,
|
PipeShape.Straight => PipeDirection.Longitudinal,
|
||||||
PipeShape.Bend => PipeDirection.SEBend,
|
PipeShape.Bend => PipeDirection.SWBend,
|
||||||
PipeShape.TJunction => PipeDirection.TEast,
|
PipeShape.TJunction => PipeDirection.TSouth,
|
||||||
PipeShape.Fourway => PipeDirection.Fourway,
|
PipeShape.Fourway => PipeDirection.Fourway,
|
||||||
_ => throw new ArgumentOutOfRangeException(nameof(shape), $"{shape} does not have an associated {nameof(PipeDirection)}."),
|
_ => throw new ArgumentOutOfRangeException(nameof(shape), $"{shape} does not have an associated {nameof(PipeDirection)}."),
|
||||||
};
|
};
|
||||||
@@ -98,14 +98,7 @@ namespace Content.Shared.GameObjects.Components.Atmos
|
|||||||
|
|
||||||
public static Angle ToAngle(this PipeDirection pipeDirection)
|
public static Angle ToAngle(this PipeDirection pipeDirection)
|
||||||
{
|
{
|
||||||
return pipeDirection switch
|
return pipeDirection.ToDirection().ToAngle();
|
||||||
{
|
|
||||||
PipeDirection.East => Angle.FromDegrees(0),
|
|
||||||
PipeDirection.North => Angle.FromDegrees(90),
|
|
||||||
PipeDirection.West => Angle.FromDegrees(180),
|
|
||||||
PipeDirection.South => Angle.FromDegrees(270),
|
|
||||||
_ => throw new ArgumentOutOfRangeException(nameof(pipeDirection), $"{pipeDirection} does not have an associated angle."),
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static PipeDirection ToPipeDirection(this Direction direction)
|
public static PipeDirection ToPipeDirection(this Direction direction)
|
||||||
|
|||||||
@@ -40,4 +40,4 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: East
|
pipeDirection: South
|
||||||
@@ -39,16 +39,16 @@
|
|||||||
components:
|
components:
|
||||||
- type: NodeContainer
|
- type: NodeContainer
|
||||||
nodes:
|
nodes:
|
||||||
|
- !type:PipeNode
|
||||||
|
nodeGroupID: Pipe
|
||||||
|
pipeDirection: West
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: South
|
pipeDirection: South
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: East
|
pipeDirection: East
|
||||||
- !type:PipeNode
|
|
||||||
nodeGroupID: Pipe
|
|
||||||
pipeDirection: North
|
|
||||||
- type: GasFilter
|
- type: GasFilter
|
||||||
inletDirection: South
|
inletDirection: West
|
||||||
filterOutletDirection: East
|
filterOutletDirection: South
|
||||||
outletDirection: North
|
outletDirection: East
|
||||||
@@ -40,7 +40,7 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: East
|
pipeDirection: South
|
||||||
- type: Icon
|
- type: Icon
|
||||||
state: pipeHalf
|
state: pipeHalf
|
||||||
|
|
||||||
@@ -53,7 +53,7 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: Lateral
|
pipeDirection: Longitudinal
|
||||||
- type: Icon
|
- type: Icon
|
||||||
state: pipeStraight
|
state: pipeStraight
|
||||||
|
|
||||||
@@ -66,7 +66,7 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: SEBend
|
pipeDirection: SWBend
|
||||||
- type: Icon
|
- type: Icon
|
||||||
state: pipeBend
|
state: pipeBend
|
||||||
|
|
||||||
@@ -79,7 +79,7 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: TEast
|
pipeDirection: TSouth
|
||||||
- type: Icon
|
- type: Icon
|
||||||
state: pipeTJunction
|
state: pipeTJunction
|
||||||
|
|
||||||
@@ -40,10 +40,10 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: West
|
pipeDirection: North
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: East
|
pipeDirection: South
|
||||||
- type: PressurePump
|
- type: PressurePump
|
||||||
inletDirection: West
|
inletDirection: North
|
||||||
outletDirection: East
|
outletDirection: South
|
||||||
@@ -41,6 +41,6 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: East
|
pipeDirection: South
|
||||||
- type: PressureSiphon
|
- type: PressureSiphon
|
||||||
scrubberOutletDirection: East
|
scrubberOutletDirection: South
|
||||||
@@ -41,6 +41,6 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- !type:PipeNode
|
- !type:PipeNode
|
||||||
nodeGroupID: Pipe
|
nodeGroupID: Pipe
|
||||||
pipeDirection: East
|
pipeDirection: South
|
||||||
- type: PressureVent
|
- type: PressureVent
|
||||||
ventInletDirection: East
|
ventInletDirection: South
|
||||||
Reference in New Issue
Block a user