ItemRack help!

ItemRack help!

by mhm » Mon Nov 16, 2015 5:01 pm

hey,

if anyone can help with this i'd be very appreciative!

itemrack currently queues itemsets (that you've created) when you select them (either by click/keybind) when you're in combat, to automatically equip them for you as soon as you leave combat

does anyone know the script it utilizes to do this? so it can be put into a macro

thanks!
mhm
Private
Private
 

Re: ItemRack help!

by Geigerkind » Mon Nov 16, 2015 6:32 pm

Add this at the end of ItemRack.lua

Code: Select all
-- Custom added stuff by Shino <Synced> - Kronos 8/3/15 --
SLASH_IR1 = "/IR"
SLASH_IR2 = "/ir"
SlashCmdList["IR"] = function(msg)
   if (msg) then
      local cmd = string.lower(msg)
      if string.sub(cmd, 1, 10) == "addtoque13" then
         local incombat = UnitAffectingCombat("player")
         if string.len(cmd) > 11 and incombat then
            local itemid1 = string.sub(cmd, 12, 16)
            local itemid2 = string.sub(cmd, 18, 24)
            local _,wornId = Rack.GetItemInfo(13)
            if wornId == itemid1..":0:0" then
               Rack.AddToCombatQueue(13, tonumber(itemid2)..":0:0")
            else
               Rack.AddToCombatQueue(13, tonumber(itemid1)..":0:0")
            end
         end
      elseif string.sub(cmd, 1, 10) == "addtoque14" then
         local incombat = UnitAffectingCombat("player")
         if string.len(cmd) > 11 and incombat then
            local itemid1 = string.sub(cmd, 12, 16)
            local itemid2 = string.sub(cmd, 18, 24)
            local _,wornId = Rack.GetItemInfo(14)
            if wornId == itemid1..":0:0" then
               Rack.AddToCombatQueue(14, tonumber(itemid2)..":0:0")
            else
               Rack.AddToCombatQueue(14, tonumber(itemid1)..":0:0")
            end
         end
      end
   end
end


The macro would be then /ir addtoque13 <ITEMID1> <ITEMID2> or addtoque14 depending on which slot you want to change.
My Addons:
DPSMate - A combat analyzation tool (/viewtopic.php?f=63&t=38042)
Vanilla Consolidated Buff-Frames (/viewtopic.php?f=63&t=18189)
Modified Power Auras (/viewtopic.php?f=63&t=18251)
User avatar
Geigerkind
Senior Sergeant
Senior Sergeant
 

Re: ItemRack help!

by mhm » Mon Nov 16, 2015 7:57 pm

hey Shino,

this didn't work, i tried;

/ir addtoque13 19381 (boots of the shadow flame)
/ir addtoque13 bootsswap (name of itemrack set)

please lmk if i'm doing anything wrong!
mhm
Private
Private
 

Re: ItemRack help!

by Geigerkind » Mon Nov 16, 2015 8:10 pm

Its just designed for trinkets. Just change the 14 and 13 in the code to other slots. Every Item has an slot number therefore you have to look for your boots.
My Addons:
DPSMate - A combat analyzation tool (/viewtopic.php?f=63&t=38042)
Vanilla Consolidated Buff-Frames (/viewtopic.php?f=63&t=18189)
Modified Power Auras (/viewtopic.php?f=63&t=18251)
User avatar
Geigerkind
Senior Sergeant
Senior Sergeant
 

Re: ItemRack help!

by mhm » Mon Nov 16, 2015 8:13 pm

Geigerkind wrote:Its just designed for trinkets. Just change the 14 and 13 in the code to other slots. Every Item has an slot number therefore you have to look for your boots.


tried that with slot 8, boots, didn't work
mhm
Private
Private
 

Re: ItemRack help!

by Geigerkind » Mon Nov 16, 2015 8:26 pm

/ir addtoque13 19381 19382
My Addons:
DPSMate - A combat analyzation tool (/viewtopic.php?f=63&t=38042)
Vanilla Consolidated Buff-Frames (/viewtopic.php?f=63&t=18189)
Modified Power Auras (/viewtopic.php?f=63&t=18251)
User avatar
Geigerkind
Senior Sergeant
Senior Sergeant
 

Re: ItemRack help!

by Geigerkind » Mon Nov 16, 2015 8:30 pm

Code: Select all
-- Custom added stuff by Shino <Synced> - Kronos 8/3/15 --
SLASH_IR1 = "/IR"
SLASH_IR2 = "/ir"
SlashCmdList["IR"] = function(msg)
   if (msg) then
      local cmd = string.lower(msg)
      if string.sub(cmd, 1, 8) == "addtoque" then
         local incombat = UnitAffectingCombat("player")
         if string.len(cmd) > 11 and incombat then
            local itemid1 = string.sub(cmd, 10, 14)
            local itemid2 = string.sub(cmd, 16, 20)
local slot = tonumber(string.sub(cmd, 22, 28))
            local _,wornId = Rack.GetItemInfo(slot)
            if wornId == itemid1..":0:0" then
               Rack.AddToCombatQueue(slot, tonumber(itemid2)..":0:0")
            else
               Rack.AddToCombatQueue(slot, tonumber(itemid1)..":0:0")
            end
         end
      end
   end
end


Use /ir addtoque 12345 12345 8
My Addons:
DPSMate - A combat analyzation tool (/viewtopic.php?f=63&t=38042)
Vanilla Consolidated Buff-Frames (/viewtopic.php?f=63&t=18189)
Modified Power Auras (/viewtopic.php?f=63&t=18251)
User avatar
Geigerkind
Senior Sergeant
Senior Sergeant
 

Re: ItemRack help!

by mhm » Mon Nov 16, 2015 8:45 pm

both /ir addtoque 19381 19381 8
and /ir addtoque 19381 8

don't work :o
mhm
Private
Private
 

Re: ItemRack help!

by Geigerkind » Mon Nov 16, 2015 9:43 pm

You cant switch an item with the same item
/ir addtoque FIRSTITEM SECONDITEM 8
My Addons:
DPSMate - A combat analyzation tool (/viewtopic.php?f=63&t=38042)
Vanilla Consolidated Buff-Frames (/viewtopic.php?f=63&t=18189)
Modified Power Auras (/viewtopic.php?f=63&t=18251)
User avatar
Geigerkind
Senior Sergeant
Senior Sergeant
 

Re: ItemRack help!

by mhm » Mon Nov 16, 2015 10:04 pm

Geigerkind wrote:You cant switch an item with the same item
/ir addtoque FIRSTITEM SECONDITEM 8


great, this works fine, tyvm! :D

but, only works for when you're in combat, is there a way to make it so it works ooc too?

& also to swap straight to the item you want rather than having to add in every pair of boots you use + the boots you want to swap to (or any other item for example)
mhm
Private
Private
 

Next

Return to Addons & macros

cron