Esempio n. 1
0
        private void processItem(WoWItem wowItem, LBItem tbItem)
        {
            // LBItem holds the action to use, switch to the right method
            switch (lbItem.Action)
            {
            case "use":
                Logging.Write(LogLevel.Normal, Colors.DarkRed, "[{0} {1}]: Using {2} we have {3}", this.Name, this.Version, wowItem.Name, wowItem.StackCount);
                ItemInteraction.UseItem(wowItem, tbItem.NeedsSleep);
                break;

            case "drop":
                Logging.Write(LogLevel.Normal, Colors.DarkRed, "[{0} {1}]: Dropping {2}", this.Name, this.Version, wowItem.Name);
                ItemInteraction.DropItem(wowItem);
                break;

            case "keep":
                // dummy action, does nothing as nothing is exactly what is meant
                break;

            default:
                Logging.Write(LogLevel.Normal, Colors.DarkRed, "[{0} {1}]: Trying to process \"{2}\" but Action \"{3}\" is unknown", this.Name, this.Version, wowItem.Name, tbItem.Action);
                break;
            }
        }