Skip to content

Commit

Permalink
Added to Targets scan
Browse files Browse the repository at this point in the history
  • Loading branch information
Vae2009 committed Dec 7, 2022
1 parent 35fea29 commit bc4814e
Show file tree
Hide file tree
Showing 2 changed files with 121 additions and 1 deletion.
2 changes: 1 addition & 1 deletion ConRO.toc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## Title:-|cffFFFFFFConRO|r- Conflict Rotation Optimizer
## Notes: Rotation helper framework.
## Version: 10.0.12
## Version: 10.0.13
## Author: Vae
## Interface: 100002
## SavedVariables: ConROPreferences
Expand Down
120 changes: 120 additions & 0 deletions helper.lua
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,114 @@ function ConRO:PlayerPower(_EnergyType)
return _Resource, _Resource_Max, _Resource_Percent;
end

--[[local FriendItems = {
[5] = {
37727, -- Ruby Acorn
},
[8] = {
34368, -- Attuned Crystal Cores
33278, -- Burning Torch
},
[10] = {
32321, -- Sparrowhawk Net
},
[15] = {
1251, -- Linen Bandage
2581, -- Heavy Linen Bandage
3530, -- Wool Bandage
3531, -- Heavy Wool Bandage
6450, -- Silk Bandage
6451, -- Heavy Silk Bandage
8544, -- Mageweave Bandage
8545, -- Heavy Mageweave Bandage
14529, -- Runecloth Bandage
14530, -- Heavy Runecloth Bandage
21990, -- Netherweave Bandage
21991, -- Heavy Netherweave Bandage
34721, -- Frostweave Bandage
34722, -- Heavy Frostweave Bandage
-- 38643, -- Thick Frostweave Bandage
-- 38640, -- Dense Frostweave Bandage
},
[20] = {
21519, -- Mistletoe
},
[25] = {
31463, -- Zezzak's Shard
},
[30] = {
1180, -- Scroll of Stamina
1478, -- Scroll of Protection II
3012, -- Scroll of Agility
1712, -- Scroll of Spirit II
2290, -- Scroll of Intellect II
1711, -- Scroll of Stamina II
34191, -- Handful of Snowflakes
},
[35] = {
18904, -- Zorbin's Ultra-Shrinker
},
[40] = {
34471, -- Vial of the Sunwell
},
[45] = {
32698, -- Wrangling Rope
},
[60] = {
32825, -- Soul Cannon
37887, -- Seeds of Nature's Wrath
},
[80] = {
35278, -- Reinforced Net
},
}
local HarmItems = {
[5] = {
37727, -- Ruby Acorn
},
[8] = {
34368, -- Attuned Crystal Cores
33278, -- Burning Torch
},
[10] = {
32321, -- Sparrowhawk Net
},
[15] = {
33069, -- Sturdy Rope
},
[20] = {
10645, -- Gnomish Death Ray
},
[25] = {
24268, -- Netherweave Net
41509, -- Frostweave Net
31463, -- Zezzak's Shard
},
[30] = {
835, -- Large Rope Net
7734, -- Six Demon Bag
34191, -- Handful of Snowflakes
},
[35] = {
24269, -- Heavy Netherweave Net
18904, -- Zorbin's Ultra-Shrinker
},
[40] = {
28767, -- The Decapitator
},
[45] = {
32698, -- Wrangling Rope
},
[60] = {
32825, -- Soul Cannon
37887, -- Seeds of Nature's Wrath
},
[80] = {
35278, -- Reinforced Net
},
}]]

function ConRO:Targets(spellID)
local target_in_range = false;
local number_in_range = 0;
Expand All @@ -217,6 +325,18 @@ function ConRO:Targets(spellID)
target_in_range = true;
end

for i = 1, 15 do
if not UnitIsFriend("player", 'nameplate' .. i) then
if UnitExists('nameplate' .. i) and IsItemInRange(37727, "nameplate"..i) == true then
number_in_range = number_in_range + 1
end
end
end
elseif spellID == "10" then
if IsItemInRange(32321, "target") then
target_in_range = true;
end

for i = 1, 15 do
if not UnitIsFriend("player", 'nameplate' .. i) then
if UnitExists('nameplate' .. i) and IsItemInRange(37727, "nameplate"..i) == true then
Expand Down

0 comments on commit bc4814e

Please sign in to comment.