@@ -13,6 +13,12 @@ local rate = getCurRate()
1313local judge = (PREFSMAN :GetPreference (" SortBySSRNormPercent" ) and 4 or GetTimingDifficulty ())
1414local offsetIndex
1515
16+ local function clampJudge ()
17+ if judge < 4 then judge = 4 end
18+ if judge > 9 then judge = 9 end
19+ end
20+ clampJudge ()
21+
1622-- Reset preview music starting point since song was finished.
1723GHETTOGAMESTATE :setLastPlayedSecond (0 )
1824
@@ -32,6 +38,17 @@ local offsetWidth2 = 0
3238local offsetHeight2 = 0
3339local offsetisLocal
3440
41+ local function getRescoreElements (pss , score )
42+ local o = {}
43+ o [" dvt" ] = dvt
44+ o [" totalHolds" ] = pss :GetRadarPossible ():GetValue (" RadarCategory_Holds" ) + pss :GetRadarPossible ():GetValue (" RadarCategory_Rolls" )
45+ o [" holdsHit" ] = score :GetRadarValues ():GetValue (" RadarCategory_Holds" ) + score :GetRadarValues ():GetValue (" RadarCategory_Rolls" )
46+ o [" holdsMissed" ] = o [" totalHolds" ] - o [" holdsHit" ]
47+ o [" minesHit" ] = pss :GetRadarPossible ():GetValue (" RadarCategory_Mines" ) - score :GetRadarValues ():GetValue (" RadarCategory_Mines" )
48+ o [" totalTaps" ] = totalTaps
49+ return o
50+ end
51+
3552local function scroller (event )
3653 if event .type == " InputEventType_FirstPress" then
3754 if event .DeviceInput .button == " DeviceButton_mousewheel up" then
@@ -72,32 +89,19 @@ local function oldEvalStuff()
7289 }
7390 t [# t + 1 ] = Def .ActorFrame {
7491 OffsetPlotModificationMessageCommand = function (self , params )
75- local score = pss :GetHighScore ()
76- local totalHolds =
77- pss :GetRadarPossible ():GetValue (" RadarCategory_Holds" ) + pss :GetRadarPossible ():GetValue (" RadarCategory_Rolls" )
78- local holdsHit =
79- pss :GetRadarActual ():GetValue (" RadarCategory_Holds" ) + pss :GetRadarActual ():GetValue (" RadarCategory_Rolls" )
80- local minesHit =
81- pss :GetRadarPossible ():GetValue (" RadarCategory_Mines" ) - pss :GetRadarActual ():GetValue (" RadarCategory_Mines" )
82- if enabledCustomWindows then
83- if params .Name == " PrevJudge" then
84- judge = judge < 2 and # customWindows or judge - 1
85- customWindow = timingWindowConfig :get_data ()[customWindows [judge ]]
86- rescoredPercentage = getRescoredCustomPercentage (dvt , customWindow , totalHolds , holdsHit , minesHit , totalTaps )
87- elseif params .Name == " NextJudge" then
88- judge = judge == # customWindows and 1 or judge + 1
89- customWindow = timingWindowConfig :get_data ()[customWindows [judge ]]
90- rescoredPercentage = getRescoredCustomPercentage (dvt , customWindow , totalHolds , holdsHit , minesHit , totalTaps )
91- end
92- elseif params .Name == " PrevJudge" and judge > 1 then
92+ local rst = getRescoreElements (pss , pss :GetHighScore ())
93+ if params .Name == " PrevJudge" and judge > 1 then
9394 judge = judge - 1
94- rescoredPercentage = getRescoredWifeJudge (dvt , judge , totalHolds - holdsHit , minesHit , totalTaps )
95+ clampJudge ()
96+ rescoredPercentage = getRescoredWife3Judge (3 , judge , rst )
9597 elseif params .Name == " NextJudge" and judge < 9 then
9698 judge = judge + 1
97- rescoredPercentage = getRescoredWifeJudge (dvt , judge , totalHolds - holdsHit , minesHit , totalTaps )
99+ clampJudge ()
100+ rescoredPercentage = getRescoredWife3Judge (3 , judge , rst )
98101 end
99102 if params .Name == " ResetJudge" then
100- judge = enabledCustomWindows and 0 or (PREFSMAN :GetPreference (" SortBySSRNormPercent" ) and 4 or GetTimingDifficulty ())
103+ judge = PREFSMAN :GetPreference (" SortBySSRNormPercent" ) and 4 or GetTimingDifficulty ()
104+ clampJudge ()
101105 self :GetParent ():playcommand (" ResetJudge" )
102106 elseif params .Name ~= " ToggleHands" then
103107 self :GetParent ():playcommand (" SetJudge" , params )
@@ -267,21 +271,7 @@ local function oldEvalStuff()
267271 end
268272 end ,
269273 SetJudgeCommand = function (self , params )
270- if enabledCustomWindows then
271- if rescoredPercentage > 99 then
272- self :settextf (
273- " %05.4f%% (%s)" ,
274- rescoredPercentage ,
275- customWindow .name
276- )
277- else
278- self :settextf (
279- " %05.2f%% (%s)" ,
280- rescoredPercentage ,
281- customWindow .name
282- )
283- end
284- elseif params .Name == " PrevJudge" and judge >= 1 then
274+ if params .Name == " PrevJudge" and judge >= 1 then
285275 if rescoredPercentage > 99 then
286276 self :settextf (
287277 " %05.4f%% (%s)" ,
@@ -413,16 +403,10 @@ local function oldEvalStuff()
413403
414404 local tst = ms .JudgeScalers
415405 local tso = tst [judge ]
416- if enabledCustomWindows then
417- tso = 1
418- end
419406 local ncol = GAMESTATE :GetCurrentSteps (PLAYER_1 ):GetNumColumns () - 1
420407 local middleCol = ncol / 2
421408 local function recountCBs ()
422409 tso = tst [judge ]
423- if enabledCustomWindows then
424- tso = 1
425- end
426410 cbl = 0
427411 cbr = 0
428412 cbm = 0
@@ -781,14 +765,14 @@ local function oldEvalStuff()
781765 end ,
782766 SetCommand = function (self )
783767 if PREFSMAN :GetPreference (" SortBySSRNormPercent" ) then
784- self :settextf (" %s - %s J4" , THEME :GetString (" ScreenEvaluation" ," CategoryScore" ), getScoreTypeText (1 ))
768+ self :settextf (" %s - %s%d J4" , THEME :GetString (" ScreenEvaluation" ," CategoryScore" ), getScoreTypeText (1 ), curScore : GetWifeVers ( ))
785769 else
786- self :settextf (" %s - %s" , THEME :GetString (" ScreenEvaluation" ," CategoryScore" ), getScoreTypeText (1 ))
770+ self :settextf (" %s - %s%d " , THEME :GetString (" ScreenEvaluation" ," CategoryScore" ), getScoreTypeText (1 ), curScore : GetWifeVers ( ))
787771 end
788772 end ,
789773 SetJudgeCommand = function (self )
790774 local jdg = (PREFSMAN :GetPreference (" SortBySSRNormPercent" ) and 4 or GetTimingDifficulty ())
791- self :settextf (" %s - %s J%d" , THEME :GetString (" ScreenEvaluation" , " CategoryScore" ), getScoreTypeText (1 ), jdg )
775+ self :settextf (" %s - %s3 J%d" , THEME :GetString (" ScreenEvaluation" , " CategoryScore" ), getScoreTypeText (1 ), jdg )
792776 end ,
793777 ResetJudgeCommand = function (self )
794778 self :playcommand (" Set" )
@@ -1040,11 +1024,7 @@ local function oldEvalStuff()
10401024 self :settext (pss :GetTapNoteScores (v ))
10411025 end ,
10421026 SetJudgeCommand = function (self )
1043- if enabledCustomWindows then
1044- self :settext (getRescoredCustomJudge (dvt , customWindow .judgeWindows , k ))
1045- else
1046- self :settext (getRescoredJudge (dvt , judge , k ))
1047- end
1027+ self :settext (getRescoredJudge (dvt , judge , k ))
10481028 end ,
10491029 ResetJudgeCommand = function (self )
10501030 self :playcommand (" Set" )
@@ -1065,11 +1045,7 @@ local function oldEvalStuff()
10651045 self :settextf (" (%.2f%%)" ,math.floor (percent * 10000 )/ 100 )
10661046 end ,
10671047 SetJudgeCommand = function (self )
1068- if enabledCustomWindows then
1069- self :settextf (" (%.2f%%)" , getRescoredCustomJudge (dvt , customWindow .judgeWindows , k ) / totalTaps * 100 )
1070- else
1071- self :settextf (" (%.2f%%)" , getRescoredJudge (dvt , judge , k ) / totalTaps * 100 )
1072- end
1048+ self :settextf (" (%.2f%%)" , getRescoredJudge (dvt , judge , k ) / totalTaps * 100 )
10731049 end ,
10741050 ResetJudgeCommand = function (self )
10751051 self :playcommand (" Set" )
@@ -2427,9 +2403,6 @@ local function newEvalStuff()
24272403
24282404 local tst = ms .JudgeScalers
24292405 local tso = tst [judge ]
2430- if enabledCustomWindows then
2431- tso = 1
2432- end
24332406 local ncol = GAMESTATE :GetCurrentSteps (PLAYER_1 ):GetNumColumns () - 1
24342407 local middleCol = ncol / 2
24352408 local function recountCBs ()
@@ -2534,13 +2507,8 @@ local function newEvalStuff()
25342507 percent = pss :GetPercentageOfTaps (thisJudgment ) * 100
25352508 end ,
25362509 SetJudgeCommand = function (self )
2537- if enabledCustomWindows then
2538- percent = getRescoredCustomJudge (dvt , customWindow .judgeWindows , i ) / totalTaps * 100
2539- count = getRescoredCustomJudge (dvt , customWindow .judgeWindows , i )
2540- else
2541- percent = getRescoredJudge (dvt , judge , i ) / totalTaps * 100
2542- count = getRescoredJudge (dvt , judge , i )
2543- end
2510+ percent = getRescoredJudge (dvt , judge , i ) / totalTaps * 100
2511+ count = getRescoredJudge (dvt , judge , i )
25442512 end ,
25452513 ResetJudgeCommand = function (self )
25462514 count = pss :GetHighScore ():GetTapNoteScore (thisJudgment )
@@ -2867,8 +2835,9 @@ local function newEvalStuff()
28672835 self :zoom (biggerTextScale )
28682836 self :maxwidth (frameWidth / 4 / biggerTextScale )
28692837 self :settext (" " )
2838+ self :playcommand (" Begin" )
28702839 end ,
2871- BeginCommand = function (self )
2840+ BeginCommand = function (self )
28722841 local wifeScore = pss :GetHighScore ():GetWifeScore ()
28732842 if wifeScore > 0.99 then
28742843 self :settextf (" %.4f%%" ,math.floor ((wifeScore )* 1000000 )/ 10000 )
@@ -2877,26 +2846,40 @@ local function newEvalStuff()
28772846 end
28782847 end ,
28792848 SetJudgeCommand = function (self , params )
2880- if enabledCustomWindows then
2881- if rescoredPercentage > 99 then
2882- self :settextf (" %05.4f%% (%s)" , rescoredPercentage , customWindow .name )
2883- else
2884- self :settextf (" %05.2f%% (%s)" , rescoredPercentage , customWindow .name )
2885- end
2849+ if rescoredPercentage > 99 then
2850+ self :settextf (" %05.4f%%" , rescoredPercentage )
28862851 else
2887-
2888- if rescoredPercentage > 99 then
2889- self :settextf (" %05.4f%%" , rescoredPercentage )
2890- else
2891- self :settextf (" %05.2f%%" , rescoredPercentage )
2892- end
2852+ self :settextf (" %05.2f%%" , rescoredPercentage )
28932853 end
28942854 end ,
28952855 ResetJudgeCommand = function (self )
28962856 self :playcommand (" Begin" )
28972857 end
28982858 },
2899- LoadFont (" Common Normal" ).. {
2859+ LoadFont (" Common Normal" ) .. {
2860+ Name = " WifeVersion" ,
2861+ InitCommand = function (self )
2862+ self :halign (0 )
2863+ self :y (upperDivider1Y + dividerHeight / 2 + (frameHeight * gradeSectionReferenceRatio / 5 * 3.4 ))
2864+ self :zoom (smallerTextScale )
2865+ self :maxwidth (frameWidth / 4 / smallerTextScale )
2866+ self :settext (" " )
2867+ end ,
2868+ PlaceCommand = function (self )
2869+ local xpos = 2 + self :GetParent ():GetChild (" WifePercent" ):GetZoomedWidth () / 2
2870+ self :x (xpos )
2871+ end ,
2872+ BeginCommand = function (self )
2873+ self :playcommand (" Place" )
2874+ local vers = pss :GetHighScore ():GetWifeVers ()
2875+ self :settextf (" Wife%d" , vers )
2876+ end ,
2877+ SetJudgeCommand = function (self , params )
2878+ self :playcommand (" Place" )
2879+ self :settextf (" Wife3" )
2880+ end
2881+ },
2882+ LoadFont (" Common Normal" ) .. {
29002883 Name = " Grade" ,
29012884 InitCommand = function (self )
29022885 self :halign (1 )
@@ -2961,9 +2944,6 @@ local function newEvalStuff()
29612944 end ,
29622945 SetJudgeCommand = function (self )
29632946 tso = tst [judge ]
2964- if enabledCustomWindows then
2965- tso = 1
2966- end
29672947 recountCBs ()
29682948 self :queuecommand (" Set" )
29692949 end ,
0 commit comments