mirror of
https://github.com/Arkia-Groupe/radar.git
synced 2026-01-18 16:37:38 +01:00
Fix segfault
This commit is contained in:
2
Makefile
2
Makefile
@@ -33,7 +33,7 @@ LIB_OBJS = $(LIB_SRCS:.c=.o)
|
|||||||
|
|
||||||
CC = gcc
|
CC = gcc
|
||||||
|
|
||||||
CFLAGS = -lasan -Iinclude
|
CFLAGS = -Iinclude
|
||||||
|
|
||||||
LDFLAGS = -L$(LIB_DIR) -lmy -lcsfml-graphics -lcsfml-window -lcsfml-system -lm
|
LDFLAGS = -L$(LIB_DIR) -lmy -lcsfml-graphics -lcsfml-window -lcsfml-system -lm
|
||||||
|
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ void handle_event(sfEvent event, csfml **csfml, int *should_close)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (event.type == sfEvtClosed) {
|
if (event.type == sfEvtClosed) {
|
||||||
*should_close = 1;
|
exit(0);
|
||||||
}
|
}
|
||||||
if (event.type == sfEvtKeyPressed && event.key.code == sfKeyL)
|
if (event.type == sfEvtKeyPressed && event.key.code == sfKeyL)
|
||||||
show_hitboxes = !show_hitboxes;
|
show_hitboxes = !show_hitboxes;
|
||||||
|
|||||||
Reference in New Issue
Block a user