windbeach
|
  |
| Joined: 11 Jul 2013 |
| Total Posts: 293 |
|
|
| 11 Dec 2016 09:19 AM |
So I have a box with a click detector, it fires whenever I click while not holding a tool, but doesn't when I click while holding a tool.
Any way I can detect clicks on a part while holding tools?
|
|
|
| Report Abuse |
|
|
windbeach
|
  |
| Joined: 11 Jul 2013 |
| Total Posts: 293 |
|
| |
|
|
| 11 Dec 2016 10:52 AM |
Try adding a script or local script (not sure if there'd be a difference in this case) in the tool and put this in the script:
script.Parent.Selected:connect(function(mouse) target = mouse.Target if target then if target == The location of your part then mouse.Button1Down:connect(function() -- code end end end) |
|
|
| Report Abuse |
|
|
|
| 11 Dec 2016 10:53 AM |
if target.Parent == The location of your part then*
Forgot a crucial part. |
|
|
| Report Abuse |
|
|
|
| 11 Dec 2016 10:56 AM |
| Make a custom clickDetector |
|
|
| Report Abuse |
|
|