From 095a0591af5dc026b9d48e282e5859eda84c646c Mon Sep 17 00:00:00 2001 From: Vito Caputo Date: Mon, 12 Dec 2022 17:25:07 -0800 Subject: game: flip the winning adult as a celebratory dance Dan's idea... --- src/game.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/game.c') diff --git a/src/game.c b/src/game.c index 9c9943a..9cd3d4e 100644 --- a/src/game.c +++ b/src/game.c @@ -1343,6 +1343,11 @@ static void game_update(play_t *play, void *context) tp->entity.model_x = m4f_scale(&tp->entity.model_x, &tp->entity.scale); tp->entity.model_x = m4f_rotate(&tp->entity.model_x, &(v3f_t){ .x = 0.f, .y = 0.f, .z = 1.f }, r); } + + /* "dance" the adult too */ + game->adult->entity.model_x = m4f_translate(NULL, &(v3f_t){ game->adult->entity.position.x, game->adult->entity.position.y, 0.f }); + game->adult->entity.model_x = m4f_scale(&game->adult->entity.model_x, &game->adult->entity.scale); + game->adult->entity.model_x = m4f_rotate(&game->adult->entity.model_x, &(v3f_t){.y = -1.f}, r < 0 ? 0.f : M_PI); break; } -- cgit v1.2.3