diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-28 16:46:40 +0100 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-28 16:46:40 +0100 |
commit | b3aecb150f55ebc9dde7c1b09559d1566e9e92a6 (patch) | |
tree | fec17255ec594ddfb6f98121d987ada32461db06 /src/ft_get_sprite_spawns.c | |
parent | normed (diff) | |
download | 42-cub3d-b3aecb150f55ebc9dde7c1b09559d1566e9e92a6.tar.gz 42-cub3d-b3aecb150f55ebc9dde7c1b09559d1566e9e92a6.tar.bz2 42-cub3d-b3aecb150f55ebc9dde7c1b09559d1566e9e92a6.tar.xz 42-cub3d-b3aecb150f55ebc9dde7c1b09559d1566e9e92a6.tar.zst 42-cub3d-b3aecb150f55ebc9dde7c1b09559d1566e9e92a6.zip |
All in sprites
Diffstat (limited to 'src/ft_get_sprite_spawns.c')
-rw-r--r-- | src/ft_get_sprite_spawns.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/ft_get_sprite_spawns.c b/src/ft_get_sprite_spawns.c index 0dc0f7a..0d20664 100644 --- a/src/ft_get_sprite_spawns.c +++ b/src/ft_get_sprite_spawns.c @@ -52,8 +52,19 @@ static void static int8_t ft_other_next_sprite(t_cub *cl, int s_n) { - if (s_n == 7) + if (s_n + 1 == 8) return (ft_get_next_sprite(cl, 8, 'T', 0)); + if (s_n + 1 == 9) + return (ft_get_next_sprite(cl, 9, '+', 0)); + if (cl->isdead == 0) + { + if (s_n + 1 == 10) + return (ft_get_next_sprite(cl, 10, '!', 0)); + if (s_n + 1 == 11) + return (ft_get_next_sprite(cl, 11, '@', 0)); + if (s_n + 1 == 12) + return (ft_get_next_sprite(cl, 12, '#', 0)); + } return (0); } |