October 15, 20178 yr Hey, I would like to check if Thrown is quiped and if not, equip it. I have this but need help with the equip function: private void EquipThrown() { if (player.GetEquipedItemBySlot(wManager.Wow.Enums.InventorySlot.INVSLOT_RANGED) = 0) { foreach (WoWItem item in Bag.GetBagItem()) { if(item.GetItemInfo.ItemName == "Heavy Throwing Dagger") { EQUIP THE ITEM } if (player.GetEquipedItemBySlot(wManager.Wow.Enums.InventorySlot.INVSLOT_RANGED) != 0) { break; } } } return; } Also, is there a way so i can avoid hardcoding the thrown name? Sth like isItemUsable && itemIsRanged Thx
October 15, 20178 yr Author Figured it out. Apparently you can use items to equip them. At least in this case. It's wonky but it works: private void EquipThrown() { if (ObjectManager.Me.GetEquipedItemBySlot(wManager.Wow.Enums.InventorySlot.INVSLOT_RANGED) == 0) // if player doesn't have a ranged weapon equipped { if (ItemsManager.HasItemById(3108)) { ItemsManager.UseItem(3108); } } return; }
Create an account or sign in to comment