Compare commits

..

2 Commits

6 changed files with 8 additions and 5 deletions

3
.ccls
View File

@ -3,6 +3,7 @@ gcc
-Isrc/headers -Isrc/headers
-Isrc/ecs/headers -Isrc/ecs/headers
-Isrc/ecs/components/headers -Isrc/ecs/components/headers
-Icore/src/headers -ISDL_Core/src/headers
-INCurses_Core/src/headers
-Iassets/asset_builder/src/headers -Iassets/asset_builder/src/headers
-DASSET_FILE_NAME="$(make print-ASSET_OUTPUT)" -DASSET_FILE_NAME="$(make print-ASSET_OUTPUT)"

1
.gitignore vendored
View File

@ -1,3 +1,2 @@
.ccls-cache .ccls-cache
build build
core

View File

@ -28,7 +28,7 @@ all: build_core build_src build_assets
# Sub Makefiles # Sub Makefiles
SOURCE_DIR = src SOURCE_DIR = src
CORE_DIR = core/src CORE_DIR = SDL_Core/src
ASSETS_DIR = assets ASSETS_DIR = assets
include $(CORE_DIR)/Makefile include $(CORE_DIR)/Makefile

1
NCurses_Core Submodule

@ -0,0 +1 @@
Subproject commit 0ef33e0b09c5834dbca891f86e2b4f89a55d3ffb

1
SDL_Core Submodule

@ -0,0 +1 @@
Subproject commit c1a3dea5609002d1be55a3e5a2c11ebc0fa7e57e

View File

@ -106,8 +106,9 @@ void animation_system_create_frames_clips(animation_system_data_t *system_data)
inline void animation_system_change_animation(animation_system_data_t *system_data, const char *name, size_t nb_frames) inline void animation_system_change_animation(animation_system_data_t *system_data, const char *name, size_t nb_frames)
{ {
system_data->nb_frames = nb_frames;
sprite_component_set_texture(system_data->sprite_component_data, name); sprite_component_set_texture(system_data->sprite_component_data, name);
animation_system_create_frames_clips(system_data);
system_data->sprite_component_data->src_rect = *(rect_t *)system_data->actual_frame->data; system_data->sprite_component_data->src_rect = *(rect_t *)system_data->actual_frame->data;
system_data->nb_frames = nb_frames;
animation_system_create_frames_clips(system_data);
} }