|
| 13 Feb 2016 01:04 PM |
| Just wondering if there is a way to disconnect the events of TextButton and ImageButton to reuse them, or will I have to delete them and remake them? |
|
|
| Report Abuse |
|
|
|
| 13 Feb 2016 01:34 PM |
http://wiki.roblox.com/index.php?title=RBXScriptSignal
you mean that?
|
|
|
| Report Abuse |
|
|
|
| 13 Feb 2016 03:14 PM |
No ImageButton.MouseButton1Down:connect(function() end) This kind of event. |
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 13 Feb 2016 03:23 PM |
Not sure what you are trying to do here. Could you explain more?
btw remember,
event:disconnect() |
|
|
| Report Abuse |
|
|
BanTech
|
  |
| Joined: 31 Dec 2015 |
| Total Posts: 886 |
|
|
| 13 Feb 2016 03:23 PM |
listeners = {}
table.insert(listeners, ImageButton.MouseButton1Down:connect(function() --code stuff end))
--disconnect all for _, e in pairs(listeners) do e:disconnect() end |
|
|
| Report Abuse |
|
|
|
| 13 Feb 2016 04:48 PM |
| Yeah I figured i'd have to keep a reference, roblox should implement a way to disconnect all events on that particular button. |
|
|
| Report Abuse |
|
|