Mercurial > hg > Members > koba > t_dandy
diff object.h @ 0:435ac1cdb64e
create task dandy directry.
author | koba <koba@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 11 Dec 2010 21:25:28 +0900 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/object.h Sat Dec 11 21:25:28 2010 +0900 @@ -0,0 +1,47 @@ +#ifndef OBJECT_H +#define OBJECT_H + + +typedef float FVECTOR[4]; +typedef float FMATRIX[4][4]; + +typedef struct width_height{ + short w; + short h; +} WX;; + +typedef struct surface { + int size; + char *name; + char *parent_name; + short w; + short h; + FVECTOR *data[4]; + FVECTOR xyz; + FVECTOR angle; + int *texture; // pointer of this surface's texture + char *image_name; + struct surface *next; + struct surface *child; + struct surface *parent; + struct surface *brother; +} SURFACE; + +typedef struct object { + FVECTOR xyz; // position + FVECTOR angle; // angle + FMATRIX transfer; // transfer matrix + char *name; // object's name + char *free_me; // pointer for free myself + SURFACE *surfaces; +} OBJECT; + +void init_object(OBJECT *obj); +void free_object(OBJECT *obj); + +extern OBJECT *font; +extern OBJECT *chara; +extern OBJECT *effect; +extern OBJECT *boss; + +#endif