Exemplo n.º 1
0
        public void AddStat(Stat stat, int amount, StatSource source)
        {
            foreach (UserItemStat addedStat in AddedStats)
            {
                if (addedStat.Stat != stat || addedStat.StatSource != source)
                {
                    continue;
                }


                addedStat.Amount += amount;

                return;
            }

            if (amount == 0)
            {
                return;
            }

            UserItemStat newStat = SEnvir.UserItemStatsList.CreateNewObject();

            newStat.StatSource = source;
            newStat.Stat       = stat;
            newStat.Amount     = amount;
            newStat.Item       = this;
        }
Exemplo n.º 2
0
 public wfCFSMonitor(CFSDriveConfig drive)
 {
     InitializeComponent();
     theDrive = drive;
     myStats = new StatSource(new CFSStats());
     this.statBindingSource.DataSource = myStats;
     this.lbDrive.Text = "[" + drive.Name + "] on "+ drive.MountPoint.ToUpper() ;
     run();
 }