maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 09 Jul 2015 09:47 PM |
that has an event?
function printthis (msg) print (msg) end
workspace.Tool.Activated:connect (printthis,"hi")
would that work?
Hello World! |
|
|
| Report Abuse |
|
|
|
| 09 Jul 2015 10:16 PM |
| workspace.Tool.Activated:connect(function() printthis("hi") end) |
|
|
| Report Abuse |
|
|
|
| 09 Jul 2015 10:20 PM |
function func(...) local args = {} local custom = args[#args] print(custom) end
workspace.Tool.Activated:connect(function(...) func(..., "hi") end) |
|
|
| Report Abuse |
|
|
|
| 09 Jul 2015 10:21 PM |
My bad, fixed
function func(...) local args = {} local custom = args[1] print(custom) end
workspace.Tool.Activated:connect(function(...) func("hi", ...) end) |
|
|
| Report Abuse |
|
|
|
| 09 Jul 2015 10:21 PM |
Ugh hold on, now it's fixed XD
function func(...) local args = {...} local custom = args[1] print(custom) end
workspace.Tool.Activated:connect(function(...) func("hi", ...) end)
|
|
|
| Report Abuse |
|
|
|
| 09 Jul 2015 10:24 PM |
| I didn't see the OP ask for the arguments from the event too. |
|
|
| Report Abuse |
|
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 09 Jul 2015 10:35 PM |
There is no parameter given from the event. It also had to be anonymous
Hello World! |
|
|
| Report Abuse |
|
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 09 Jul 2015 10:36 PM |
*named, not anonymous
Hello World! |
|
|
| Report Abuse |
|
|
| |
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 09 Jul 2015 10:38 PM |
hmm, perhaps you're right
Hello World! |
|
|
| Report Abuse |
|
|