+ cptr = color_pixels;
+ for(i=0; i<VOX_SZ; i++) {
+ for(j=0; j<VOX_SZ; j++) {
+ if(*cptr == 0) {
+ /* player spawn point */
+ pos[0] = j << 16;
+ pos[1] = i << 16;
+
+ } else if(*cptr >= CMAP_SPAWN0) {
+ /* enemy spawn point */
+ enemy = enemies + *cptr - CMAP_SPAWN0;
+ if(enemy->anm) {
+ panic(get_pc(), "double spawn at %d,%d", j, i);
+ }
+ enemy->vobj.x = j;
+ enemy->vobj.y = i;
+ enemy->vobj.px = -1;
+ enemy->anm = 0xff;
+ enemy->hp = 2;
+ enemy->last_fire = 0;
+ total_enemies++;
+ }
+ cptr++;
+ }
+ }
+ /* check continuity */