fixes stacksystem exception
This commit is contained in:
parent
58fc8ee35f
commit
2f95d77060
1 changed files with 4 additions and 1 deletions
|
|
@ -50,7 +50,10 @@ namespace Content.Server.Stack
|
|||
// Get a prototype ID to spawn the new entity. Null is also valid, although it should rarely be picked...
|
||||
var prototype = _prototypeManager.TryIndex<StackPrototype>(stack.StackTypeId, out var stackType)
|
||||
? stackType.Spawn
|
||||
: stack.Owner.Prototype?.ID ?? null;
|
||||
: stack.Owner.Prototype?.ID;
|
||||
|
||||
if (prototype == null)
|
||||
return null;
|
||||
|
||||
// Try to remove the amount of things we want to split from the original stack...
|
||||
if (!Use(uid, amount, stack))
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue