Фиксы (#228)

* fix: morgues and bodybags can store more than 1 entity

* fix: rename BluespaceSilo to BluespaceStorage

* fix: fix felinid`s missing sound

* fix: fix missing hatch airlock`s states

* add: translation for hatch airlocks

* add: texture localization for airlocks

* add: add new word to slang.json

* fix: fix wrong letter on cargo airlock`s texture

* fix: fix material whitelist part one

* git commit

* fix: fix lathe whitelist
This commit is contained in:
ThereDrD0
2024-03-21 23:20:09 +03:00
committed by GitHub
parent 953ebe2450
commit cdf16c6119
71 changed files with 96 additions and 61 deletions

View File

@@ -45,7 +45,7 @@ public sealed partial class MaterialStorageControl : BoxContainer
}
var gridStorage = _entityManager.TryGetComponent<TransformComponent>(_owner, out var transformComponent) &&
_entityManager.HasComponent<BluespaceSiloComponent>(_owner) &&
_entityManager.HasComponent<BluespaceStorageComponent>(_owner) &&
_entityManager.TryGetComponent<MaterialStorageComponent>(transformComponent.GridUid,
out var materialStorageComponent) ? materialStorageComponent : null;

View File

@@ -109,6 +109,7 @@ namespace Content.Server.Lathe
return;
var materialWhitelist = new List<ProtoId<MaterialPrototype>>();
var recipes = GetAvailableRecipes(uid, component, true);
foreach (var id in recipes)
{
if (!_proto.TryIndex(id, out var proto))
@@ -122,6 +123,18 @@ namespace Content.Server.Lathe
}
}
if (TryComp<MaterialStorageComponent>(args.Storage, out var materialStorageComponent) &&
materialStorageComponent.Whitelist?.Entities != null)
{
foreach (var id in materialStorageComponent.Whitelist.Entities)
{
if (!materialWhitelist.Contains(id))
{
materialWhitelist.Add(id);
}
}
}
var combined = args.Whitelist.Union(materialWhitelist).ToList();
args.Whitelist = combined;
}
@@ -165,7 +178,7 @@ namespace Content.Server.Lathe
? (int) (-amount * component.MaterialUseMultiplier)
: -amount;
var gridUid = HasComp<BluespaceSiloComponent>(uid) &&
var gridUid = HasComp<BluespaceStorageComponent>(uid) &&
TryComp<TransformComponent>(uid, out var transformComponent) ? transformComponent.GridUid : null;
var gridStorage =

View File

@@ -79,7 +79,7 @@ public sealed class MaterialStorageSystem : SharedMaterialStorageSystem
volume = sheetsToExtract * volumePerSheet;
}
var gridUid = HasComp<BluespaceSiloComponent>(uid) &&
var gridUid = HasComp<BluespaceStorageComponent>(uid) &&
TryComp<TransformComponent>(uid, out var transformComponent)
? transformComponent.GridUid
: null;
@@ -109,18 +109,23 @@ public sealed class MaterialStorageSystem : SharedMaterialStorageSystem
{
if (!Resolve(receiver, ref storage) || !Resolve(toInsert, ref material, ref composition, false))
return false;
if (TryComp<ApcPowerReceiverComponent>(receiver, out var power) && !power.Powered)
return false;
if (!base.TryInsertMaterialEntity(user, toInsert, receiver, storage, material, composition))
return false;
_audio.PlayPvs(storage.InsertingSound, receiver);
_popup.PopupEntity(Loc.GetString("machine-insert-item", ("user", user), ("machine", receiver),
("item", toInsert)), receiver);
QueueDel(toInsert);
// Logging
TryComp<StackComponent>(toInsert, out var stack);
var count = stack?.Count ?? 1;
_adminLogger.Add(LogType.Action, LogImpact.Low,
$"{ToPrettyString(user):player} inserted {count} {ToPrettyString(toInsert):inserted} into {ToPrettyString(receiver):receiver}");
return true;

View File

@@ -1,3 +1,4 @@
using Robust.Shared.Audio;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype;
using Robust.Shared.Prototypes;
@@ -12,6 +13,9 @@ namespace Content.Server.Abilities.Felinid
[DataField("hairballPrototype", customTypeSerializer: typeof(PrototypeIdSerializer<EntityPrototype>))]
public string HairballPrototype = "Hairball";
[DataField]
public SoundSpecifier MouseEatingSound = new SoundCollectionSpecifier("eating");
public EntityUid? HairballAction;
public EntityUid? EatMouseAction;

View File

@@ -137,7 +137,7 @@ namespace Content.Server.Abilities.Felinid
Del(component.PotentialTarget.Value);
component.PotentialTarget = null;
_audio.PlayPvs("/Audio/Items/eatfood.ogg", uid, AudioParams.Default.WithVariation(0.15f));
_audio.PlayPvs(component.MouseEatingSound, uid, AudioParams.Default.WithVariation(0.15f));
_hungerSystem.ModifyHunger(uid, 70f, hunger);

View File

@@ -46,7 +46,7 @@ public abstract class SharedLatheSystem : EntitySystem
var adjustedAmount = AdjustMaterial(needed, recipe.ApplyMaterialDiscount, component.MaterialUseMultiplier);
var gridUid =
HasComp<BluespaceSiloComponent>(uid) &&
HasComp<BluespaceStorageComponent>(uid) &&
TryComp<TransformComponent>(uid, out var transformComponent)
? transformComponent.GridUid
: null;

View File

@@ -296,7 +296,7 @@ public abstract class SharedMaterialStorageSystem : EntitySystem
var multiplier = TryComp<StackComponent>(toInsert, out var stackComponent) ? stackComponent.Count : 1;
var totalVolume = 0;
var gridUid = HasComp<BluespaceSiloComponent>(receiver) &&
var gridUid = HasComp<BluespaceStorageComponent>(receiver) &&
TryComp<TransformComponent>(receiver, out var transformComponent)
? transformComponent.GridUid
: null;
@@ -348,8 +348,10 @@ public abstract class SharedMaterialStorageSystem : EntitySystem
{
if (!Resolve(uid, ref component, false))
return;
var ev = new GetMaterialWhitelistEvent(uid);
RaiseLocalEvent(uid, ref ev);
component.MaterialWhiteList = ev.Whitelist;
Dirty(uid, component);
}

View File

@@ -1,4 +1,5 @@
using Content.Shared.Tag;
using Robust.Shared.Prototypes;
using Robust.Shared.Serialization;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype.List;
@@ -31,6 +32,9 @@ namespace Content.Shared.Whitelist
[NonSerialized]
private List<ComponentRegistration>? _registrations = null;
[DataField(customTypeSerializer:typeof(PrototypeIdListSerializer<EntityPrototype>))]
public List<string>? Entities;
/// <summary>
/// Tags that are allowed in the whitelist.
/// </summary>

View File

@@ -3,7 +3,7 @@
namespace Content.Shared._White.ShitSilo;
[RegisterComponent, NetworkedComponent]
public sealed partial class BluespaceSiloComponent : Component
public sealed partial class BluespaceStorageComponent : Component
{
}

View File

@@ -61,3 +61,10 @@ ent-AirlockCommandGlass = { ent-AirlockGlass }
ent-AirlockSecurityGlass = { ent-AirlockGlass }
.desc = { ent-AirlockGlass.desc }
.suffix = СлужбаБезопасности
ent-AirlockHatch = шлюзовый люк
.desc = { ent-Airlock.desc }
ent-AirlockHatchMaintenance = { ent-AirlockHatch}
.desc = { ent-AirlockHatch.desc }
.suffix = Технический

View File

@@ -16500,7 +16500,7 @@ entities:
- type: Transform
pos: -49.629227,-28.475441
parent: 60
- proto: BodyBag_Container
- proto: BodyBagContainer
entities:
- uid: 2049
components:

View File

@@ -16606,7 +16606,7 @@ entities:
rot: 1.5707963267948966 rad
pos: -9.5,47.5
parent: 8364
- proto: BodyBag_Folded
- proto: BodyBagFolded
entities:
- uid: 27686
components:

View File

@@ -8171,7 +8171,7 @@ entities:
- type: Transform
pos: -26.622076,24.452543
parent: 1
- proto: BodyBag_Container
- proto: BodyBagContainer
entities:
- uid: 8242
components:

View File

@@ -20173,7 +20173,7 @@ entities:
- type: Transform
pos: 19.5,-51.5
parent: 2
- proto: BodyBag_Folded
- proto: BodyBagFolded
entities:
- uid: 161
components:

View File

@@ -15255,7 +15255,7 @@ entities:
- type: Transform
pos: 30.5,56.5
parent: 1
- proto: BodyBag_Folded
- proto: BodyBagFolded
entities:
- uid: 2490
components:

View File

@@ -15186,7 +15186,7 @@ entities:
- type: Transform
pos: -42.538452,-53.54715
parent: 5350
- proto: BodyBag_Folded
- proto: BodyBagFolded
entities:
- uid: 23085
components:

View File

@@ -11878,7 +11878,7 @@ entities:
- type: Transform
pos: 6.380858,-242.27087
parent: 2
- proto: BodyBag_Folded
- proto: BodyBagFolded
entities:
- uid: 2706
components:

View File

@@ -117,7 +117,7 @@
components:
- type: StorageFill
contents:
- id: BodyBag_Folded
- id: BodyBagFolded
amount: 4
- type: Sprite
layers:

View File

@@ -1,5 +1,5 @@
- type: entity
id: BodyBag_Container
id: BodyBagContainer
parent: BaseFoldable
name: body bag
description: A plastic bag designed for the storage and transportation of cadavers to stop body decomposition.
@@ -42,7 +42,6 @@
mask:
- Impassable
- type: EntityStorage
capacity: 1
isCollidableWhenOpen: true
closeSound:
path: /Audio/Misc/zip.ogg
@@ -83,10 +82,10 @@
price: 50
- type: entity
id: BodyBag_Folded
id: BodyBagFolded
name: body bag
description: A plastic bag designed for the storage and transportation of cadavers to stop body decomposition.
parent: BodyBag_Container
parent: BodyBagContainer
suffix: folded
components:
- type: Foldable

View File

@@ -18,8 +18,19 @@
layer:
- MachineLayer
- type: Lathe
- type: BluespaceSilo
- type: MaterialStorage
whitelist:
tags:
- Sheet
- RawMaterial
- Ingot
entities:
- Steel
- Glass
- Gold
- Plasma
- Uranium
- Plastic
- type: Destructible
thresholds:
- trigger:
@@ -75,12 +86,6 @@
map: ["enum.WiresVisualLayers.MaintenancePanel"]
- type: Machine
board: AutolatheMachineCircuitboard
- type: MaterialStorage
whitelist:
tags:
- Sheet
- RawMaterial
- Ingot
- type: Lathe
idleState: icon
runningState: building
@@ -226,7 +231,7 @@
- MagazineGrenadeEmpty
- GrenadeEMP
- GrenadeFlash
- type: BluespaceSilo
- type: BluespaceStorage
- type: entity
id: AutolatheHyperConvection
@@ -239,7 +244,7 @@
- type: Lathe
materialUseMultiplier: 0.5
timeMultiplier: 1.5
- type: BluespaceSilo
- type: BluespaceStorage
- type: LatheHeatProducing
- type: Machine
board: AutolatheHyperConvectionMachineCircuitboard
@@ -268,12 +273,6 @@
- type: Wires
boardName: wires-board-name-protolathe
layoutId: Protolathe
- type: MaterialStorage
whitelist:
tags:
- Sheet
- RawMaterial
- Ingot
- type: Lathe
idleState: icon
runningState: building
@@ -352,7 +351,7 @@
- WeaponAdvancedLaser
- WeaponLaserCannon
- WeaponXrayCannon
- type: BluespaceSilo
- type: BluespaceStorage
- type: entity
id: ProtolatheHyperConvection
@@ -365,7 +364,7 @@
- type: Lathe
materialUseMultiplier: 0.5
timeMultiplier: 1.5
- type: BluespaceSilo
- type: BluespaceStorage
- type: LatheHeatProducing
- type: Machine
board: ProtolatheHyperConvectionMachineCircuitboard
@@ -481,7 +480,7 @@
- ArtifactCrusherMachineCircuitboard
- TelecomServerCircuitboard
- MassMediaCircuitboard
- type: BluespaceSilo
- type: BluespaceStorage
- type: MaterialStorage
whitelist:
tags:
@@ -594,7 +593,7 @@
- HamtrLLeg
- HamtrRLeg
- VimHarness
- type: BluespaceSilo
- type: BluespaceStorage
- type: MaterialStorage
whitelist:
tags:
@@ -647,7 +646,6 @@
- AbominationCube
- SpaceCarpCube
- SpaceTickCube
- type: BluespaceSilo
- type: entity
id: SecurityTechFab
@@ -774,13 +772,7 @@
- MagazineBoxMagnumAP
- MagazineBoxAntiMateriel
- MagazineBoxCaselessRifle
- type: MaterialStorage
whitelist:
tags:
- Sheet
- RawMaterial
- Ingot
- type: BluespaceSilo
- type: BluespaceStorage
- type: entity
id: AmmoTechFab
@@ -827,12 +819,8 @@
- MagazineBoxMagnumAP
- MagazineBoxAntiMateriel
- MagazineBoxCaselessRifle
- type: BluespaceSilo
- type: MaterialStorage
whitelist:
tags:
- Sheet
-
- type: BluespaceStorage
- type: entity
id: MedicalTechFab
parent: BaseLathe
@@ -901,7 +889,7 @@
- SyringeBluespace
- SyringeCryostasis
- ClothingEyesHudMedical
- type: BluespaceSilo
- type: BluespaceStorage
- type: Machine
board: MedicalTechFabCircuitboard
- type: StealTarget
@@ -1086,7 +1074,7 @@
- ClothingOuterWinterCentcom
- ClothingOuterWinterSyndie
- ClothingOuterWinterSyndieCap
- type: BluespaceSilo
- type: BluespaceStorage
- type: MaterialStorage
whitelist:
tags:
@@ -1133,7 +1121,6 @@
- IngotGold30
- IngotSilver30
- MaterialBananium10
- type: BluespaceSilo
- type: entity
parent: OreProcessor
@@ -1162,7 +1149,6 @@
- IngotGold30
- IngotSilver30
- MaterialBananium10
- type: BluespaceSilo
- type: entity
parent: BaseLathe
@@ -1194,4 +1180,3 @@
staticRecipes:
- MaterialSheetMeat
- SheetPaper
- type: BluespaceSilo

View File

@@ -36,7 +36,6 @@
- type: EntityStorage
isCollidableWhenOpen: true
showContents: false
capacity: 1
enteringOffset: 0, -1
closeSound:
path: /Audio/Items/deconstruct.ogg

View File

@@ -49,7 +49,7 @@
- type: latheRecipe
id: BodyBag
result: BodyBag_Folded
result: BodyBagFolded
completetime: 2
materials:
Plastic: 300

View File

@@ -20,7 +20,7 @@
layer:
- TabletopMachineLayer
- type: Lathe
- type: BluespaceSilo
- type: BluespaceStorage
- type: MaterialStorage
- type: ActivatableUI
key: enum.LatheUiKey.Key

View File

@@ -31,7 +31,7 @@
- type: CameraRecoil
- type: Examiner
- type: CanHostGuardian
- type: Felinid #since this just adds an action...
- type: Felinid
- type: InteractionPopup
successChance: 1
interactSuccessString: petting-success-cat

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 984 B

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1020 B

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 3.4 KiB

View File

@@ -22,6 +22,12 @@
{
"name": "open_unlit"
},
{
"name": "emergency_open_unlit"
},
{
"name": "bolted_open_unlit"
},
{
"name": "closing",
"delays": [

View File

@@ -22,6 +22,12 @@
{
"name": "open_unlit"
},
{
"name": "emergency_open_unlit"
},
{
"name": "bolted_open_unlit"
},
{
"name": "closing",
"delays": [

Binary file not shown.

Before

Width:  |  Height:  |  Size: 963 B

After

Width:  |  Height:  |  Size: 1009 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 953 B

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 538 B

After

Width:  |  Height:  |  Size: 489 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1008 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 998 B

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 913 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 538 B

After

Width:  |  Height:  |  Size: 539 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1010 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 961 B

After

Width:  |  Height:  |  Size: 1004 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 831 B

After

Width:  |  Height:  |  Size: 852 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

View File

@@ -318,6 +318,11 @@
"чиллит": "отдыхает",
"чиллим": "отдыхаем",
"жиза": "жизненно",
"анома": "аномалия",
"аному": "аномалию",
"аномы": "аномалии",
"аномов": "аномалий",
"аномах": "аномалиях",
"сус": "подозрительно",
"сасно": "привлекательно",
"сасный": "привлекательный",