what do these errors mean?
1. error C2627: member function defined in unnamed class
2. warning C4094: untagged ''class'' declared no symbols
those two errors are the source of 66 other errors that are preventing me from doing any extra work.
X4J
X4J
Looks to me like you didn''t name your class properly, those two errors pop up if you have some code like this:
The code above is obviously wrong, as the class isn''t named.
If that''s not your problem please post some of the code that causes things to go pear-shaped.
-Neophyte
- Death awaits you all with nasty, big, pointy teeth. -
|
The code above is obviously wrong, as the class isn''t named.
If that''s not your problem please post some of the code that causes things to go pear-shaped.
-Neophyte
- Death awaits you all with nasty, big, pointy teeth. -
here is the class.
class OBJECT
{
public:
// OBJECT functions
int state; // the state of the object (general)
int Show();
int Hide();
int Move();
int Destroy();
int Animate();
int Set_Pos(int nx, int ny);
int Set_Vel(int nyv, int nxv);
int Set_Anim_Speed(int speed);
// int Set_Animation(int anim_index);
int Collision_Test(OBJECT object2);
int Draw(LPDIRECTDRAWSURFACE7 dest);
int Clone(OBJECT source, OBJECT dest);
// int Load_Animation(int anim_index, int num_frames, int *sequence);
int Create(int xx,int yy,int Width,int Height,int numo_frames,int attributes,LPCTSTR filename);
// public variables
int x,y; // position bitmap will be displayed at
int xv,yv; // velocity of object
int max_velocity,min_velocity;
private:
int anim_state; // an animation state variable, up to you
int attr; // attributes pertaining to the object (general)
int width, height; // the width and height of the object
int width_fill; // internal, used to force 8*x wide surfaces
int counter_1; // general counters
int counter_2;
int max_count_1; // general threshold values;
int max_count_2;
int varsI[16]; // stack of 16 integers
float varsF[16]; // stack of 16 floats
int curr_frame; // current animation frame
int num_frames; // total number of animation frames
int curr_animation; // index of current animation
int anim_counter; // used to time animation transitions
int anim_index; // animation element index
int anim_count_max; // number of cycles before animation
int *animations[16]; // animation sequences
LPDIRECTDRAWSURFACE7 file; // the template that contains the animations
RECT images[60]; // the source rects representing the varoius animations
};
class OBJECT
{
public:
// OBJECT functions
int state; // the state of the object (general)
int Show();
int Hide();
int Move();
int Destroy();
int Animate();
int Set_Pos(int nx, int ny);
int Set_Vel(int nyv, int nxv);
int Set_Anim_Speed(int speed);
// int Set_Animation(int anim_index);
int Collision_Test(OBJECT object2);
int Draw(LPDIRECTDRAWSURFACE7 dest);
int Clone(OBJECT source, OBJECT dest);
// int Load_Animation(int anim_index, int num_frames, int *sequence);
int Create(int xx,int yy,int Width,int Height,int numo_frames,int attributes,LPCTSTR filename);
// public variables
int x,y; // position bitmap will be displayed at
int xv,yv; // velocity of object
int max_velocity,min_velocity;
private:
int anim_state; // an animation state variable, up to you
int attr; // attributes pertaining to the object (general)
int width, height; // the width and height of the object
int width_fill; // internal, used to force 8*x wide surfaces
int counter_1; // general counters
int counter_2;
int max_count_1; // general threshold values;
int max_count_2;
int varsI[16]; // stack of 16 integers
float varsF[16]; // stack of 16 floats
int curr_frame; // current animation frame
int num_frames; // total number of animation frames
int curr_animation; // index of current animation
int anim_counter; // used to time animation transitions
int anim_index; // animation element index
int anim_count_max; // number of cycles before animation
int *animations[16]; // animation sequences
LPDIRECTDRAWSURFACE7 file; // the template that contains the animations
RECT images[60]; // the source rects representing the varoius animations
};
X4J
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement