فهرست منبع

Fixed AnimationTreeStateMachine transition priority (last transition was always chosen instead of least cost)

Fixes #31132
PouleyKetchoupp 6 سال پیش
والد
کامیت
aaad50e4d9
1فایلهای تغییر یافته به همراه1 افزوده شده و 0 حذف شده
  1. 1 0
      scene/animation/animation_node_state_machine.cpp

+ 1 - 0
scene/animation/animation_node_state_machine.cpp

@@ -235,6 +235,7 @@ bool AnimationNodeStateMachinePlayback::_travel(AnimationNodeStateMachine *p_sta
 
 			if (cost < least_cost) {
 				least_cost_transition = E;
+				least_cost = cost;
 			}
 		}