Skip to content

Commit

Permalink
Merge pull request #249 from Bestride/develop
Browse files Browse the repository at this point in the history
Add Burning Rush
  • Loading branch information
DanSheps committed Aug 24, 2023
2 parents fdb3ec0 + 960e6c8 commit 579029c
Show file tree
Hide file tree
Showing 12 changed files with 99 additions and 2 deletions.
13 changes: 13 additions & 0 deletions Versions/Common/BeStride_Mount.lua
Expand Up @@ -321,3 +321,16 @@ end
function BeStride_Mount:RogueSprint()
return self:MountSpell("[@player] "..SpellToName(2983))
end

function BeStride_Mount:Warlock()
return self:WarlockBurningRush()
end

function BeStride_Mount:WarlockBurningRush()
spell = SpellToName(111400)
if spell then
return self:MountSpell("[@player] " .. spell .. "\n/cancelaura " .. spell)
else
return nil
end
end
6 changes: 6 additions & 0 deletions Versions/Common/BeStride_Variables.lua
Expand Up @@ -65,6 +65,9 @@ BeStride_Variables = {
{
{name="classes.evoker.hover",element="CheckBox",label=LibStub("AceLocale-3.0"):GetLocale("BeStride")["Settings.Classes.Evoker.Hover"],class="evoker"},
},
{
{name="classes.warlock.rush",element="CheckBox",label=LibStub("AceLocale-3.0"):GetLocale("BeStride")["Settings.Classes.Warlock.BurningRush"],class="warlock"},
},
}
},
}
Expand Down Expand Up @@ -151,6 +154,9 @@ defaults = {
evoker = {
hover = true,
},
warlock = {
rush = true,
},
},
},
mounts = {
Expand Down
51 changes: 50 additions & 1 deletion Versions/Common/logic.class.lua
Expand Up @@ -97,6 +97,15 @@ function BeStride:IsEvoker()
end
end

function BeStride:IsWarlock()
-- Check for Warlock
if playerTable["class"]["id"] == 9 then
return true
else
return false
end
end

function BeStride:IsEvokerAndSpecial()
if self:IsEvoker() then
if IsFlying() and self:NoDismountWhileFlying() then
Expand Down Expand Up @@ -268,7 +277,17 @@ function BeStride:IsShamanAndSpecial()
end
end


function BeStride:IsWarlockAndSpecial()
if self:IsWarlock() then
if self:WarlockBurningRush() and self:MovementCheck() then
return true
else
return false
end
else
return false
end
end

-- +--------------------------+ --
-- Class Specific Spells Checks --
Expand Down Expand Up @@ -483,6 +502,18 @@ function BeStride:RogueCanSprint()
end
end

-- -------------- --
-- Warlock Spells --
-- -------------- --

function BeStride:WarlockCanBurningRush()
if IsUsableSpell(111400) then
return true
else
return false
end
end

-- +-------------------------+ --
-- Class Specific Mount Checks --
-- +-------------------------+ --
Expand Down Expand Up @@ -754,6 +785,24 @@ function BeStride:ShamanGhostWolf()
end
end


-- ------- --
-- Warlock --
-- ------- --

function BeStride:WarlockBurningRush()
-- Todo: Bitwise Compare
if self:IsWarlock() then
if self:WarlockCanBruningRush() and BeStride:DBGet("settings.classes.warlock.rush") then
return true
else
return false
end
else
return false
end
end

-- ------ --
-- Evoker --
-- ------ --
Expand Down
7 changes: 7 additions & 0 deletions Versions/Common/mounting.class.lua
Expand Up @@ -131,3 +131,10 @@ function BeStride:Rogue()
BeStride_Debug:Error("This is a error. Please report to the maintainer at https://www.github.com/dansheps/bestride/issues/. ID: RGBSL")
end
end

function BeStride:Warlock()
if not IsFlying() and self:MovementCheck() and self:WarlockBurningRush() then
return BeStride_Mount:Warlock()
end
BeStride_Debug:Error("This is a error. Please report to the maintainer at https://www.github.com/dansheps/bestride/issues/. ID: PABSL")
end
15 changes: 15 additions & 0 deletions Versions/Common/options.lua
Expand Up @@ -416,6 +416,21 @@ local optionsTable_Options = {
},
},
},
warlock = {
type="group",
name=L["Classes.Warlock"],
disabled = function (info) return BeStride:IsWrath() and not BeStride:IsMainline() end,
args = {
["classes.warlock.rush"]={
type="toggle",
name=L["Settings.Classes.Warlock.BurningRush"],
order=1,
width="full",
get=function (info) return BeStride:DBGetSetting(info[#info]) end,
set=function (info,val) BeStride:DBSetSetting(info[#info],val) end,
},
},
},
},
},
}
Expand Down
2 changes: 2 additions & 0 deletions Versions/Common/upgrade.lua
Expand Up @@ -76,6 +76,8 @@ function BeStride:Upgrade()
self.db.profile.settings.classes.mage.blink = value
elseif key == "EVOKER" then
self.db.profile.settings.classes.evoker.hover = value
elseif key == "Warlock" then
self.db.profile.settings.classes.warlock.rush = value
end
end)

Expand Down
1 change: 1 addition & 0 deletions localization/de-DE.lua
Expand Up @@ -104,3 +104,4 @@ L["Settings.Profiles.CreateNew"] = "Neues Profil erstellen:"
L["Settings.Profiles.Current"] = "Aktuelles Profil:"
L["Settings.Profiles.CopyFrom"] = "Einstellungen kopieren von:"
L["Settings.Profiles.Delete"] = "Profil löschen:"
L["Settings.Classes.Warlock.BurningRush"] = "Hexenmeister: Brennender Ansturm"
1 change: 1 addition & 0 deletions localization/en-US.lua
Expand Up @@ -110,3 +110,4 @@ L["Settings.Profiles.CreateNew"] = "Create new Profile:"
L["Settings.Profiles.Current"] = "Current Profile:"
L["Settings.Profiles.CopyFrom"] = "Copy settings from:"
L["Settings.Profiles.Delete"] = "Delete profile:"
L["Settings.Classes.Warlock.BurningRush"] = "Warlock: Burning Rush"
1 change: 1 addition & 0 deletions localization/fr-FR.lua
Expand Up @@ -103,3 +103,4 @@ L["Settings.Profiles.CreateNew"] = "Créer un nouveau Profile :"
L["Settings.Profiles.Current"] = "Profil Actuel :"
L["Settings.Profiles.CopyFrom"] = "Copier les paramètres depuis :"
L["Settings.Profiles.Delete"] = "Supprimer le Profil :"
L["Settings.Classes.Warlock.BurningRush"] = "Warlock: Burning Rush"
1 change: 1 addition & 0 deletions localization/ko-KR.lua
Expand Up @@ -104,3 +104,4 @@ L["Settings.Profiles.CreateNew"] = "새 프로필 만들기:"
L["Settings.Profiles.Current"] = "현재 프로필:"
L["Settings.Profiles.CopyFrom"] = "프로필 복사:"
L["Settings.Profiles.Delete"] = "프로필 삭제:"
L["Settings.Classes.Warlock.BurningRush"] = "Warlock: Burning Rush"
1 change: 1 addition & 0 deletions localization/zh-TW.lua
Expand Up @@ -103,3 +103,4 @@ L["Settings.Profiles.CreateNew"] = "創建新的設定檔:"
L["Settings.Profiles.Current"] = "當前設定檔:"
L["Settings.Profiles.CopyFrom"] = "複製設定檔:"
L["Settings.Profiles.Delete"] = "刪除設定檔:"
L["Settings.Classes.Warlock.BurningRush"] = "Warlock: Burning Rush"

0 comments on commit 579029c

Please sign in to comment.