소스 검색

Merge pull request #23930 from zer0problem/master

AnimatedSprite: Fixed signal animation_finished
Rémi Verschelde 6 년 전
부모
커밋
aa63b86feb
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      scene/2d/animated_sprite.cpp

+ 2 - 2
scene/2d/animated_sprite.cpp

@@ -398,11 +398,11 @@ void AnimatedSprite::_notification(int p_what) {
 							emit_signal(SceneStringNames::get_singleton()->animation_finished);
 							frame = 0;
 						} else {
+							frame = fc - 1;
 							if (!is_over) {
-								emit_signal(SceneStringNames::get_singleton()->animation_finished);
 								is_over = true;
+								emit_signal(SceneStringNames::get_singleton()->animation_finished);
 							}
-							frame = fc - 1;
 						}
 					} else {
 						frame++;