Make sure that the last frame in the generated atlas is not the same as the first to make the animation look better.

This commit is contained in:
Relintai 2021-07-15 01:08:03 +02:00
parent 003633ac0f
commit fb3d7ea82a
2 changed files with 1 additions and 1 deletions

View File

@ -148,7 +148,7 @@ func _process(delta):
_texture.blend_rect(frame, ur, Vector2((_frame * _sprite_size) + xx, (_index * _sprite_size))) _texture.blend_rect(frame, ur, Vector2((_frame * _sprite_size) + xx, (_index * _sprite_size)))
_current_animation_player.seek(_frame * (_current_animation_player.current_animation_length / (_sprite_num - 1)), true) _current_animation_player.seek(_frame * (_current_animation_player.current_animation_length / (_sprite_num)), true)
_frame += 1 _frame += 1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

After

Width:  |  Height:  |  Size: 43 KiB