Фиксы (#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

@@ -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 =