Documentation
¶
Overview ¶
Package inventory sorts a captured character's bags and bank into what to equip, keep for professions, hand in for quests, vendor, bank, or leave alone. The rules are in docs/inventory.md.
Nothing is guessed: an item the dataset does not know, a price the dataset does not hold and a quest link the capture does not state are each reported as unknown.
Index ¶
Constants ¶
This section is empty.
Variables ¶
Order is the precedence of the groups, and the order Render lists them.
Functions ¶
Types ¶
type Entry ¶
type Entry struct {
ItemID int64
Name string
Count int
Where string // "bags" or "bank"
Group Group
Reason string
SellPrice *int64 // copper per item; nil when the dataset has no price
}
Entry is one stack and why it is in its group.
type Group ¶
type Group string
Group is where an item belongs. An item takes the first group that fits, in this order.
type Result ¶
type Result struct {
Groups map[Group][]Entry
// VendorValue is the copper the vendor stacks sell for, over the stacks with a known price.
VendorValue int64
// VendorUnpriced counts vendor stacks with no known price; VendorValue leaves them out.
VendorUnpriced int
// SlotsFreed is the bag slots emptied by vendoring and banking what sits in the bags.
SlotsFreed int
Notes []string
}
Result is what Review found.