コード例 #1
0
        private static string GetSpell(BlizzardPet blizzPet)
        {
            // spell ID is the spell which has ON_LEARN
            var spellId = -1;

            if (blizzPet.itemSpells != null)
            {
                foreach (var spell in blizzPet.itemSpells)
                {
                    if (spell.trigger == "ON_LEARN")
                    {
                        spellId = spell.spellId;
                    }
                }
            }

            if (spellId <= 0)
            {
                return(null);
            }

            return(spellId.ToString());
        }
コード例 #2
0
 public WowHeadPet(BlizzardPet pet)
 {
     this.pet = pet;
 }