I have not attempted to do this specific script. I asked this question 2 days ago and nobody has replied since then. What I would Like to learn is when you step on a brick it triggers a bridge to appear to cross the river. That was the example.
What you should do is fire an onTouched event when someone touches the part. Write down a local function that runs when the onTouched event is fired! Hopefully this helped.
local part = -- Define where the Part that should be touched is local bridge = -- Define the model/part that is the bridge local function onTouched() bridge.Transparency = 0 -- This makes the bridge visible end part.Touched:Connect(onTouched)
If you have multiple parts for your bridge, then:
local part = --Define the part that is touched to fire event local bridgePart1 = -- Define first bridge part local bridgePart2 = --Define second bridge part and so on... local function onTouched() bridgePart1.Transparency = 0 -- Sets Transparency to Opaque bridgePart2.Transparency = 0 end part.Touched:Connect(onTouched)