ItemReminder: Flipped up/down navigation buttons to make it more intuitive to use
This commit is contained in:
1 parent
038d50ae68
commit
0635e3436e
2 files changed
+18
-14
No files matched your search
+7
-7
@@ -337,18 +337,18 @@ EID.UserConfig = {
|
||||
-- Look into the AB+ or Repentance documentation for the key names here: https://wofsauge.github.io/IsaacDocs/rep/enums/ButtonAction.html
|
||||
-- Default = ButtonAction.ACTION_SHOOTLEFT
|
||||
["ItemReminderNavigateRightButton"] = ButtonAction.ACTION_SHOOTRIGHT,
|
||||
-- Set the keybinding that is used to scroll thru the players in the left direction
|
||||
-- Look into the AB+ or Repentance documentation for the key names here: https://wofsauge.github.io/IsaacDocs/rep/enums/ButtonAction.html
|
||||
-- Default = ButtonAction.ACTION_SHOOTDOWN
|
||||
["ItemReminderNavigateDownButton"] = ButtonAction.ACTION_SHOOTDOWN,
|
||||
-- Number of entries to display per category of the item description.
|
||||
-- Set the keybinding that is used to scroll thru the players in the right direction
|
||||
-- Set the keybinding that is used to scroll thru the players or item entries in the left direction
|
||||
-- Look into the AB+ or Repentance documentation for the key names here: https://wofsauge.github.io/IsaacDocs/rep/enums/ButtonAction.html
|
||||
-- Default = ButtonAction.ACTION_SHOOTUP
|
||||
["ItemReminderNavigateUpButton"] = ButtonAction.ACTION_SHOOTUP,
|
||||
-- Set the keybinding that is used to scroll thru the players or item entries in the right direction
|
||||
-- Look into the AB+ or Repentance documentation for the key names here: https://wofsauge.github.io/IsaacDocs/rep/enums/ButtonAction.html
|
||||
-- Default = ButtonAction.ACTION_SHOOTDOWN
|
||||
["ItemReminderNavigateDownButton"] = ButtonAction.ACTION_SHOOTDOWN,
|
||||
-- Limits the number of description bullet points to be displayed on the overview page for each item
|
||||
-- Default = 2
|
||||
["ItemReminderOverviewHideAfterRows"] = 2,
|
||||
-- Number of entries to display per category of the item description.
|
||||
-- Default = 3
|
||||
["ItemReminderMaxEntriesCount"] = 3,
|
||||
-- Items that grant you items without saying what they are (like Zodiac, Liberty Cap) can have their current granted item revealed in the Item Reminder
|
||||
@@ -603,8 +603,8 @@ EID.DefaultConfig = {
|
||||
["BagOfCraftingToggleKey"] = ButtonAction.ACTION_MAP,
|
||||
["ItemReminderNavigateLeftButton"] = ButtonAction.ACTION_SHOOTLEFT,
|
||||
["ItemReminderNavigateRightButton"] = ButtonAction.ACTION_SHOOTRIGHT,
|
||||
["ItemReminderNavigateDownButton"] = ButtonAction.ACTION_SHOOTDOWN,
|
||||
["ItemReminderNavigateUpButton"] = ButtonAction.ACTION_SHOOTUP,
|
||||
["ItemReminderNavigateDownButton"] = ButtonAction.ACTION_SHOOTDOWN,
|
||||
["ItemReminderOverviewHideAfterRows"] = 2,
|
||||
["ItemReminderMaxEntriesCount"] = 5,
|
||||
["ItemReminderShowHiddenInfo"] = false,
|
||||
|
||||
+11
-7
@@ -433,8 +433,8 @@ function EID:ItemReminderHandleInputs()
|
||||
EID.ForceRefreshCache = true
|
||||
lastInputTime = Isaac.GetTime()
|
||||
lastScrollDirection = 1
|
||||
elseif Input.IsActionTriggered(EID.Config["ItemReminderNavigateDownButton"], EID.holdTabPlayer.ControllerIndex) and Isaac.GetTime() - lastInputTime > 50 then
|
||||
if not EID:IsCategorySelected("Passives") then
|
||||
elseif Input.IsActionTriggered(EID.Config["ItemReminderNavigateUpButton"], EID.holdTabPlayer.ControllerIndex) and Isaac.GetTime() - lastInputTime > 50 then
|
||||
if not EID:IsScrollableCategorySelected() then
|
||||
EID.ItemReminderSelectedPlayer = (EID.ItemReminderSelectedPlayer - 1) % #EID.coopAllPlayers
|
||||
else
|
||||
EID.ItemReminderSelectedItem = EID.ItemReminderSelectedItem - 1 -- clamp later
|
||||
@@ -442,8 +442,8 @@ function EID:ItemReminderHandleInputs()
|
||||
|
||||
EID.ForceRefreshCache = true
|
||||
lastInputTime = Isaac.GetTime()
|
||||
elseif Input.IsActionTriggered(EID.Config["ItemReminderNavigateUpButton"], EID.holdTabPlayer.ControllerIndex) and Isaac.GetTime() - lastInputTime > 50 then
|
||||
if not EID:IsCategorySelected("Passives") then
|
||||
elseif Input.IsActionTriggered(EID.Config["ItemReminderNavigateDownButton"], EID.holdTabPlayer.ControllerIndex) and Isaac.GetTime() - lastInputTime > 50 then
|
||||
if not EID:IsScrollableCategorySelected() then
|
||||
EID.ItemReminderSelectedPlayer = (EID.ItemReminderSelectedPlayer + 1) % #EID.coopAllPlayers
|
||||
else
|
||||
EID.ItemReminderSelectedItem = EID.ItemReminderSelectedItem + 1 -- clamp later
|
||||
@@ -455,6 +455,10 @@ function EID:ItemReminderHandleInputs()
|
||||
end
|
||||
end
|
||||
|
||||
function EID:IsScrollableCategorySelected()
|
||||
return EID.ItemReminderCategories[EID.ItemReminderSelectedCategory + 1].isScrollable
|
||||
end
|
||||
|
||||
function EID:IsCategorySelected(categoryID)
|
||||
return EID.ItemReminderCategories[EID.ItemReminderSelectedCategory + 1].id == categoryID
|
||||
end
|
||||
@@ -499,9 +503,9 @@ function EID:ItemReminderGetTitle()
|
||||
local playerIcon = EID:GetPlayerIcon(currentPlayer:GetPlayerType(), "P" .. curPlayerID )
|
||||
|
||||
local playerSelectWidget = playerIcon .. " "
|
||||
if not EID:IsCategorySelected("Passives") and EID.Config["ItemReminderDisplayMode"] ~= "Classic" then
|
||||
playerSelectWidget = EID.ButtonToIconMap[EID.Config["ItemReminderNavigateDownButton"]] ..
|
||||
playerIcon .. EID.ButtonToIconMap[EID.Config["ItemReminderNavigateUpButton"]] .. "|"
|
||||
if not EID:IsScrollableCategorySelected() and EID.Config["ItemReminderDisplayMode"] ~= "Classic" then
|
||||
playerSelectWidget = EID.ButtonToIconMap[EID.Config["ItemReminderNavigateUpButton"]] ..
|
||||
playerIcon .. EID.ButtonToIconMap[EID.Config["ItemReminderNavigateDownButton"]] .. "|"
|
||||
end
|
||||
combinedText = "{{ColorText}}" .. playerSelectWidget .. combinedText
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user