How do I make a box just a 5,5,5 part and when the part slides onto the part(the button) it becomes green and it gets pushed down, but it player pushes the part off the button it goes up and the button becomes red. But when the block is on the button. a door opens. but if not on button doesnt open.
script.Parent.Touched:connect(function(part) if part.Name == "Box" then --It touched the part and it is the box script.Parent.BrickColor = BrickColor.new("Really red") else --it touched the part and it isn't the box script.Parent.BrickColor = BrickColor.new("Lime green") end end)
You need to add some special to the box like name it "Box" or have something to define it
Closed as Not Constructive by lukeb50, hiimgoodpack, PyccknnXakep, and Void_Frost
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?