示例#1
0
 public Villager(string name, Reputation reputation, List <string> prompts)
 {
     Name                  = name;
     Attributes            = AttributeFactory.GetInstance("Villager");
     Reputation            = reputation;
     Prompts               = prompts;
     InteractionTriggered += OnInteractionTriggered;
 }
示例#2
0
        //Create a factory test object to pass in here and set values then create a constructor which takes that factory as a parameter
        //public Gladiater(List<IAttribute> attributes, Dictionary<BodyPart, IWeapon> weaponSet, Dictionary<BodyPart, IArmor> armor, List<IItems> inventory, GladiatorTypes gladType)
        //{
        //    this.Attributes = attributes;
        //    this.WeaponSet = weaponSet;
        //    this.Armor = armor;
        //    this.Inventory = inventory;
        //    this.Name = gladType.ToString();
        //    this.IsAlive = true;
        //    this.DmgMitigated = 0;
        //    this.Kills = 0;
        //    this.Reputation = Reputation.Hostile;
        //    InteractionTriggered += OnInteractionTriggered;
        //}

        public Gladiator(string name, GladiatorTypes gladType)
        {
            this.Attributes       = AttributeFactory.GetInstance(gladType.ToString());
            this.WeaponSet        = WeaponFactory.GetBaseWeaponInstances(gladType);
            this.Armor            = ArmorFactory.GetBaseArmorInstances(gladType);
            this.AbilityList      = AbilityFactory.GetBaseAbilityList(gladType);
            this.Inventory        = new List <IItems>();
            this.Name             = name.ToUpper();
            this.IsAlive          = true;
            this.DmgMitigated     = 0;
            this.Kills            = 0;
            this.MaxEnergyValue   = this.GetAttribute(AttributeType.Energy).Value;
            this.Reputation       = Reputation.Hostile;
            InteractionTriggered += OnInteractionTriggered;
        }