diff options
Diffstat (limited to 'src/sdl/draw.c')
-rw-r--r-- | src/sdl/draw.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/sdl/draw.c b/src/sdl/draw.c index 762976f..37d9ba2 100644 --- a/src/sdl/draw.c +++ b/src/sdl/draw.c @@ -10,6 +10,8 @@ #define M_2_PI (2.0 * 3.1415926) +#define BUMP_TIME 300 + static size_t get_cell_size( const draw_ctx_t * const draw_ctx @@ -145,6 +147,8 @@ get_home_angle( return 5 * sin(draw_ctx->ticks * M_2_PI / 2000.0); } else if (sok_ctx_is_done(draw_ctx->ctx)) { return 10 * sin(draw_ctx->ticks * M_2_PI / 1000.0); + } else if ((draw_ctx->ticks - draw_ctx->bump_ticks) < BUMP_TIME) { + return 10 * sin(draw_ctx->ticks * M_2_PI / (BUMP_TIME / 2.0)); } else { return 0; } |