From 5dfb285bd83e8afffd372515b573162f2ef7b9fd Mon Sep 17 00:00:00 2001 From: NepDisk Date: Tue, 18 Nov 2025 01:27:20 -0500 Subject: [PATCH] Modify P_CanPickupItem hook to function correctly Returning true for the first return argument disables being able to pickup stuff, in combontion with weapon and other status checks can be used to turn off picking x item. the second return specifies if you override vanilla pickup behaviour and always pick up stuff --- src/p_inter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/p_inter.c b/src/p_inter.c index f55c0f17e..e8159c9c2 100644 --- a/src/p_inter.c +++ b/src/p_inter.c @@ -116,7 +116,7 @@ boolean P_CanPickupItem(player_t *player, UINT8 weapon) boolean force = false; if (LUA_HookCanPickupItem(player, weapon, &force)) - return true; + return false; if (!force) {