소스 검색

[godot] Don't apply "[stop]" animation.

badlogic 3 년 전
부모
커밋
bcf20d764b
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      spine-godot/spine_godot/SpineAnimationTrack.cpp

+ 2 - 2
spine-godot/spine_godot/SpineAnimationTrack.cpp

@@ -294,8 +294,8 @@ void SpineAnimationTrack::update_animation_state(const Variant &variant_sprite)
 		animation_state->clearTrack(track_index);
 		if (found_track_index == -1) return;
 
-		// If no animation is set, we are done.
-		if (EMPTY(animation_name)) return;
+		// If no animation is set or it's set to "[stop]", we are done.
+		if (EMPTY(animation_name) || animation_name == "[stop]") return;
 		
 		// If there's no keys on the timeline for this track, we are done.
 		if (edited_animation->track_get_key_count(found_track_index) == 0) return;