I want the mod to stop taking my question down. I did nothing wrong i'm just asking a question.Also the player have a sword and when they walk above the brick their sword get removed. Please help.Thanks
vvvv-Local Version-vvvv
wait () game.Workspace.TestBrick.Touched:Connect(function () local Sword = game.Players.LocalPlayer.Backpack:FindFirstChild("Sword") if Sword then Sword:Destroy() end end)
put this in a local script in the backpack or start player scripts
function onTouch(part) local Player = game.Players:FindFirstChild(part.Parent.Name) if Player ~= nil then local Sword = part.Parent:FindFirstChild("Sword") local SwordInBackpack = Player.Backpack:FindFirstChild("Sword") if Sword ~= nil then Sword:Destroy() end if SwordInBackpack ~= nil then SwordInBackpack:Destroy() end end end script.Parent.Touched:connect(onTouch)
try this
Closed as Not Constructive by User#19524
This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.
Why was this question closed?