@@ -197,7 +197,7 @@ function GM:PlayerCanPickupItem(ply, item)
197197 DbgPrintPickup (" PlayerCanPickupItem" , ply , item )
198198
199199 if item .CreatedForPlayer ~= nil then
200- if item .CreatedForPlayer == ply then
200+ if item .CreatedForPlayer == ply or item . CreatedForPlayer == NULL then
201201 DbgPrintPickup (" Simple pickup, created for player: " .. tostring (ply ))
202202
203203 return true
@@ -252,7 +252,7 @@ function GM:PlayerCanPickupWeapon(ply, wep)
252252 end
253253
254254 if wep .CreatedForPlayer ~= nil then
255- if wep .CreatedForPlayer == ply then
255+ if wep .CreatedForPlayer == ply or wep . CreatedForPlayer == NULL then
256256 DbgPrintPickup (ply , " Simple pickup, created for player" )
257257
258258 return true
@@ -311,7 +311,7 @@ function GM:WeaponEquip(wep, owner)
311311 end
312312 end
313313
314- if wep .CreatedForPlayer ~= owner and wep .DroppedByPlayer == nil then
314+ if wep .CreatedForPlayer == nil and wep .DroppedByPlayer == nil then
315315 if AMMO_LIKE_WEAPONS [wep :GetClass ()] ~= true and self :CallGameTypeFunc (" ShouldRespawnWeapon" , wep ) == true then
316316 local respawnTime = self :CallGameTypeFunc (" GetWeaponRespawnTime" ) or 0.5
317317
@@ -321,5 +321,5 @@ function GM:WeaponEquip(wep, owner)
321321 end
322322 end
323323
324- wep .CreatedForPlayer = nil
324+ wep .CreatedForPlayer = NULL
325325end
0 commit comments