Hi thanks for reading this post i appreciate your help i have a problem i want to make a ranking system that each player can rank with an gui here is the code from the server script
showhui:FireClient(plr) -- shows the buttons for ranking
for y,players in pairs(plrs) do
local gamechardacter=players.Character or players.CharacterAdded:Wait()
gamechardacter:FindFirstChild("builder").Value=false
print("i am allowed")
for i,surface in pairs(surfacess) do --surfacess is a list of the maps wich the player should rank
local points={}
local gamecharacter=players.Character or players.CharacterAdded:Wait()
local surfacespowns=surface:FindFirstChild("Spown"):GetChildren()
wait(1)
gamecharacter:FindFirstChild("HumanoidRootPart").CFrame=surfacespowns[math.random(1,#surfacespowns)].CFrame -- player will be teleporter to surface
voteevent.OnServerEvent:Connect(function(plrc,num)--when a player presses a button
votevalue=Instance.new("IntValue")
votevalue.Name="votevalue"
local playervot=plrc.Character or plrc.CharacterAdded:Wait()
if allow==true and playervot:FindFirstChild("votevalue") then
print("WE DESTROYES"..playervot.votevalue.Value)
playervot.votevalue:Destroy()
end
votevalue.Parent=playervot
votevalue.Value=num
print(playervot.votevalue.Value)
allow=true
end)
wait(10)
surface:FindFirstChild("Score").Value=surface:FindFirstChild("Score").Value+votevalue.Value--each surface has it own score
print("we are here")
print(surface:FindFirstChild("Score").Value)
--table.remove(surfaces,i)
end
end
but this doesn't work if u know why please answer this question and thanks for reading.

8 comments
Did I solve the question you asked a few minutes ago? And what errors are you getting here
yes u did
well that is the thing there is no error but it doesent run as i wantet it and how do i get the votes from all players
and then put it intu the map
sorry if i am asking to much but i really am stuck now an appreciate some help
I'm just confused with this because a few of the variables you are using haven't been instantiated anywhere
they are there in the code if u have any question question about variables just ask plrs : are all the players surfaces:A LIST OF THE MAPS THEY SHOULD RANK
they are there in the code if u have any question question about variables just ask plrs : are all the players surfaces:A LIST OF THE MAPS THEY SHOULD RANK