/ perc get in chal result
This commit is contained in:
parent
dced5cabb6
commit
e5d00ae0a2
|
@ -58,6 +58,7 @@ local gradeImages = {
|
||||||
}
|
}
|
||||||
|
|
||||||
local percRequired = 1;
|
local percRequired = 1;
|
||||||
|
local percGet = 0;
|
||||||
|
|
||||||
-- AUDIO
|
-- AUDIO
|
||||||
game.LoadSkinSample("challenge_result.wav")
|
game.LoadSkinSample("challenge_result.wav")
|
||||||
|
@ -236,11 +237,11 @@ function drawCompletion()
|
||||||
gfx.BeginPath()
|
gfx.BeginPath()
|
||||||
gfx.ImageRect(63, 1331, 766*0.85, 130*0.85, completitionImage, 1, 0)
|
gfx.ImageRect(63, 1331, 766*0.85, 130*0.85, completitionImage, 1, 0)
|
||||||
|
|
||||||
draw_number(925, 1370, 1.0, result.avgPercentage, 3, scoreNumber, true, 0.3, 1.12)
|
draw_number(925, 1370, 1.0, percGet, 3, scoreNumber, true, 0.3, 1.12)
|
||||||
|
|
||||||
|
|
||||||
gfx.BeginPath();
|
gfx.BeginPath();
|
||||||
gfx.Rect(741, 1402, 278*math.min(1, result.avgPercentage / percRequired), 6);
|
gfx.Rect(741, 1402, 278*math.min(1, percGet / percRequired), 6);
|
||||||
gfx.FillColor(255, 128, 0, 255);
|
gfx.FillColor(255, 128, 0, 255);
|
||||||
gfx.Fill()
|
gfx.Fill()
|
||||||
end
|
end
|
||||||
|
@ -256,6 +257,13 @@ function result_set()
|
||||||
end
|
end
|
||||||
|
|
||||||
game.Log(percRequired, game.LOGGER_ERROR);
|
game.Log(percRequired, game.LOGGER_ERROR);
|
||||||
|
|
||||||
|
local a = 0;
|
||||||
|
for i, chart in ipairs(result.charts) do
|
||||||
|
a = a + chart.percent;
|
||||||
|
game.Log('#' .. i .. ' got ' .. chart.percent .. '% // ACC at ' .. a, game.LOGGER_ERROR);
|
||||||
|
end
|
||||||
|
percGet = a / #result.charts;
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue