Objects ordered through cargo system shouldn't start anchored (#28115)
* Order normal space heater instead of anchored variant * Make sure ordered objects don't spawn anchored * Order space heater flatpack instead of a regular space heater * Remove obsolete TODO * Remove unnecessary name --------- Co-authored-by: Eoin Mcloughlin <helloworld@eoinrul.es>
This commit is contained in:
@@ -20,6 +20,8 @@ namespace Content.Server.Cargo.Systems
|
|||||||
{
|
{
|
||||||
public sealed partial class CargoSystem
|
public sealed partial class CargoSystem
|
||||||
{
|
{
|
||||||
|
[Dependency] private readonly SharedTransformSystem _transformSystem = default!;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// How much time to wait (in seconds) before increasing bank accounts balance.
|
/// How much time to wait (in seconds) before increasing bank accounts balance.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -489,6 +491,9 @@ namespace Content.Server.Cargo.Systems
|
|||||||
// Create the item itself
|
// Create the item itself
|
||||||
var item = Spawn(order.ProductId, spawn);
|
var item = Spawn(order.ProductId, spawn);
|
||||||
|
|
||||||
|
// Ensure the item doesn't start anchored
|
||||||
|
_transformSystem.Unanchor(item, Transform(item));
|
||||||
|
|
||||||
// Create a sheet of paper to write the order details on
|
// Create a sheet of paper to write the order details on
|
||||||
var printed = EntityManager.SpawnEntity(paperProto, spawn);
|
var printed = EntityManager.SpawnEntity(paperProto, spawn);
|
||||||
if (TryComp<PaperComponent>(printed, out var paper))
|
if (TryComp<PaperComponent>(printed, out var paper))
|
||||||
|
|||||||
@@ -133,7 +133,7 @@
|
|||||||
icon:
|
icon:
|
||||||
sprite: Structures/Piping/Atmospherics/Portable/portable_sheater.rsi
|
sprite: Structures/Piping/Atmospherics/Portable/portable_sheater.rsi
|
||||||
state: sheaterOff
|
state: sheaterOff
|
||||||
product: SpaceHeaterAnchored
|
product: CrateEngineeringSpaceHeater
|
||||||
cost: 300
|
cost: 300
|
||||||
category: cargoproduct-category-name-engineering
|
category: cargoproduct-category-name-engineering
|
||||||
group: market
|
group: market
|
||||||
|
|||||||
@@ -194,3 +194,13 @@
|
|||||||
contents:
|
contents:
|
||||||
- id: WeaponParticleDecelerator
|
- id: WeaponParticleDecelerator
|
||||||
amount: 3
|
amount: 3
|
||||||
|
|
||||||
|
- type: entity
|
||||||
|
id: CrateEngineeringSpaceHeater
|
||||||
|
parent: CrateEngineering
|
||||||
|
name: space heater crate
|
||||||
|
description: Contains a space heater for climate control.
|
||||||
|
components:
|
||||||
|
- type: StorageFill
|
||||||
|
contents:
|
||||||
|
- id: SpaceHeaterFlatpack
|
||||||
|
|||||||
@@ -42,7 +42,7 @@
|
|||||||
components:
|
components:
|
||||||
- type: StorageFill
|
- type: StorageFill
|
||||||
contents:
|
contents:
|
||||||
- id: EmitterFlatpack # TODO change to flatpack
|
- id: EmitterFlatpack
|
||||||
|
|
||||||
- type: entity
|
- type: entity
|
||||||
id: CrateEngineeringSingularityCollector
|
id: CrateEngineeringSingularityCollector
|
||||||
|
|||||||
@@ -195,3 +195,12 @@
|
|||||||
- state: overlay
|
- state: overlay
|
||||||
color: "#cec8ac"
|
color: "#cec8ac"
|
||||||
- state: icon-default
|
- state: icon-default
|
||||||
|
|
||||||
|
- type: entity
|
||||||
|
parent: BaseFlatpack
|
||||||
|
id: SpaceHeaterFlatpack
|
||||||
|
name: space heater flatpack
|
||||||
|
description: A flatpack used for constructing a space heater.
|
||||||
|
components:
|
||||||
|
- type: Flatpack
|
||||||
|
entity: SpaceHeaterAnchored
|
||||||
|
|||||||
Reference in New Issue
Block a user