Esempio n. 1
0
        public Creep generateCreep(Dictionary<String, Creep> dict)
        {
            Random rnd = new Random();

            Creep[] array = new Creep[dict.Count];

            array = dict.Values.ToArray();

            return array[rnd.Next(0, array.Length)];
        }
Esempio n. 2
0
 public Battle(Character p1, Dictionary<String, Creep> dictionary)
 {
     this.char_1 = p1;
     this.char_2 = generateCreep(dictionary);
     playersTurn = false;
 }
Esempio n. 3
0
 public static void populateCreeps()
 {
     IDictionary<string, Ability> abilitySet = new Dictionary<string, Ability>();
     Ability a = Ability.fetchAbility("Attack");
     abilitySet.Add("Attack", a);
     ICollection<Item> lootSet = new List<Item>();
     lootSet.Add(ItemSet.retrieveItem(1));
     Creep c = new Creep("Troll", 30, 10, 0, 10, 300, 300, 50, 50, abilitySet, lootSet, 100, new Uri("troll"));
 }