Items are removed from their parent inventory and their bodies are removed when Item.Remove is called
This commit is contained in:
@@ -378,7 +378,12 @@ namespace Barotrauma.Items.Components
|
||||
{
|
||||
base.RemoveComponentSpecific();
|
||||
|
||||
GameMain.World.RemoveBody(body.FarseerBody);
|
||||
if (body != null)
|
||||
{
|
||||
body.Remove();
|
||||
body = null;
|
||||
}
|
||||
|
||||
|
||||
if (linkedGap!=null) linkedGap.Remove();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user