#Trying to make a ready button but i cant figure it out
6 messages · Page 1 of 1 (latest)
idk
You could just do it with a loop, checking if any value inside an array is false, yet this is not all that efficient so what I would do:
local AmountOfNotReady = --amount of players you've to wait for
RemoteEvent.OnServerEvent...function(Player:Player, IsReady:Boolean)
--Add some stuff to visualize player being ready or not ready
AmountOfNotReady += IsReady and -1 or 1
if AmountOfNotReady ~= 0 then return end
--add code here that has to trigger when all people are ready
end)
ty dawg
inb4 where do i put that
?