I'm trying to make a script that resets this loop after the 'voting' value is turned back to true. 'Voting' is a boolean value and 'votetime' is an IntValue.
voting = script.Parent.Parent.voting
votetime = script.Parent
while voting.Value == true do wait(1)
votetime.Value = votetime.Value - 1
end
I tried using the .Changed event but I can't figure out how to make it work with the boolean (attempt to index field 'value', a boolean value). Any idea on how to make this loop run again after the voting value is changed to false than true again? I'd also like to avoid constantly running a loop to check. Thanks.

1 comment
Worked just how I wanted, thanks!