I made it few monts ago. Anyway, I don't use it
1. Add this at beginning of racevoting_server.lua in race resource
local timesMapPlayed = 0
local lastMapPlayed = 0
2. REPLACE this
if currentMap then
table.insert(poll, {"Play again", 'nextMapVoteResult', getRootElement(), currentMap})
end
WITH this
if currentMap ~= lastMapPlayed then
timesMapPlayed = 1
lastMapPlayed = currentMap
end
if currentMap and timesMapPlayed <= 2 then -- map could be played max. 3 times in row
timesMapPlayed = timesMapPlayed + 1
table.insert(poll, {"Play again", 'nextMapVoteResult', getRootElement(), currentMap})
end
It may work. At least it works for me