|
| 24 Aug 2011 02:49 PM |
function onTouch(hit) wait(0.3) script.Parent.Transparency = 1 script.Parent.CanCollide = false wait(3) script.Parent.Transparency = 0 script.Parent.CanCollide = true end
script.Parent.Touched:connect(onTouched)
I'm trying to make a script for my obby that will go in dissappearing stairs, so that after you touch the stairs, they dissapear and you can fall through them. |
|
|
| Report Abuse |
|
|
Lancias
|
  |
| Joined: 03 Aug 2011 |
| Total Posts: 437 |
|
|
| 24 Aug 2011 02:50 PM |
function onTouch(hit) wait(0.3) script.Parent.Transparency = 1 script.Parent.CanCollide = false wait(3) script.Parent.Transparency = 0 script.Parent.CanCollide = true end
script.Parent.Touched:connect(onTouch) |
|
|
| Report Abuse |
|
|
Fl0x
|
  |
| Joined: 06 Aug 2010 |
| Total Posts: 5169 |
|
|
| 24 Aug 2011 02:51 PM |
function onTouch(hit) --Called "onTouch"
script.Parent.Touched:connect(onTouched) --Searches for "onTouched", which does not exist.
|
|
|
| Report Abuse |
|
|
|
| 24 Aug 2011 02:52 PM |
| Oh. Sorry guys, I am a big nub caik. T_T |
|
|
| Report Abuse |
|
|
Fl0x
|
  |
| Joined: 06 Aug 2010 |
| Total Posts: 5169 |
|
|
| 24 Aug 2011 02:53 PM |
| It's okay, everyone starts small. |
|
|
| Report Abuse |
|
|
Lancias
|
  |
| Joined: 03 Aug 2011 |
| Total Posts: 437 |
|
|
| 24 Aug 2011 02:53 PM |
| You might want to add Debounce. |
|
|
| Report Abuse |
|
|
Fl0x
|
  |
| Joined: 06 Aug 2010 |
| Total Posts: 5169 |
|
| |
|
|
| 24 Aug 2011 02:56 PM |
| Debounce? Sorry, this is literally my 2nd script I have ever made.... -_- |
|
|
| Report Abuse |
|
|
Fl0x
|
  |
| Joined: 06 Aug 2010 |
| Total Posts: 5169 |
|
|
| 24 Aug 2011 02:57 PM |
http://wiki.roblox.com/index.php/Debounce
It's basicly a method that people don't touch the brick too many times at once. |
|
|
| Report Abuse |
|
|
|
| 24 Aug 2011 02:59 PM |
| Thanks. I'll try it without first and take it from there. |
|
|
| Report Abuse |
|
|