Skip to content

Commit

Permalink
Config cleaning up of mounts
Browse files Browse the repository at this point in the history
  • Loading branch information
DerpleMQ2 committed Jan 14, 2024
1 parent 4921501 commit 58c84fd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion extras/version.lua
Original file line number Diff line number Diff line change
@@ -1 +1 @@
return { commitId = 'a45a112 2024-01-13' }
return { commitId = '4921501 2024-01-13' }
2 changes: 1 addition & 1 deletion utils/rgmercs_config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ for k, v in pairs(Config.ExpansionNameToID) do Config.ExpansionIDToName[v] = k e
Config.DefaultConfig = {
-- [ UTILITIES ] --
['MountItem'] = { DisplayName = "Mount Item", Category = "Utilities", Tooltip = "Item to use to cast Mount", Type = "ClickyItem", Default = "", ConfigType = "Normal", },
['DoMount'] = { DisplayName = "Do Mount", Category = "Utilities", Tooltip = "0 = Disabled, 1 = Enabled, 2 = Dismount but Keep Buff", Default = 0, Min = 0, Max = 2, ConfigType = "Normal", },
['DoMount'] = { DisplayName = "Do Mount", Category = "Utilities", Tooltip = "0 = Disabled, 1 = Enabled, 2 = Dismount but Keep Buff", Type = "Combo", ComboOptions = { 'Off', 'Mount', 'Buff Only', }, Default = 1, Min = 1, Max = 3, ConfigType = "Normal", },
['ShrinkItem'] = { DisplayName = "Shrink Item", Category = "Utilities", Tooltip = "Item to use to Shrink yourself", Type = "ClickyItem", Default = "", ConfigType = "Normal", },
['DoShrink'] = { DisplayName = "Do Shrink", Category = "Utilities", Tooltip = "Enable auto shrinking", Default = false, ConfigType = "Normal", },
['PriorityHealing'] = { DisplayName = "Priority Healing", Category = "Utilities", Tooltip = "Prioritize Healing over Combat", Default = false, ConfigType = "Advanced", },
Expand Down
8 changes: 4 additions & 4 deletions utils/rgmercs_utils.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1291,12 +1291,12 @@ end

---@return boolean
function Utils.ShouldMount()
if RGMercConfig:GetSettings().DoMount == 0 then return false end
if RGMercConfig:GetSettings().DoMount == 1 then return false end

local passBasicChecks = not RGMercConfig:GetSettings().DoMelee and RGMercConfig:GetSettings().MountItem:len() > 0 and mq.TLO.Zone.Outdoor()

local passCheckMountOne = ((RGMercConfig:GetSettings().DoMount == 1 and (mq.TLO.Me.Mount.ID() or 0) == 0))
local passCheckMountTwo = ((RGMercConfig:GetSettings().DoMount == 2 and (mq.TLO.Me.Buff("Mount Blessing").ID() or 0) == 0))
local passCheckMountOne = ((RGMercConfig:GetSettings().DoMount == 2 and (mq.TLO.Me.Mount.ID() or 0) == 0))
local passCheckMountTwo = ((RGMercConfig:GetSettings().DoMount == 3 and (mq.TLO.Me.Buff("Mount Blessing").ID() or 0) == 0))
local passMountItemGivesBlessing = true

if passCheckMountTwo then
Expand All @@ -1311,7 +1311,7 @@ end

---@return boolean
function Utils.ShouldDismount()
return RGMercConfig:GetSettings().DoMount ~= 1 and ((mq.TLO.Me.Mount.ID() or 0) > 0)
return RGMercConfig:GetSettings().DoMount ~= 2 and ((mq.TLO.Me.Mount.ID() or 0) > 0)
end

---@return boolean
Expand Down

0 comments on commit 58c84fd

Please sign in to comment.