Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make disappear an brick and make a sound when touched ? [closed]

Asked by 6 years ago

Hello I'm reposting this because I still don't have any awnsers :/

I'm trying to make something DISAPPEAR and when the brick is touched it has to make a noise (sound id) , somebody did this script for me but it's not like I want , it's not making sound , it's not making it disappear , it's unanchoring it


function x(hit) script.Parent.Anchored = false script.Parent.GlassSound:Play() script:Destroy() end script.Parent.Touched:connect(x)

Hope somebody can help me :/ Thanks

0
You should not repost questions as they will be moderated as duplicated. User#5423 17 — 6y
0
You want the scripts parent to be destroyed since this is the part. User#5423 17 — 6y

Marked as Duplicate by minikitkat

This question has been asked before, and already has an answer. If those answers do not fully address your question, then please ask a new question here.

Why was this question closed?

1 answer

Log in to vote
0
Answered by 6 years ago
function x(hit)
script.Parent.Anchored = false
script.Parent.GlassSound:Play()
script.Parent:Destroy()
end

script.Parent.Touched:connect(x)

thats the script you need (look at the comments tho)

Ad