So I wanted to make a text button to unanchor dice for a dice game. I have scripted something but it's not working.
local Dice1 = game.Workspace.Dices.Dice1 local Dice2 = game.Workspace.Dices.Dice2
script.Parent.MouseButton1Click:Connect (function() Dice1.Anchored = false
1 | Wait( 0.5 ) |
2 |
3 | Dice 2. Anchored = false |
End)
I think your script is a bit wrong: at line before 1, there is a space between :Connect and (function() and at the end
So i think my script would work (if not, tell me. I'm still noob :v)
1 | local Dice 1 = game.Workspace.Dices.Dice 1 |
2 | local Dice 2 = game.Workspace.Dices.Dice 2 |
3 |
4 | script.Parent.MouseButton 1 Click:Connect( function () |
5 | Dice 1. Anchored = false |
6 | wait( 0.5 ) |
7 | Dice 2. Anchored = false |
8 | end ) |
I don't know if this is the problem but maybe turn End)
into end)
(no caps).