replacing Point with Vector2 class