|
| 17 May 2017 04:05 PM |
Because I tried it in this script and it doesn't work. If it isn't then how can I fix this?
function onClick(click) local player = game.Players:GetPlayerFromCharacter(click.Parent) if player then if game.Workspace.DJBooth.Sound.Playing == false then game.ReplicatedStorage.Music:Clone().Parent = player.PlayerGui elseif game.Workspace.DJBooth.Sound.Playing == true then print("Already playing") end end end |
|
|
| Report Abuse |
|
|
|
| 17 May 2017 04:06 PM |
you need to connect the event to the function
|
|
|
| Report Abuse |
|
|
|
| 17 May 2017 04:07 PM |
WE HAVE GONE THROUGH THIS ALREADY.
SNOW ANSWERED YOUR ERROR. |
|
|
| Report Abuse |
|
|
|
| 17 May 2017 04:13 PM |
| That is not the whole script lol |
|
|
| Report Abuse |
|
|
|
| 17 May 2017 04:14 PM |
| 14:14:20.498 - Workspace.DJBooth.GuiOpener.Script:10: attempt to index local 'click' (a nil value) |
|
|
| Report Abuse |
|
|
| |
|
|
| 17 May 2017 04:28 PM |
| the click argument is a variant meaning it can be anything but also nil. So if click is nil then the argument will pass a nil value and thats where the error comes in. |
|
|
| Report Abuse |
|
|
| |
|
|
| 17 May 2017 04:29 PM |
| what event did you connect it to? |
|
|
| Report Abuse |
|
|
LowOnXTC
|
  |
| Joined: 02 Jul 2012 |
| Total Posts: 563 |
|
|
| 17 May 2017 04:42 PM |
stop bumping this, it's already been answered, you're not getting anymore answers..give up
ooga booga |
|
|
| Report Abuse |
|
|