diff --git a/eid_config.lua b/eid_config.lua index 31bcdd9c..c9d151cc 100644 --- a/eid_config.lua +++ b/eid_config.lua @@ -134,6 +134,9 @@ EID.UserConfig = { -- Set the mod indicator display -- Default = "Both" ["ModIndicatorDisplay"] = "Both", + -- Set the mod indicator text color + -- Default = "ColorLightOrange" + ["ModIndicatorTextColor"] = "ColorLightOrange", -------TRANSFORMATIONS--------- @@ -355,6 +358,7 @@ EID.DefaultConfig = { ["ItemNameColor"] = "ColorEIDObjName", ["ShowQuality"] = true, ["ModIndicatorDisplay"] = "Both", + ["ModIndicatorTextColor"] = "ColorLightOrange", ["ShowObjectID"] = false, ["TransformationText"] = true, ["TransformationIcons"] = true, diff --git a/main.lua b/main.lua index 5eace6c0..63abc049 100644 --- a/main.lua +++ b/main.lua @@ -376,9 +376,9 @@ function EID:printDescription(desc) if desc.ModName then if EID.Config["ModIndicatorDisplay"] == "Both" or EID.Config["ModIndicatorDisplay"] == "Name only" then - curName = curName .. " {{ColorWhite}}" .. EID.ModIndicator[desc.ModName].Name + curName = curName .. " {{"..EID.Config["ModIndicatorTextColor"].."}}" .. EID.ModIndicator[desc.ModName].Name end - if EID.Config["ModIndicatorDisplay"] == "Both" or EID.Config["ModIndicatorDisplay"] == "Icon only" and EID.ModIndicator[desc.ModName].Icon then + if (EID.Config["ModIndicatorDisplay"] == "Both" or EID.Config["ModIndicatorDisplay"] == "Icon only") and EID.ModIndicator[desc.ModName].Icon then curName = curName .. "{{".. EID.ModIndicator[desc.ModName].Icon .."}}" end end diff --git a/mod_config_menu.lua b/mod_config_menu.lua index 65424291..6a1f1be8 100644 --- a/mod_config_menu.lua +++ b/mod_config_menu.lua @@ -1563,4 +1563,28 @@ if MCMLoaded then Info = {"Changes the color of error messages like Unknown pills"} } ) + -- Mod indicator Color + MCM.AddSetting( + "EID", + "Colors", + { + Type = ModConfigMenu.OptionType.NUMBER, + CurrentSetting = function() + return AnIndexOf(colorNameArray, EID.Config["ModIndicatorTextColor"]) + end, + Minimum = 0, + Maximum = 1000, + Display = function() + if EID.Config["ModIndicatorTextColor"] == nil then EID.Config["TextColor"] = EID.DefaultConfig["ModIndicatorTextColor"] end + EID.MCMCompat_isDisplayingEIDTab = "Visuals"; + return "Mod Indicator: " .. string.gsub(EID.Config["ModIndicatorTextColor"], "Color", "").. " ("..AnIndexOf(colorNameArray, EID.Config["ModIndicatorTextColor"]).."/"..#colorNameArray..")" + end, + OnChange = function(currentNum) + if currentNum == 0 then currentNum = #colorNameArray end + if currentNum > #colorNameArray then currentNum = 1 end + EID.Config["ModIndicatorTextColor"] = colorNameArray[currentNum] + end, + Info = {"Changes the color of mod indicator texts (as long as they are enabled)."} + } + ) end