Is it possible to display messages on-screen (similar to ATC call-outs) from a stand-alone WASM module?
Please take a moment to read the platform’s guidelines before you get started!
If you mean for debugging purposes, then any output to stdout or stderr shows up in the "Console" window of the Dev Mode. Each individual write to stderr shows up as one line (even if just a few characters not ended with a newline), so make sure to do some own buffering if necessary and write out complete lines that don't need to end with a newline (but will show up as a separate line anyway). As in:
// Output to std::cerr is unbuffered, and appears in the Console // window each part on a separate line. Not ideal. So collect // output to std::cerr into one string and write it in one go. std::stringstream output; output << THISAIRCRAFT ": The call '" << call << "' failed at line " << lineNumber; std::cerr << output.str() << std::flush;
The "legacy" SIMCONNECT_TEXT call will feed into the Notification system.
Thanks, I tried that, but no text was displayed. My call was:
hr = SimConnect_Text(g_hSimConnect, SIMCONNECT_TEXT_TYPE_PRINT_MAGENTA, 5, EVENT_TEXT, strlen(msg), msg);
Also, the documentation (I know it may be way behind) says:
The SimConnect_Text function is not currently available for use.
That's because the Simconnect_Text is tied to the flying Tips feature so, if it's disabled, you won't see anything. This is something we asked a while ago to be improved because:
If Tips are disabled, there's no way to send any feedback to the user.
The original call in FSX allowed to select a text color and, most importantly, the message duration. Right now, the text always appear as a Tip, with a fixed length of about 8 seconds, which means if something sends many calls in a short while, it will take a while to clear all the messages left in the queue. FSX could use scrolling text, MSFS can't.
And, most importantly, the SIMCONNECT_TEXT_TYPE_MENU is not supported, which is very limiting, considering it was very useful to do simple user interactions.
4 People are following this question.