diff --git a/Themes/_fallback/Scripts/03 Gameplay.lua b/Themes/_fallback/Scripts/03 Gameplay.lua index 402d6daab3..9124d4092e 100644 --- a/Themes/_fallback/Scripts/03 Gameplay.lua +++ b/Themes/_fallback/Scripts/03 Gameplay.lua @@ -231,4 +231,8 @@ function GetTapPosition( sType ) bPreference = GetUserPrefB("UserPrefNotePosition") and "Normal" or "Lower" tNotePos = tNotePositions[bPreference] return tNotePos[bCategory] +end + +function ComboUnderField() + return GetUserPrefB("UserPrefComboUnderField") end \ No newline at end of file diff --git a/Themes/_fallback/metrics.ini b/Themes/_fallback/metrics.ini index 86f4ec8eda..586d9a5ae9 100644 --- a/Themes/_fallback/metrics.ini +++ b/Themes/_fallback/metrics.ini @@ -905,7 +905,7 @@ DrawDistanceBeforeTargetsPixels=SCREEN_HEIGHT DrawDistanceAfterTargetsPixels=-128 TapJudgmentsUnderField=false HoldJudgmentsUnderField=false -ComboUnderField=true +ComboUnderField=ComboUnderField() PenalizeTapScoreNone=false JudgeHoldNotesOnSameRowTogether=(GAMESTATE:GetCurrentGame():GetName() == "pump") HoldCheckpoints=(GAMESTATE:GetCurrentGame():GetName() == "pump") diff --git a/Themes/default/Scripts/03 ThemePrefs.lua b/Themes/default/Scripts/03 ThemePrefs.lua index dc33cc848d..b6903fd1db 100644 --- a/Themes/default/Scripts/03 ThemePrefs.lua +++ b/Themes/default/Scripts/03 ThemePrefs.lua @@ -31,6 +31,9 @@ function InitUserPrefs() if GetUserPrefB("FlashyCombos") == nil then SetUserPref("FlashyCombos", false); end; + if GetUserPrefB("UserPrefComboUnderField") == nil then + SetUserPref("UserPrefComboUnderField", true); + end; --[[ if GetUserPref("ProTimingP1") == nil then SetUserPref("ProTimingP1", false); end; @@ -413,4 +416,40 @@ function UserPrefFlashyCombo() setmetatable( t, t ); return t; end + +function UserPrefComboUnderField() + local t = { + Name = "UserPrefComboUnderField"; + LayoutType = "ShowAllInRow"; + SelectType = "SelectOne"; + OneChoiceForAllPlayers = true; + ExportOnChange = false; + Choices = { 'Off','On' }; + LoadSelections = function(self, list, pn) + if ReadPrefFromFile("UserPrefComboUnderField") ~= nil then + if GetUserPrefB("UserPrefComboUnderField") then + list[2] = true; + else + list[1] = true; + end; + else + WritePrefToFile("UserPrefComboUnderField",true); + list[2] = true; + end; + end; + SaveSelections = function(self, list, pn) + local val; + if list[2] then + val = true; + else + val = false; + end; + WritePrefToFile("UserPrefComboUnderField",val); + MESSAGEMAN:Broadcast("PreferenceSet", { Message == "Set Preference" } ); + THEME:ReloadMetrics(); + end; + }; + setmetatable( t, t ); + return t; +end --[[ end option rows ]] \ No newline at end of file diff --git a/Themes/default/metrics.ini b/Themes/default/metrics.ini index ccf50c317b..969cb912f4 100644 --- a/Themes/default/metrics.ini +++ b/Themes/default/metrics.ini @@ -776,7 +776,7 @@ ItemsLongRowSharedX=SCREEN_CENTER_X [ScreenOptionsTheme] Fallback="ScreenOptionsServiceChild" -LineNames="gNotePos,gAuto,gScore,gSDisp,gOpts,gLongFail,FlashyCombo" +LineNames="gNotePos,gAuto,gScore,gSDisp,gOpts,gLongFail,gComboUnderField,FlashyCombo" #,gAuto LinegNotePos="lua,UserPrefNotePosition()" LinegScore="lua,UserPrefGameplayShowScore()" @@ -784,6 +784,7 @@ LinegSDisp="lua,UserPrefGameplayShowStepsDisplay()" LinegOpts="lua,UserPrefShowLotsaOptions()" LinegAuto="lua,UserPrefAutoSetStyle()" LinegLongFail="lua,UserPrefLongFail()" +LinegComboUnderField="lua,UserPrefComboUnderField()" LineFlashyCombo="lua,UserPrefFlashyCombo()" [ScreenOptionsSystemDirection]