plane icon Welcome to Microsoft Flight Simulator’s SDK Q&A Platform!

You have questions regarding the SDK? DevMode Tools? SimConnect? You would like to submit an idea for future improvements, seek help or exchange knowledge? You’re in the right place.

In the upcoming flighting, we've changed the behaviour of the content.xml file. If your addon uses this file, please read this article!

Please take a moment to read the platform’s guidelines before you get started!


question

Simbol avatar image
Simbol asked Simbol edited

Contact Points on the Ground

Hello,

The variable A:CONTACT POINT IS ON GROUND is reporting wrong values while loading a flight, for example a scrape point which is not touching the ground will report True while the loading screen for a flight is happening.

As a consequence when the flight loads, for a short period of time, it reports the contact point is on the ground, throwing the logic of crash detection for our code out..

Thanks,

Simbol

aircraft
10 |10000

Up to 5 attachments (including images) can be used with a maximum of 4.8 MiB each and 23.8 MiB total.

1 Answer

·
FlyingRaccoon avatar image
FlyingRaccoon answered Simbol edited

Hello @Simbol

Obviously, this simvar is not reliable while loading the terrain.
To handle this kind of problem, we usually use the CAMERA STATE simvar to know when the loading has ended.
I just noticed the documented values for that simvar are not all correct and seem to have changed overtime. That's an issue we'll address asap

Regards,
Sylvain

1 comment
10 |10000

Up to 5 attachments (including images) can be used with a maximum of 4.8 MiB each and 23.8 MiB total.

Simbol avatar image Simbol commented ·

Hi Sylvain,


Many thanks for the feedback. I can confirm I am not using these to detect a flight is loaded, I do use the CAMERA STATE alongside with other things to be 100% sure a flight has started.

The problem I was experiencing was because I am using a custom prop crash detection which triggers animations and engine damage, but unfortunately for some reason, this code (which was in the model behaviour) would activate during the loading screen since the sim var was changing 0, 1, 0, 1, 0 while loading the flight and the airplane ended up loading with the props already in crash state. It also happened even when the user was trying load a flight already in the air..

The behaviour was kind of difference between users (my beta testers), it seems the faster the PC the chances of this problem from occurring increased. So as a way around, I moved the code to a WASM module since WASM always loads at a much later state of the flight loading and I was also able to put a delay to allow the system to stabilise before checking if the props contact points were hitting the ground. This solution keep me going.

However I still wanted to report this to you guys since in my view the A:CONTACT POINT IS ON GROUND should not become "true" under any circumstances than actually hitting the ground.

Once again many thanks for all the efforts to correct these issues. I hope my feedback and reports are valuable to the team and the rest of the 3rd party community, my main objective is to keep increasing the quality of the SDK since everyone will benefits from it :).

Best Regards,
Raul

1 Like 1 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 5 attachments (including images) can be used with a maximum of 19.1 MiB each and 23.8 MiB total.