Open ykeuter opened 4 years ago
I changed this execution order in PR #3128 .
Without these changes, on the first call to FixedUpdate
the drones are positioned at the origin (since poseFromAirLib
is not set yet), causing a collision. AirSim then processes this collision, but at the actual position of the drones, causing the drones to tumble down.
Something similar happens in single drone mode. In this case the "fake" collision (with the floor at the origin now) is interpreted as a landing by AirSim, making the drone "hover" mid-air at the start, even though it is only armed.
This issue has been automatically marked as stale because it has not had activity from the community in the last year. It will be closed if no further activity occurs within 20 days.
InvokeTickInAirSim
is called inLateUpdate
: https://github.com/microsoft/AirSim/blob/d59ceb7f63878f5e087ea802d603ba0fd282ff56/Unity/UnityDemo/Assets/AirSimAssets/Scripts/Vehicles/Vehicle.cs#L116 whiletransform
is updated inFixedUpdate
: https://github.com/microsoft/AirSim/blob/d59ceb7f63878f5e087ea802d603ba0fd282ff56/Unity/UnityDemo/Assets/AirSimAssets/Scripts/Vehicles/Multirotor/Drone.cs#L41 Is there a reason for this?FixedUpdate
andLateUpdate
are not necessarily in sync.Also, I would expect
currentPose = poseFromAirLib;
aftertransform
is updated.What am I missing?