public void Add(EGrid grid) { EHistoryItem item = new EHistoryItem(grid); _items.Insert(0, item); if (_bestItem.iteration < item.iteration) { _bestItem = item; } else if (_bestItem.iteration == item.iteration) { if (_bestItem.averageHealth < item.averageHealth) { _bestItem = item; } } return; }
public EHistory() { _items = new List <EHistoryItem>(); _bestItem = new EHistoryItem(); }