Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Progress on grinder model. Minor updates to view interface.
- Loading branch information
Showing
20 changed files
with
790 additions
and
180 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
namespace BlizzardApi.Global | ||
{ | ||
using CsLua.Wrapping; | ||
using System; | ||
using WidgetInterfaces; | ||
|
||
public partial interface IApi | ||
{ | ||
/// <summary> | ||
/// Get the info for an item in one of the player's bags. | ||
/// </summary> | ||
/// <param name="bag">Index of the bag to query.</param> | ||
/// <param name="slot">Index of the slot within the bag to query; ascending from 1.</param> | ||
/// <returns>texture, itemCount, locked, quality, readable, lootable, itemLink</returns> | ||
IMultipleValues<string, int, bool, int, bool, bool, string> GetContainerItemInfo(int bagID, int slot); | ||
|
||
/// <summary> | ||
/// Returns the item ID of the item in a particular container slot. | ||
/// </summary> | ||
/// <param name="bag">Index of the bag to query.</param> | ||
/// <param name="slot">Index of the slot within the bag to query; ascending from 1.</param> | ||
/// <returns>Item ID of the item held in the container slot, nil if there is no item in the container slot. </returns> | ||
int? GetContainerItemID(int bag, int slot); | ||
|
||
/// <summary> | ||
/// Returns the total number of slots in the bag specified by the index. | ||
/// </summary> | ||
/// <param name="bagID">Index of the bag.</param> | ||
/// <returns>The number of slots in the specified bag, or 0 if there is no bag in the given slot.</returns> | ||
int GetContainerNumSlots(int bagID); | ||
|
||
/* | ||
ContainerIDToInventoryID(bagID) | ||
GetBagName(bagID) - Get the name of one of the player's bags. | ||
GetContainerItemCooldown(bagID, slot) | ||
GetContainerItemDurability(bag, slot) - Get current and maximum durability of an item in the character's bags. | ||
GetContainerItemGems(bag, slot) - Returns item IDs of gems inserted into the item in a specified container slot. | ||
GetContainerItemID(bag, slot) - Returns the item ID of the item in a particular container slot. | ||
GetContainerItemLink(bagID, slot) - Returns the itemLink of the item located in bag#, slot#. | ||
GetContainerItemQuestInfo(bag, slot) - Returns information about quest and quest-starting items in your bags. (added 3.3.3) | ||
GetContainerNumFreeSlots(bagID) - Returns the number of free slots and type of slots in the bag specified by the index. (added 2.4) | ||
HasKey() - Returns 1 if the player has a keyring, nil otherwise. | ||
UI OpenAllBags() - Open all bags | ||
UI CloseAllBags() - Close all bags | ||
PickupBagFromSlot(slot) - Picks up the bag from the specified slot, placing it in the cursor. | ||
PickupContainerItem(bagID,slot) | ||
PutItemInBackpack() - attempts to place item in backpack (bag slot 0). | ||
PutItemInBag(inventoryId) - attempts to place item in a specific bag. | ||
UI PutKeyInKeyRing() - attempts to place item in your keyring. | ||
SplitContainerItem(bagID,slot,amount) | ||
UI ToggleBackpack() - Toggles your backpack open/closed. | ||
UI ToggleBag(bagID) - Opens or closes the specified bag. | ||
PROTECTED UseContainerItem(bagID, slot[, onSelf]) - Uses an item located in bag# and slot#. Warning: If a vendor window is open, using items in your pack may sell them - 'onSelf'! Protected situationally? (added 1.12) | ||
*/ | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
namespace BlizzardApi.Global | ||
{ | ||
using CsLua.Wrapping; | ||
using System; | ||
using WidgetInterfaces; | ||
|
||
public partial interface IApi | ||
{ | ||
/// <summary> | ||
/// Returns information about an item. | ||
/// </summary> | ||
/// <param name="itemId">The numeric ID of the item. ie. 12345 </param> | ||
/// <returns>itemName, itemLink, itemRarity, itemLevel, itemMinLevel, itemType, itemSubType, itemStackCount, itemEquipLoc, itemTexture, itemSellPrice</returns> | ||
IMultipleValues<string, string, int, int, int, string, string, int, string, string, int> GetItemInfo(int itemId); | ||
|
||
/// <summary> | ||
/// Returns information about an item. | ||
/// </summary> | ||
/// <param name="itemString">The full item ID in string format, e.g. "item:12345:0:0:0:0:0:0:0". Also supports partial itemStrings, by filling up any missing ":x" value with ":0", e.g. "item:12345:0:0:0" </param> | ||
/// <returns>itemName, itemLink, itemRarity, itemLevel, itemMinLevel, itemType, itemSubType, itemStackCount, itemEquipLoc, itemTexture, itemSellPrice</returns> | ||
IMultipleValues<string, string, int, int, int, string, string, int, string, string, int> GetItemInfo(string itemString); | ||
|
||
/// <summary> | ||
/// Returns count information for the item. | ||
/// </summary> | ||
/// <param name="itemId">ID of the item</param> | ||
/// <returns>The number of items in your possesion.</returns> | ||
int GetItemCount(int itemId); | ||
|
||
/// <summary> | ||
/// Returns count information for the item. | ||
/// </summary> | ||
/// <param name="itemId">ID of the item</param> | ||
/// <param name="includeBank">Count includes bank items.</param> | ||
/// <returns>The number of items in your possesion.</returns> | ||
int GetItemCount(int itemId, bool includeBank); | ||
|
||
/// <summary> | ||
/// Returns count information for the item. | ||
/// </summary> | ||
/// <param name="itemId">ID of the item</param> | ||
/// <param name="includeBank">Count includes bank items.</param> | ||
/// <param name="includeCharges">Count is charges if any, otherwise number of items</param> | ||
/// <returns>The number of items in your possesion, or charges if includeCharges is true and the item has charges.</returns> | ||
int GetItemCount(int itemId, bool includeBank, bool includeCharges); | ||
|
||
/// <summary> | ||
/// Returns count information for the item. | ||
/// </summary> | ||
/// <param name="itemName">ID of the item</param> | ||
/// <returns>The number of items in your possesion.</returns> | ||
int GetItemCount(string itemName); | ||
|
||
/// <summary> | ||
/// Returns count information for the item. | ||
/// </summary> | ||
/// <param name="itemName">ID of the item</param> | ||
/// <param name="includeBank">Count includes bank items.</param> | ||
/// <returns>The number of items in your possesion.</returns> | ||
int GetItemCount(string itemName, bool includeBank); | ||
|
||
/// <summary> | ||
/// Returns count information for the item. | ||
/// </summary> | ||
/// <param name="itemName">ID of the item</param> | ||
/// <param name="includeBank">Count includes bank items.</param> | ||
/// <param name="includeCharges">Count is charges if any, otherwise number of items</param> | ||
/// <returns>The number of items in your possesion, or charges if includeCharges is true and the item has charges.</returns> | ||
int GetItemCount(string itemName, bool includeBank, bool includeCharges); | ||
|
||
/* | ||
EquipItemByName(itemId or "itemName" or "itemLink"[, slot]) - Equips an item, optionally into a specified slot. | ||
GetAuctionItemLink("type", index) - Returns an itemLink for the specified auction item. | ||
GetContainerItemLink(bagID, slot) - Returns the itemLink of the item located in bag#, slot#. | ||
GetItemCooldown(itemID) - Returns startTime, duration, enable. | ||
GetItemCount(itemId or "itemName" or "itemLink"[, includeBank][, includeCharges]) - Returns number of such items in inventory[, or charges instead if it has charges] | ||
GetItemFamily(itemId or "itemName" or "itemLink") - Returns the bag type that an item can go into, or for bags the type of items that it can contain. (added 2.4) | ||
GetItemIcon(itemId or "itemString" or "itemName" or "itemLink") - Returns the icon for the item. Works for any valid item even if it's not in the cache. (added 2.4) | ||
GetItemInfo(itemId or "itemString" or "itemName" or "itemLink") - Returns information about an item. | ||
GetItemQualityColor(quality) - Returns the RGB color codes for a quality. | ||
GetItemSpell(item) - Returns name, rank. | ||
GetItemStats(itemLink, statTable) - Returns a table of stats for an item. | ||
GetMerchantItemLink(index) - Returns an itemLink for the given purchasable item | ||
GetQuestItemLink("type", index) - Returns an itemLink for a quest reward item. | ||
GetQuestLogItemLink("type", index) - Returns an itemLink for a quest reward item. | ||
GetTradePlayerItemLink(id) - Returns an itemLink for the given item in your side of the trade window (if open) | ||
GetTradeSkillItemLink(index) - Returns the itemLink for a trade skill item. | ||
GetTradeSkillReagentItemLink(index, reagentId) - Returns the itemLink for one of the reagents needed to craft the given item | ||
GetTradeTargetItemLink(id) - Returns an itemLink for the given item in the other player's side of the trade window (if open) | ||
IsUsableItem(item) - Returns usable, noMana. | ||
IsConsumableItem(item) | ||
IsCurrentItem(item) | ||
IsEquippedItem(item) | ||
IsEquippableItem(itemId or "itemName" or "itemLink") - Returns 1 or nil. | ||
IsEquippedItemType("type") - Where "type" is any valid inventory type, item class, or item subclass. | ||
IsItemInRange("itemName" or "itemLink", "unit") - Nil for invalid target, 0 for out of range, 1 for in range. | ||
ItemHasRange(item) | ||
OffhandHasWeapon() - Determine if your offhand carries a weapon. | ||
SplitContainerItem(bagID,slot,amount) - Picks up part of a stack. | ||
UI SetItemRef(link, text, button) - Handles item link tooltips in chat. | ||
*/ | ||
} | ||
} |
Oops, something went wrong.