public void ReproduceState(int index) { Init(); History history = History.Instance; PieceController pc = PieceController.Instance; for (int i = 0; i <= index; i++) { HistoryInfo info = history.Get(i); Piece piece = pc.GetByIndex(info.PieceId - 1); piece.Move(info.Position, false); if (info.IsPromote) { piece.Promote(); } } }