Well heres a couple quick things I noticed in the code provided.
How about this:
Code:
class playerclass
{
public:
player (); // Default Constructor
int init();
int update_player();
/*int draw();*/
int get_position(int, int); // What are the prurposes of p and q?
/*int get_position(int*, int*); */ If you want them declared as pointers ( which I dont think you really need to)
int set_position(int ,int );
private:
int centerx, centery;
int X, Y; // What do X and Y represent?
float dX, dY;
int health;
int mass;
};
Code:
int playerclass::get_position( int* p, int* q )
{
*/int *p, *q; // Are these the same as the p and q passed in?
If they are they need to be defined as pointers
otherwise use different variables.*/
// What are you saying here?
p=&X; // p = "address of" X
q=&Y; // same
return 0; // You might want to return the actual postion rather than true or false
}
int playerclass::set_position( p, q )
{
X=p;
Y=q;
return 1; // Success?
}
I could have misinterpreted what you are trying to accomplish. I just picked out some syntactical errors I noticed.
My C is a little rusty (especially pointers

) so I might not be totally 100% correct but it's a start.

Like I said I dont exactly what you are trying to do with the code so maybe you could give a little more detail so we might be able to clean up all the errors.
I also had a project a couple semesters back where we had to write a program that would simulate a basketball, football, soccer or whatever we wanted. So I might be able to help if thats what your doing.
Hopefully this cleans it up a little and helps you out
-Late