I'm trying to create my own Vector2D class, similar to that of XNA's, to store coordinates in. Following the example of constructors found here, I created the code below. However, I get an error saying that there is no instance of constructor "Vector2D::Vector2D" that matches the argument list. I don't see how that can be... What seems to be my problem?
struct Vector2D {
Vector2D(int *varX, int *varY);
~Vector2D();
private: int *X, *Y;
};
Vector2D::Vector2D(int *varX, int *varY) {
X = varX;
Y = varY;
}
Vector2D::~Vector2D() {
free(X);
free(Y);
}