public override bool IsAdjacentTo(Context other, float offset) { if (other == null) { throw new ArgumentNullException("other"); } Context2D context2D = other as Context2D; if (context2D == null) { throw new ArgumentException("Passed context is not of type Context2D.", "other"); } return context2D.AbsolutePosition.Distance(this.AbsolutePosition) <= offset; }