aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_get_weapon_spawn.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ft_get_weapon_spawn.c')
-rw-r--r--src/ft_get_weapon_spawn.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ft_get_weapon_spawn.c b/src/ft_get_weapon_spawn.c
index a54d2b6..1ed4c7d 100644
--- a/src/ft_get_weapon_spawn.c
+++ b/src/ft_get_weapon_spawn.c
@@ -22,8 +22,10 @@ static void
{
if (id == 0)
ft_map_error(FT_ERR_TOO_MUCH_W_ONE, clist);
- else
+ else if (id == 1)
ft_map_error(FT_ERR_TOO_MUCH_W_TWO, clist);
+ else
+ ft_map_error(FT_ERR_TOO_MUCH_W_THREE, clist);
}
clist->weaps[id][0].s_pos_x = x;
clist->weaps[id][0].s_pos_y = y;
@@ -47,6 +49,8 @@ void
ft_get_weapon_id_spawn(0, y, x, clist);
else if (clist->mlist.map[y][x] == '@')
ft_get_weapon_id_spawn(1, y, x, clist);
+ else if (clist->mlist.map[y][x] == '#')
+ ft_get_weapon_id_spawn(2, y, x, clist);
x++;
}
x = 1;