I have a weapon spawner but want to stop players from picking it up more then once, I think my code below is correct to find if the player has Gun1 in thier backpack but how do you intercept the tool pickup event to allow or stop the pickup?
local tool = hit.Parent:FindFirstChild("Gun1")
if tool then
-- do stuff
end
Make sure to check in the backpack as well, not just the character. And if you haven’t already, use the piece of code you just posted within the script that gives the player the gun, if this isn’t working then posting the give script would help.