StackSystem uses EntityUid for Split and Spawn
This commit is contained in:
@@ -91,7 +91,7 @@ namespace Content.Server.Construction.Components
|
||||
if (stack == null)
|
||||
throw new Exception($"Couldn't spawn stack of type {stackType}!");
|
||||
|
||||
if (!partContainer.Insert(stack))
|
||||
if (!partContainer.Insert(Owner.EntityManager.GetEntity(stack)))
|
||||
throw new Exception($"Couldn't insert machine material of type {stackType} to machine with prototype {Owner.Prototype?.ID ?? "N/A"}");
|
||||
}
|
||||
|
||||
|
||||
@@ -319,7 +319,7 @@ namespace Content.Server.Construction.Components
|
||||
if (splitStack == null)
|
||||
return false;
|
||||
|
||||
if(!_partContainer.Insert(splitStack))
|
||||
if(!_partContainer.Insert(Owner.EntityManager.GetEntity(splitStack.Value)))
|
||||
return false;
|
||||
|
||||
_materialProgress[type] += needed;
|
||||
|
||||
Reference in New Issue
Block a user