Пример #1
0
 public PilotAbilityEngine(PilotStatPackage stats, HashSet <IAction> actions, IReadOnlyList <IUpgradeSlot> upgrades)
 {
     this.attack     = stats.Attack;
     this.agility    = stats.Agility;
     this.hull       = stats.Hull;
     this.shield     = stats.Shield;
     this.pilotSkill = stats.PilotSkill;
     this._actions   = actions;
     _upgrades       = upgrades.ToList();
     foreach (var upgrade in _upgrades)
     {
         upgrade.PropertyChanged += UpgradeContainer_PropertyChanged;
     }
 }
Пример #2
0
 internal Pilot(string shipName, string name, bool unique, IFaction faction, int cost, PilotStatPackage stats, string pilotAbility,
                string imageUri, IShipSize shipSize, HashSet <IAction> actions, IReadOnlyList <IUpgradeSlot> upgrades, string shipIcon)
 {
     Name          = name;
     Faction       = faction;
     ShipName      = shipName;
     Unique        = unique;
     PilotAbility  = pilotAbility;
     Image         = imageUri;
     ShipSize      = shipSize;
     AbilityEngine = new PilotAbilityEngine(stats, actions, upgrades);
     AbilityEngine.PropertyChanged += AbilityEngine_PropertyChanged;
     this.Cost = cost;
     ShipIcon  = shipIcon;
     Id        = Guid.NewGuid();
 }