Comments on: Custom Command with Custom DataRef https:/code-sample/custom-command-with-custom-dataref/ Developer resources for the X-Plane flight simulator Wed, 10 Jul 2019 15:24:06 +0000 hourly 1 https://wordpress.org/?v=6.6.1 By: andre luiz rodrigues da silva https:/code-sample/custom-command-with-custom-dataref/#comment-33863 Wed, 10 Jul 2019 15:24:06 +0000 http://developer.x-plane.com/?post_type=code-sample&p=7975#comment-33863 Qual é a variavel de altitude no xplane?
eu preciso criar um programa em java para ler e retornar o valor da altitude.

What is the altitude variable on the xplane?
I need to create a program in java to read and return the altitude value.

]]>
By: Philipp Ringler https:/code-sample/custom-command-with-custom-dataref/#comment-33321 Fri, 15 Mar 2019 15:50:48 +0000 http://developer.x-plane.com/?post_type=code-sample&p=7975#comment-33321 In reply to TIAGO THIENGO VIEIRA.

The correct way is to provide a custom callback function and register it for the native command, which you found with XPLMFindCommand rather than created. Then, from your callback function where you execute the custom action, return 0 so that your plugin eats the command rather than passing it on to X-Plane.

]]>
By: TIAGO THIENGO VIEIRA https:/code-sample/custom-command-with-custom-dataref/#comment-33320 Fri, 15 Mar 2019 13:07:54 +0000 http://developer.x-plane.com/?post_type=code-sample&p=7975#comment-33320 How do I create a custom command and replace the native with it? I tried to do this, however, the sdk returned that it was an illegal action, to register a native command name. what is the sequence?

]]>