1 | |
1 | |
2 | /* |
2 | /* |
3 | * static char *rcsid_anim_c = |
3 | * static char *rcsid_anim_c = |
4 | * "$Id: anim.C,v 1.7 2006/09/10 16:00:23 root Exp $"; |
4 | * "$Id: anim.C,v 1.8 2006/09/11 20:28:37 root Exp $"; |
5 | */ |
5 | */ |
6 | |
6 | |
7 | /* |
7 | /* |
8 | CrossFire, A Multiplayer game for X-windows |
8 | CrossFire, A Multiplayer game for X-windows |
9 | |
9 | |
… | |
… | |
68 | /* set the name so we don't try to dereferance null. |
68 | /* set the name so we don't try to dereferance null. |
69 | * Put # at start so it will be first in alphabetical |
69 | * Put # at start so it will be first in alphabetical |
70 | * order. |
70 | * order. |
71 | */ |
71 | */ |
72 | { |
72 | { |
73 | Animations |
73 | Animations anim0; |
74 | anim0; |
|
|
75 | |
74 | |
76 | anim0.name = "###none"; |
75 | anim0.name = "###none"; |
77 | anim0.num_animations = 1; |
76 | anim0.num_animations = 1; |
78 | anim0.faces = (Fontindex *) malloc (sizeof (Fontindex)); |
77 | anim0.faces = (Fontindex *) malloc (sizeof (Fontindex)); |
79 | anim0.faces[0] = 0; |
78 | anim0.faces[0] = 0; |
… | |
… | |
102 | LOG (llevError, "Didn't get a mina before %s\n", buf); |
101 | LOG (llevError, "Didn't get a mina before %s\n", buf); |
103 | num_frames = 0; |
102 | num_frames = 0; |
104 | } |
103 | } |
105 | num_animations++; |
104 | num_animations++; |
106 | |
105 | |
107 | Animations |
106 | Animations anim; |
108 | anim; |
|
|
109 | |
107 | |
110 | anim.name = buf + 5; |
108 | anim.name = buf + 5; |
111 | anim.num = num_animations; /* for bsearch */ |
109 | anim.num = num_animations; /* for bsearch */ |
112 | anim.facings = 1; |
110 | anim.facings = 1; |
113 | animations.push_back (anim); |
111 | animations.push_back (anim); |