diff options
Diffstat (limited to 'fx.c')
-rw-r--r-- | fx.c | 35 |
1 files changed, 31 insertions, 4 deletions
@@ -6,7 +6,8 @@ static int new_fx( World* world, int x, int y, - Animation_ID anim + Animation_ID anim, + Asset_ID bitmap ) { Entity e; CPosition* pos; @@ -30,7 +31,7 @@ static int new_fx( pos->x = x; pos->y = y; - sprite->id = asset_id_bullet; + sprite->id = bitmap; sprite->rect = make_rect(0, 0, 16, 16); animated->id = anim; @@ -45,7 +46,13 @@ int new_enemy_bullet_explosion( int x, int y ) { - return new_fx(world, x, y, animation_enemy_bullet_explode); + return new_fx( + world, + x, + y, + animation_enemy_bullet_explode, + asset_id_bullet + ); } int new_player_bullet_explosion( @@ -53,5 +60,25 @@ int new_player_bullet_explosion( int x, int y ) { - return new_fx(world, x, y, animation_player_bullet_explode); + return new_fx( + world, + x, + y, + animation_player_bullet_explode, + asset_id_bullet + ); +} + +int new_heart_break( + struct World* world, + int x, + int y +) { + return new_fx( + world, + x, + y, + animation_heart_break, + asset_id_usr + ); } |