mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2025-01-10 21:09:38 +01:00
fix: emit target_reached signal after updating state
This commit is contained in:
parent
9e43e62e3b
commit
799a6e334f
@ -492,8 +492,8 @@ void NavigationAgent2D::_request_repath() {
|
|||||||
void NavigationAgent2D::_check_distance_to_target() {
|
void NavigationAgent2D::_check_distance_to_target() {
|
||||||
if (!target_reached) {
|
if (!target_reached) {
|
||||||
if (distance_to_target() < target_desired_distance) {
|
if (distance_to_target() < target_desired_distance) {
|
||||||
emit_signal("target_reached");
|
|
||||||
target_reached = true;
|
target_reached = true;
|
||||||
|
emit_signal("target_reached");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user