diff options
| author | arngo <[email protected]> | 2023-05-27 18:19:22 -0400 |
|---|---|---|
| committer | arngo <[email protected]> | 2023-05-27 18:19:22 -0400 |
| commit | 95ac4162cb0b29be6d3cea07af37d0c6eafe6ac2 (patch) | |
| tree | 8c31c8c584a1808275ea85d41c2b1400d5f162a5 /src/player.c | |
| parent | a0dc49aa2f18b7454de89cf8fb103688d6a24162 (diff) | |
| download | rodeo_sample_game-95ac4162cb0b29be6d3cea07af37d0c6eafe6ac2.tar.gz rodeo_sample_game-95ac4162cb0b29be6d3cea07af37d0c6eafe6ac2.zip | |
fix bullet offset
Diffstat (limited to 'src/player.c')
| -rw-r--r-- | src/player.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/player.c b/src/player.c index 55c6d38..fe413f6 100644 --- a/src/player.c +++ b/src/player.c @@ -142,8 +142,8 @@ player_shoot(rodeo_collision_2d_world_t *bullet_collision_world) for(uint32_t i = 0; i < bullet_per_frame; ++i) { spawn_bullet( - (float)player_position->x - (orc_size[0] / 2.0f), - (float)player_position->y - (orc_size[1] / 2.0f), + (float)player_position->x + (orc_size[0] / 2.0f) - 9.0f, + (float)player_position->y + (orc_size[1] / 2.0f) - 16.0f, (float)((int8_t)(rodeo_random_uint64_get() % 10) - 5), (float)((int8_t)(rodeo_random_uint64_get() % 10) - 5), bullet_collision_world, @@ -225,11 +225,6 @@ void player_wall_resolver( p->dx = 0; p->dy = 0; } - rodeo_log( - rodeo_logLevel_info, - "%d collided with %d", - p->id.id, w->id.id - ); } void |
