Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

My script is not working even though there is no errors. Any help?

This script is meant to make its so when you touch the block it becomes transparent and CanCollide becomes false. Its not working. Please help!!!

script.Parent.Touched:Connect(function(p)
	
	p.Parent.Transparency (100)
	wait (0.2)
	p.Parent.CanCollide = false
	
	wait(1)
	p.Parent.Transpareny (0)
	wait (0.2)
	p.Parent.CanCollide = true
end)

2 comments

0

On line 8, you wrote "p.Parent.Transpareny (0)", but you misspelled Transparency, maybe that's why it doesn't work

0

It should be Transparency = 0

1 answer

script.Parent.Touched:Connect(function(p)

    p.Parent.Transparency = 1
    wait (0.2)
    p.Parent.CanCollide = false

    wait(1)
    p.Parent.Transparency = 0
    wait (0.2)
    p.Parent.CanCollide = true
end)

why Transparency (100) ? a value between 0 and 1 will do.

This discussion is preserved as it was. New answers, comments, and votes are closed.