From 2dd0c264da7f2af6a700d87a6b543c03cc8ba556 Mon Sep 17 00:00:00 2001 From: AJ Kelly Date: Sun, 7 Aug 2011 18:27:15 -0500 Subject: [PATCH] fix error --- Themes/default/Graphics/ScreenEvaluation MachineRecord.lua | 7 +++++-- .../default/Graphics/ScreenEvaluation PersonalRecord.lua | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/Themes/default/Graphics/ScreenEvaluation MachineRecord.lua b/Themes/default/Graphics/ScreenEvaluation MachineRecord.lua index 3bb840190e..0d2e63dbdd 100644 --- a/Themes/default/Graphics/ScreenEvaluation MachineRecord.lua +++ b/Themes/default/Graphics/ScreenEvaluation MachineRecord.lua @@ -5,7 +5,10 @@ local record = stats:GetMachineHighScoreIndex() local hasMachineRecord = record ~= -1 return LoadFont("Common normal")..{ - Text=string.format(THEME:GetString("ScreenEvaluation", "MachineRecord"), record+1); InitCommand=cmd(zoom,0.55;shadowlength,1;NoStroke;glowshift;effectcolor1,color("1,1,1,0");effectcolor2,color("1,1,1,0.25")); - BeginCommand=cmd(visible,hasMachineRecord;); + BeginCommand=function(self) + self:visible(hasMachineRecord;); + local text = string.format(THEME:GetString("ScreenEvaluation", "MachineRecord"), record+1) + self:settext(text); + end; }; \ No newline at end of file diff --git a/Themes/default/Graphics/ScreenEvaluation PersonalRecord.lua b/Themes/default/Graphics/ScreenEvaluation PersonalRecord.lua index af97bcb2cc..7a0633c624 100644 --- a/Themes/default/Graphics/ScreenEvaluation PersonalRecord.lua +++ b/Themes/default/Graphics/ScreenEvaluation PersonalRecord.lua @@ -5,7 +5,10 @@ local record = stats:GetPersonalHighScoreIndex() local hasPersonalRecord = record ~= -1 return LoadFont("Common normal")..{ - Text=string.format(THEME:GetString("ScreenEvaluation", "PersonalRecord"), record+1) InitCommand=cmd(zoom,0.55;shadowlength,1;NoStroke;glowshift;effectcolor1,color("1,1,1,0");effectcolor2,color("1,1,1,0.25")); - BeginCommand=cmd(visible,hasPersonalRecord;); + BeginCommand=function(self) + self:visible(hasPersonalRecord;); + local text = string.format(THEME:GetString("ScreenEvaluation", "PersonalRecord"), record+1) + self:settext(text) + end }; \ No newline at end of file