예제 #1
0
 void AddToHistory <T>(List <HistoryElement <T> > history, HistoryElement <T> historyElement) where T : MoveInfoBase
 {
     if (history.Count > MAX_HISTORY_LENGTH)
     {
         history.Remove(history.Last());
     }
     else
     {
         historyElement.ID += 1;
         history.Add(historyElement);
     }
 }
예제 #2
0
 void AddToFogHistory(HistoryElement <MapDirectionMoveInfo> historyElement)
 {
     AddToHistory(fogHistory, historyElement);
 }
예제 #3
0
 public new void Add(HistoryElement <TMapInfo> historyElement)
 {
     historyElement.ID = ID;
     ID++;
     Add(historyElement);
 }
예제 #4
0
 void AddToMapHistory(HistoryElement <MapMoveInfo> historyElement)
 {
     AddToHistory(mapHistory, historyElement);
 }