/trunk
elseif kind == "LAND" then |
mounts = 0 -- reset mounts to 0 so we can start counting land mounts |
for k in orderedPairs(settings) do -- Check the list of mounts, increment mounts, and add the index of the mounts to mountstable |
if (settings[k].type == "land" or settings[k].type == "combo") or (settings[k].type == "flying" and LivestockSettings.flyland == 1) then |
if (settings[k].type == "land" or settings[k].type == "combo" or settings[k].type == "combo2") or |
(settings[k].type == "flying" and LivestockSettings.flyland == 1) then |
mounts = mounts + 1 |
tinsert(mountstable, settings[k].index) |
end |
elseif kind == "WATER" then -- code is the same for water mounts with the appropriate changes; perhaps this could be a function call? |
mounts = 0 |
for k in orderedPairs(settings) do |
if (settings[k].type == "water" or settings[k].type == "combo") then |
if (settings[k].type == "water" or settings[k].type == "combo" or settings[k].type == "combo2") then |
mounts = mounts + 1 |
tinsert(mountstable, settings[k].index) |
end |
LivestockSettings.Mounts[name].type = "land" |
elseif mountType == 231 or mountType == 232 or mountType == 254 then -- water mount |
LivestockSettings.Mounts[name].type = "water" |
elseif mountType == 407 or mountType == 412 then |
elseif mountType == 407 then |
LivestockSettings.Mounts[name].type = "combo" -- land/flying/water mount |
elseif mountType == 412 then |
LivestockSettings.Mounts[name].type = "combo2" -- land/water mount |
elseif mountType == 402 then |
LivestockSettings.Mounts[name].type = "dragon" -- dragonriding mount |
else |
for k in pairs(LivestockSettings.Mounts) do -- go through the land mounts and add the ones that are selected to the temp table |
if LivestockSettings.Mounts[k].enableLand == 1 and |
((LivestockSettings.Mounts[k].type == "land" or LivestockSettings.Mounts[k].type == "combo") or |
((LivestockSettings.Mounts[k].type == "land" or LivestockSettings.Mounts[k].type == "combo" or LivestockSettings.Mounts[k].type == "combo2") or |
(LivestockSettings.Mounts[k].type == "flying" and LivestockSettings.flyland == 1)) then |
local _, _, _, _, isUsable = C_MountJournal.GetMountInfoByID(LivestockSettings.Mounts[k].index) |
if isUsable == true then |
end |
else |
for k in pairs(LivestockSettings.Mounts) do -- go through the water mounts and add the ones that are selected to the temp table (minus the Abyssal Seahorse) |
if (LivestockSettings.Mounts[k].type == "water" or LivestockSettings.Mounts[k].type == "combo") and |
if (LivestockSettings.Mounts[k].type == "water" or LivestockSettings.Mounts[k].type == "combo" or LivestockSettings.Mounts[k].type == "combo2") and |
LivestockSettings.Mounts[k].enableWater == 1 and LivestockSettings.Mounts[k].spellID ~= 75207 then |
tinsert(temp, LivestockSettings.Mounts[k].index) |
end |
Version 3.3.7 |
- Fixed Otto and Ottuk mounts |
Version 3.3.6 |
- TOC update for patch 10.1.0 |
## Title: Livestock |
## Notes: Enables easy random summoning of vanity pets and mounts, including the option of "smart mounting" |
## Author: Kharthus - Deathwing(US) |
## Version: 3.3.6 |
## Version: 3.3.7 |
## AddonCompartmentFunc: Livestock_OnAddonCompartmentClick |
## IconTexture: 136456 |
## SavedVariablesPerCharacter: LivestockSettings |