Fix coop key share failing if the item was spawned in-game (for example, via the console)

This commit is contained in:
nashmuhandes 2024-12-31 04:42:56 +08:00 committed by Rachael Alexanderson
parent d6e1097b85
commit aebabd2307

View file

@ -700,7 +700,7 @@ class Inventory : Actor
toucher.HasReceived(self, cls); toucher.HasReceived(self, cls);
// If the item can be shared, make sure every player gets a copy. // If the item can be shared, make sure every player gets a copy.
if (multiplayer && !deathmatch && !bDropped && ShouldShareItem(toucher)) if (multiplayer && !deathmatch && ShouldShareItem(toucher))
ShareItemWithPlayers(toucher); ShareItemWithPlayers(toucher);
} }
return res, toucher; return res, toucher;