make the menu timer show decimal places

This commit is contained in:
AJ Kelly
2012-01-08 19:00:28 -06:00
parent 4b5baa37ce
commit 321faf8dfc
+6 -4
View File
@@ -199,11 +199,13 @@ RightOnCommand=horizalign,left;diffuse,PlayerColor(PLAYER_1)
LeftOnCommand=horizalign,right;diffuse,PlayerColor(PLAYER_2)
MiddleOnCommand=;diffuse,PlayerColor(PLAYER_2)
RightOnCommand=horizalign,left;diffuse,PlayerColor(PLAYER_2)
[MenuTimer]
Text1OnCommand=stopeffect;stoptweening;shadowlength,0;strokecolor,Color("Outline")
Text1FormatFunction=function(fSeconds) \
return string.format("%0.1f", fSeconds); \
end
Text1OnCommand=stopeffect;stoptweening;halign,1;shadowlength,0;strokecolor,Color("Outline")
Text1FormatFunction=function(fSeconds) fSeconds=math.floor(fSeconds); return string.format("%02.0f",fSeconds) end
Text2OnCommand=x,2;y,-3;stopeffect;stoptweening;halign,0;shadowlength,0;strokecolor,Color("Outline");zoom,0.65
Text2FormatFunction=function(fSeconds) local remainder=fSeconds-math.floor(fSeconds); local digit=math.floor(remainder*100); return string.format("%02.0f",digit) end
Warning10Command=diffuseshift;effectperiod,1;effectcolor2,Color("Red");effectcolor1,color("0.5,0,0,1");