Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide model info via dataRef to 3rd party plugins when having AI control #26

Closed
2 tasks done
TwinFan opened this issue Dec 3, 2020 · 0 comments
Closed
2 tasks done
Labels
enhancement New feature or request

Comments

@TwinFan
Copy link
Owner

TwinFan commented Dec 3, 2020

Current Situation / Problem
3rd party plugins cannot find out which model a rendered plane uses.
There is a use case at least for the camera plugin ABC, which asks for a value similar to what LTAPI returns through LTAPIAircraft::getCslModel().

Suggested Solution

Extend the already existing set of shared dataRefs:

  • Add a shared dataRef sim/multiplayer/position/plane#_cslModel filled with XPMP2::Aircraft::GetModelName()
  • Document the new shared dataRef in the developer docs

Benefits
Use cases are probably limited...but at least ABC has what it asks for. It somehow uses it to fine-tune the camera per displayed model.

Additional context
Discussed in a support thread in the context of the Remote Client. The solution will be generic for XPMP2, however, ie. for any plugin based on XPMP2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant