-- Get a reference to the Fashion Show
local fashionShow = game.ReplicatedStorage.FashionShow
-- Get the current time
local currentTime = tick()
-- Get the total number of votes in the game
local totalVotes = #fashionShow.Votes
-- Loop through the players to get their vote scores
for _, player in ipairs(game.Players:GetChildren()) do
local voteScore = fashionShow.Votes[player.UserId]
totalVotes = totalVotes - voteScore
end
-- Calculate the time between each vote
local timeBetweenVotes = (tick() - currentTime) // totalVotes
-- Set the vote score to 5 for the current player
fashionShow.Votes[game.Players.LocalPlayer.UserId] = 5
-- Fire the Voting remote, casting a vote for the current player
game.ReplicatedStorage.FashionShow.Remotes.Voting:FireServer(1)
-- Simulate time passing so the other players can vote
wait(timeBetweenVotes)
-- Clear out all the vote scores
for _, vote in pairs(fashionShow.Votes) do
fashionShow.Votes[vote] = nil
end
To embed this project on your website, copy the following code and paste it into your website's HTML: