void star_move(star_t* st) { int x, y, z; z = (st->z -= 1); x = (st->x / z) + 128; y = (st->y / z) + 96; if (z < 1|| x < 0 || x >= MODE2_WIDTH || y < 0 || y >= MODE2_HEIGHT) { star_randomize(st); z = st->z; x = (st->x / z) + 128; y = (st->y / z) + 96; } st->last = st->addr; st->addr = map_pixel(x, y); st->sub = map_subpixel(x); }
void pset(int x, int y) { vmerge(map_pixel(x,y), map_subpixel(x)); }