|
| 26 Nov 2011 11:29 AM |
I got a simple vote GUI here and the first time I click on the button line 5 is ignored but every other time after that it runs fine, any ideas?
a=script.Parent
function Click() if a.Voted.Value==false then game.Workspace.Votes.Value = game.Workspace.Votes.Value + 1 a.Voted.Value = true wait(1) end end
script.Parent.MouseButton1Down:connect(Click)
|
|
|
| Report Abuse |
|
|
MrChubbs
|
  |
| Joined: 14 Oct 2010 |
| Total Posts: 4969 |
|
|
| 26 Nov 2011 11:34 AM |
function MrChubbsissocoool() if script.Parent.Voted.Value == false then -- Are you sure its a bool? print("Gate One"..script.Parent.Voted.Value) game.Workspace.Votes.Value = game.Workspace.Votes.Value + 1 script.Parent.Voted.Value = true wait(1) end print("Gate One failed the value is: "..script.Parent.Voted.Value) end
script.Parent.MouseButton1Click:connect(MrChubbsissocoool)
|
|
|
| Report Abuse |
|
|
|
| 26 Nov 2011 11:39 AM |
| If it wasn't a bool the script would not work at all it just skips the line that adds the votes once. |
|
|
| Report Abuse |
|
|
|
| 26 Nov 2011 11:59 AM |
| So is it just a bug or can it be fixed? |
|
|
| Report Abuse |
|
|