wormy worming
This commit is contained in:
parent
74451c9350
commit
c165e7b51b
|
@ -24,6 +24,7 @@ set(ASSETS
|
|||
res/test.kble
|
||||
res/burn.kble
|
||||
res/bounce.kble
|
||||
res/worm.kble
|
||||
res/fonts/dina.png
|
||||
)
|
||||
|
||||
|
|
|
@ -2,3 +2,4 @@
|
|||
|
||||
int polarity(void);
|
||||
void polarity_invert(void);
|
||||
void polarity_reset(void);
|
||||
|
|
Binary file not shown.
|
@ -11,11 +11,12 @@
|
|||
static struct Level level;
|
||||
extern bopti_image_t bimg_tileset;
|
||||
|
||||
extern struct LevelBin kble_test, kble_burn, kble_bounce;
|
||||
extern struct LevelBin kble_test, kble_burn, kble_bounce, kble_worm;
|
||||
static const struct LevelBinNamed levels[] = {
|
||||
{&kble_test, "gentle introduction"},
|
||||
{&kble_burn, "these are rare"},
|
||||
{&kble_bounce, "deceptive road"},
|
||||
{&kble_worm, "under your skin"},
|
||||
{NULL, NULL}};
|
||||
|
||||
static void level_free(void);
|
||||
|
@ -48,6 +49,7 @@ level_load(int id)
|
|||
level.visual_data = malloc(i * sizeof(struct VisualData));
|
||||
while (i-- > 0)
|
||||
level.data[i] = b->data[i];
|
||||
polarity_reset();
|
||||
level_regen_visual_data();
|
||||
player_spawn(level.player);
|
||||
}
|
||||
|
|
|
@ -15,3 +15,9 @@ polarity_invert(void)
|
|||
pol = !pol;
|
||||
level_regen_visual_data();
|
||||
}
|
||||
|
||||
void
|
||||
polarity_reset(void)
|
||||
{
|
||||
pol = 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue