Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

The script I made does not work, it just says there and do nothing? Any fix?

Asked by 6 years ago

I'm trying to make a button when you click on it, the self destruct script enables.

This is what I made.

game.Workspace.Insdestruct.ClickDetector.MouseClick:connect(onClicked)


function onClicked()
    workspace.Check1.Disabled = true
    workspace.Check2.Disabled = true
    workspace.Check3.Disabled = true
    workspace.DelTemp.Disabled = true
    workspace.InstantMelt.Disabled = false
end

Yes there is a clickdetector included.

When I click it, it doesn't do anything?

Can someone help me?

1 answer

Log in to vote
0
Answered by
PlaasBoer 275 Moderation Voter
6 years ago
Edited 6 years ago

Lua runs from top to bottom so put the function before calling it so put it above the mouse click code.

Ad

Answer this question