assets: Use new terry walk assets with proper baseline

This commit is contained in:
doyle 2023-09-23 22:38:08 +10:00
parent 5de62f1b15
commit ebfcc899c1
41 changed files with 96 additions and 13 deletions

1
.gitignore vendored
View File

@ -1 +1,2 @@
Build/
Nocheckin/

BIN
Data/Textures/protagonist_walk.png (Stored with Git LFS)

Binary file not shown.

BIN
Data/Textures/protagonist_walk.txt (Stored with Git LFS)

Binary file not shown.

BIN
Data/Textures/terry_movement.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement.txt (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_1.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_2.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_3.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_4.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_5.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_6.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Down_7.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_1.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_2.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_3.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_4.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_5.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_6.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Left_7.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_1.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_2.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_3.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_4.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_5.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_6.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Right_7.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Up_1.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Up_2.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Up_3.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Up_4.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Up_5.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
Data/Textures/terry_movement/Up_6.png (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -403,8 +403,8 @@ void TELY_DLL_Init(void *user_data)
Dqn_Slice<TELY_AssetSpriteAnimation> *anims = &game->protag_walk_sprite_anims;
Dqn_ThreadScratch scratch = Dqn_Thread_GetScratch(nullptr);
Dqn_String8 sheet_path = Dqn_FsPath_ConvertF(scratch.arena, "%.*s/protagonist_walk.png", DQN_STRING_FMT(assets->textures_dir));
sheet->tex_handle = platform->func_load_texture(assets, DQN_STRING8("Protagonist Walk"), sheet_path);
Dqn_String8 sheet_path = Dqn_FsPath_ConvertF(scratch.arena, "%.*s/terry_movement.png", DQN_STRING_FMT(assets->textures_dir));
sheet->tex_handle = platform->func_load_texture(assets, DQN_STRING8("Terry Movement"), sheet_path);
sheet->sprite_count = 28;
sheet->sprites_per_row = 7;
sheet->sprite_size = Dqn_V2I_InitNx2(185, 170);
@ -419,7 +419,7 @@ void TELY_DLL_Init(void *user_data)
// NOTE: Load the sprite meta file =========================================================
{
Dqn_List<LoadedSprite> raw_sprites = Dqn_List_Init<LoadedSprite>(scratch.arena, 32);
Dqn_String8 sheet_meta_path = Dqn_FsPath_ConvertF(scratch.arena, "%.*s/protagonist_walk.txt", DQN_STRING_FMT(assets->textures_dir));
Dqn_String8 sheet_meta_path = Dqn_FsPath_ConvertF(scratch.arena, "%.*s/terry_movement.txt", DQN_STRING_FMT(assets->textures_dir));
Dqn_String8 sheet_meta_file = Dqn_Fs_Read(sheet_meta_path, scratch.allocator);
Dqn_String8BinarySplitResult split = {};
@ -450,10 +450,11 @@ void TELY_DLL_Init(void *user_data)
}
TELY_AssetSpriteAnimation raw_anims[] = {
// {DQN_STRING8("Walk down"), /*index*/ 0, /*count*/ 7, /*seconds_per_frame*/ 1 / 8.f},
{DQN_STRING8("Walk idle"), /*index*/ 0, /*count*/ 8, /*seconds_per_frame*/ 1 / 8.f},
// {DQN_STRING8("Walk left"), /*index*/ 15, /*count*/ 7, /*seconds_per_frame*/ 1 / 8.f},
// {DQN_STRING8("Walk right"), /*index*/ 22, /*count*/ 7, /*seconds_per_frame*/ 1 / 8.f},
{DQN_STRING8("Walk down"), /*index*/ 0, /*count*/ 7, /*seconds_per_frame*/ 1 / 8.f},
{DQN_STRING8("Walk idle"), /*index*/ 7, /*count*/ 8, /*seconds_per_frame*/ 1 / 8.f},
{DQN_STRING8("Walk left"), /*index*/ 15, /*count*/ 7, /*seconds_per_frame*/ 1 / 8.f},
{DQN_STRING8("Walk right"), /*index*/ 22, /*count*/ 7, /*seconds_per_frame*/ 1 / 8.f},
{DQN_STRING8("Walk up"), /*index*/ 29, /*count*/ 6, /*seconds_per_frame*/ 1 / 8.f},
};
*anims = Dqn_Slice_Alloc<TELY_AssetSpriteAnimation>(&platform->arena, DQN_ARRAY_UCOUNT(raw_anims), Dqn_ZeroMem_No);