Skip to content

Commit be86aa2

Browse files
authored
Fix dupe bug caused by StackSystem (space-wizards#43738)
* Fix dupe bug caused by StackSystem * Removed TryComp
1 parent ab96ec8 commit be86aa2

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

Content.Shared/Stacks/SharedStackSystem.API.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,10 @@ public EntityUid GetOne(Entity<StackComponent?> stackEnt)
2626

2727
ReduceCount(stackEnt, 1);
2828
var stackId = _prototype.Index(stackEnt.Comp.StackTypeId);
29-
return PredictedSpawnNextToOrDrop(stackId.Spawn, stackEnt.Owner);
29+
var entityUid = PredictedSpawnNextToOrDrop(stackId.Spawn, stackEnt.Owner);
30+
31+
SetCount(entityUid, 1);
32+
return entityUid;
3033
}
3134

3235
#endregion

0 commit comments

Comments
 (0)