Fix ghost FOV bug (#21614)

This commit is contained in:
Leon Friedrich
2023-11-13 05:36:00 +11:00
committed by GitHub
parent b9b706bda9
commit c9e2a91f13
5 changed files with 50 additions and 58 deletions

View File

@@ -301,6 +301,18 @@ namespace Content.Shared.Chemistry.Components
return total;
}
public FixedPoint2 GetTotalPrototypeQuantity(string id)
{
var total = FixedPoint2.Zero;
foreach (var (reagent, quantity) in Contents)
{
if (id == reagent.Prototype)
total += quantity;
}
return total;
}
public ReagentId? GetPrimaryReagentId()
{
if (Contents.Count == 0)