madattak
|
  |
| Joined: 07 Aug 2008 |
| Total Posts: 2924 |
|
|
| 14 May 2014 02:37 PM |
I think the title explains all. Excuse my horrible naming.
FinDetFunc = Instance.new("BindableFunction") FinDetFunc.Name = "FinDetFunc" FinDetFunc.Parent = script function TallyFinishers(Player,Time) PlayersFinished = PlayersFinished +1 PlayersFinishedTable[PlayersFinished] = Player TimesTable[PlayersFinished] = Time end FinDetFunc.OnInvoke:Connect(TallyFinishers) |
|
|
| Report Abuse |
|
|
|
| 14 May 2014 02:44 PM |
OnInvoke is a callback, not an event. Use this:
FinDetFunc = Instance.new("BindableFunction") FinDetFunc.Name = "FinDetFunc" FinDetFunc.Parent = script FinDetFunc.OnInvoke = function(Player,Time) PlayersFinished = PlayersFinished +1 PlayersFinishedTable[PlayersFinished] = Player TimesTable[PlayersFinished] = Time end
Then you can invoke it like this: FinDetFunc:Invoke(player, time) --Change player to your player variable, and time to the time.
Here's my siggy... Done. |
|
|
| Report Abuse |
|
|
madattak
|
  |
| Joined: 07 Aug 2008 |
| Total Posts: 2924 |
|
| |
|
|
| 14 May 2014 03:58 PM |
No problem.
Here's my siggy... Done. |
|
|
| Report Abuse |
|
|