I am getting multiple "missing ';' before '*' , and "type specifier - int assumed" errors on only two lines of code (all errors are in the header files).
Why are you declaring an overloading operator for vector2 inside of the header file matrix.h? I'm not sure that's workable.(line 23 matrix.h)
also, and sorry, I haven't played much with operator overloading, but can you actually set one up to multiply two objects from separate classes? (line 31 vector2.h)
Since both those lines are causing errors and they seem suspicious ...
@newbieg "On line 16 in vector2.h why is there an & after the vector2?"
Because in the vector2.cpp I am returning the address of the rhs.
1 2 3 4 5 6 7
vector2& vector2::operator=(const vector2 &rhs)
{
x = rhs.x;
y = rhs.y;
return *this;
}
@vlad from moscow
The reason the headers are inside eachother are so I can multiply a vector by matrix and vica versa in the respected .cpp's (shown below). Removing either headers from within eachother doubles the amount of errors, leaving the original errors untouched.