private void SetupAnimation(PuzzleMove move, TimeSpan totalGameTime, int endMoveIndex) { isAnimating = true; _puzzleAnimationDirection = move.Direction; _puzzlePiecesMoving = move.MovingPieces; _animationPercent = 0; _animationStart = totalGameTime; _animationEnd = totalGameTime.Add(_animationLength); _animationStartModelPosition = GetCenteringVector(move.StartingState); var nonNormalizedEndPosition = move.GetEndingState(); _animationEndModelPosition = GetCenteringVector(nonNormalizedEndPosition); _animationEndMoveIndex = endMoveIndex; }
public bool Equals(PuzzleMove other) { if (other == null) { return false; } return other.StartingState == StartingState && other.GetEndingState() == GetEndingState(); }