Added MCM options for Rep content

This commit is contained in:
Wofsauge committed 2021-05-15 20:34:32 +02:00
1 parent 19369b45fd
commit 9eb1da56b5
3 files changed
+73 -9

No files matched your search

+3
View File
@@ -129,6 +129,9 @@ EID.DefaultConfig = {
-- Higher numbers can cause more lag!
-- Default = 7
["BagOfCraftingResults"] = 7,
-- Changes the number of Results shown for the additional Spindown dice description
-- Default = 3
["SpindownDiceResults"] = 3,
-- Error message displayed when an error occurs
-- Default = [Effect not defined]
+7 -7
View File
@@ -7,7 +7,7 @@ local enableDebug = false
require("eid_config")
EID.Config = EID.DefaultConfig
EID.Config.Version = "3.1"
EID.Config.Version = "3.2"
EID.isHidden = EID.Config["Hidden"]
-- general variables
@@ -388,15 +388,15 @@ local function handleBagOfCraftingRendering()
customDescObj.Description = customDescObj.Description.."# {{Collectible"..v[2].."}} ="
customDescObj.Description = customDescObj.Description..EID:tableToCraftingIconsMerged(v[1])
resultCount = resultCount + 1
if resultCount > 9 then
if #results > 10 then
customDescObj.Description = customDescObj.Description.."#{{Blank}} ...+"..(#results-10).." more"
if resultCount > EID.Config["BagOfCraftingResults"]-1 then
if #results > EID.Config["BagOfCraftingResults"] then
customDescObj.Description = customDescObj.Description.."#{{Blank}} ...+"..(#results-EID.Config["BagOfCraftingResults"]).." more"
end
break
end
end
end
if resultCount > EID.Config["BagOfCraftingResults"] then
if resultCount > EID.Config["BagOfCraftingResults"]-1 then
break
end
end
@@ -533,12 +533,12 @@ local function onRender(t)
if player:HasCollectible(723) then
descriptionObj.Description = descriptionObj.Description.."#{{Collectible723}} :"
local refID = closest.SubType
for i = 1,3 do
for i = 1,EID.Config["SpindownDiceResults"] do
local spinnedID = EID:getSpindownResult(refID)
refID = spinnedID
if spinnedID > 0 then
descriptionObj.Description = descriptionObj.Description.."{{Collectible"..spinnedID.."}}"
if i ~=3 then
if i ~= EID.Config["SpindownDiceResults"] then
descriptionObj.Description = descriptionObj.Description.." ->"
end
else
+63 -2
View File
@@ -69,7 +69,7 @@ if MCMLoaded then
---------------------------------------------------------------------------
---------------------------------General-----------------------------------
-- Language
local displayLanguage = {"English", "English (detailed)", "French", "Portuguese", "Portugues (Brasil)", "Russian", "Spanish", "Italian", "Bulgarian (WIP)", "Polish (WIP)", "German (WIP)", "Turkish (WIP)"}
local displayLanguage = {"English", "English (detailed)", "French (AB+)", "Portuguese (AB+)", "Portugues (Brasil)", "Russian", "Spanish", "Italian (AB+)", "Bulgarian (WIP) (AB+)", "Polish (WIP) (AB+)", "German (WIP) (AB+)", "Turkish (WIP) (AB+)"}
MCM.AddSetting(
"EID",
"General",
@@ -134,6 +134,27 @@ if MCMLoaded then
end
}
)
-- Disable Alt Item option
MCM.AddSetting(
"EID",
"General",
{
Type = ModConfigMenu.OptionType.BOOLEAN,
CurrentSetting = function()
return EID.Config["DisableOnAltPath"]
end,
Display = function()
local onOff = "True"
if EID.Config["DisableOnAltPath"] then
onOff = "False"
end
return 'Show hidden alt-Path Item: ' .. onOff
end,
OnChange = function(currentBool)
EID.Config["DisableOnAltPath"] = currentBool
end
}
)
--------ShowUnidentifiedPillDescriptions---------
MCM.AddSetting(
@@ -407,7 +428,47 @@ if MCMLoaded then
end
}
)
-- Spindown Dice results
local diceSteps = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}
MCM.AddSetting(
"EID",
"Display",
{
Type = ModConfigMenu.OptionType.SCROLL,
CurrentSetting = function()
return AnIndexOf(diceSteps, EID.Config["SpindownDiceResults"]) - 1
end,
Display = function()
return "Spindown Dice: $scroll" ..
AnIndexOf(diceSteps, EID.Config["SpindownDiceResults"]) - 1 .. " " .. EID.Config["SpindownDiceResults"] .. " Items"
end,
OnChange = function(currentNum)
EID.Config["SpindownDiceResults"] = diceSteps[currentNum%#diceSteps + 1]
end,
Info = {"Preview of Items resulting when using the Spindown dice X times"}
}
)
-- Bag of Crafting results
MCM.AddSetting(
"EID",
"Display",
{
Type = ModConfigMenu.OptionType.SCROLL,
CurrentSetting = function()
return AnIndexOf(diceSteps, EID.Config["BagOfCraftingResults"]) - 1
end,
Display = function()
return "Crafting bag: $scroll" ..
AnIndexOf(diceSteps, EID.Config["BagOfCraftingResults"]) - 1 .. " " .. EID.Config["BagOfCraftingResults"] .. " Results"
end,
OnChange = function(currentNum)
EID.Config["BagOfCraftingResults"] = diceSteps[currentNum%#diceSteps + 1]
end,
Info = {"Preview of items currently craftable with Bag of crafting"}
}
)
---------------------------------------------------------------------------
---------------------------------Visuals-----------------------------------
-- Font Type