Basically, I'm trying to check if there's one player left in a round by using the MatchActive value to check if the match is currently underway. The only problem is, this code doesn't change the value of MatchActive. At first, I just tried using MatchActive, then I switched to MatchActive.Value and it still doesn't work. Any suggestions?
MatchStart.Event:Connect(function() local MatchState = MatchActive.Value MatchState = true print(MatchState) end) MatchEnd.Event:Connect(function() local MatchState = MatchActive.Value MatchState = false print(MatchState) end)
I set MatchState to false before the game. I am using a constantly running print statement to monitor it, and it remains false.
Oh, also, you could just make one bindable and pass arguments through it. Instead of having two binds.
Example:
local MatchController = Where ever the bind is located in. MatchController.Event:Connect(function(argument) MatchActive.Value = argument print(MatchActive.Value) end)