Attack Script for the Npc:
Texture.Touched:connect(function(hit)
if hit.Parent:FindFirstChild('Humanoid') then
local char = hit.Parent
if char.Shared:FindFirstChild("Check1") then
-- Checking if player doesn't have the Value
else
local Int = Instance.new('BoolValue',char.Shared)
Int.Name = "Check1"
Int.Value = true
end
Npc Died Script:
for _,p in pairs(game.Players:GetPlayers()) do
if p.Character.Shared.Check1.Value == true then
print (p.Name.." Gain the loot")
p.Character.Shared.Check1:Remove()
end
end
I'm not sure if this would give everyone in the game the same loot or would it just give the player that has "Check1" in there Character the Loot and not everyone else. Is there a better way of doing this?

3 comments
You're using Remove() :c
Still new to half of this stuff, Remove() not good to use or something? There's only 2 I know of and that's Remove() / Destroy()
Yeah, don't use Remove() use Destroy() or use game.Debris:AddItem(p.Character.Shared.Check1, wait())