EpicMessi
|
  |
| Joined: 11 Apr 2011 |
| Total Posts: 596 |
|
|
| 19 Sep 2017 07:58 PM |
I always get confused with the end function. Can someone fix this up for me?
alarm = script.Parent.ClickDetector sound = script.Parent.Parent.Alarm
alarm_On = false
alarm.MouseClick:connect(function() if alarm_On == true then script.Parent.Parent.Alarm:Stop() end end elseif alarm_On = false then sound:Play() alarm_On = true end) end)
|
|
|
| Report Abuse |
|
|
|
| 19 Sep 2017 08:00 PM |
| take away the parenthese on the first end, that's for the end statement while the second is in closing for (function() |
|
|
| Report Abuse |
|
|
|
| 19 Sep 2017 08:01 PM |
thats for the if* statement
oof
im way tired |
|
|
| Report Abuse |
|
|
EpicMessi
|
  |
| Joined: 11 Apr 2011 |
| Total Posts: 596 |
|
|
| 19 Sep 2017 08:07 PM |
| fixed it, few errors done. thx |
|
|
| Report Abuse |
|
|