Im making my own game at roblox, and i need a script about invisible wall with cancollide and after few 5 seconds the cancollide dissapears. Thanks for the helpers
Need help about an invisible wall with cancollide script?
1 answer
Try this, assuming you understand the properties of a part...
Part = script.Parent
Part.Transparency = 0
Part.CanCollide = true
wait(5)
Part.Transparency = 1
Part.CanCollide = false
If you want it once the round stats,
if game.Workspace.RoundStarted == true then
Part = script.Parent
Part.Transparency = 0
Part.CanCollide = true
wait(5)
Part.Transparency = 1
Part.CanCollide = false
That should work, as long as there is a bool value in workspace named "RoundStarted" and when the "round" starts the value is set to true.
3 comments
As much as that might work, using a localscript with FE-Enabled might be more efficient if you only want one person going through. I'm sure theres a way to allow players to go through but not other objects, I can't find it though.
Maybe, but it seemed like he was just starting out and I tried to make it extremely basic for the sake of him.
I'm new and im trying my best to script and learn. everyone was new to something and needed help.
This discussion is preserved as it was. New answers, comments, and votes are closed.

9 comments
What have you tried doing so far?
searched on youtube scripts about cancollide but nothing worked so far. Then, i went to roblox forums and this forum and reddit also. i found only door and key scripts. and when im trying to do the script at my own its not working. example:
i tried like: wait(1) name.transparency = 1 name.cancollide = false. (im new at scripting so if its bad dont judge
Do you want it to be a loop of on and off? Or just once when the server begins running?
Ultimate_Piccolo that worked thanks! but can u do it as a loop, when the round starts it will start again?
If you mean when a round starts, when that round start it can set a value true and I can write a script for that?
yea i want the value at the beginning of the round to be true. if u can write a script for that i will very appreciate it
Ultimate_Piccolo i dont find BoolValue... i think the round and the intermission is in a script. do u know how to solve that or making another script?
Sorry I was gone for a few days and will be for the next 11 days. If you don't know, a boolean value is a true or false value. Put a boolean value named "round" in the script that does the rounds. In the script set the round value to true when the round starts.