Go Back   Orbiter-Forum > Orbiter Space Flight Simulator > Orbiter SDK
Register Blogs Orbinauts List Social Groups FAQ Projects Mark Forums Read

Orbiter SDK Orbiter software developers post your questions and answers about the SDK, the API interface, LUA, meshing, etc.

Thread Tools
Old 12-05-2017, 05:53 PM   #1
slaver0110's Avatar
Default oapiBroadcastMFDMessage usage

In working on my StationTug I've been rifling through the Dragonfly code to get a feel for coding docking port management, and I came across oapiBroadcastMFDMessage.

In the Dragonfly code, the usage seems to make a call to the stock DockingMFD, and after playing around with it, when used in clbkDockEvent, oapiBroadcastMFDMessage seems to change the DockingMFD to another port.
(I could be wrong, wouldn't be the first time...)

In the OrbiterAPI Guide, all I can find is the function itself, without a description of how it's used:

"oapiBroadcastMFDMessage(int mode, int msg, void *data)"

Could anyone offer a little guidance on how this function is used, particularly in connection with DockingMFD?

Cheers, and thanx!!

ETA: All I can clearly see is that it sends a struct to the DockingMFD:

struct { OBJHANDLE hObj; int dock; } dockspec;
dockspec.hObj = mate;
dockspec.dock = remoteport = (dock ? 0 : -1);
oapiBroadcastMFDMessage(MFD_DOCKING, 0, (void*)&dockspec);

Last edited by slaver0110; 12-05-2017 at 06:06 PM. Reason: Added example
slaver0110 is offline   Reply With Quote
Old 12-05-2017, 11:47 PM   #2
ADSWNJ's Avatar

Interesting! I have never come across that before. It's like a protoype of the ModuleMessagingExt system (though ModuleMessagingExt has much more flexibility and controls around data passing).
ADSWNJ is offline   Reply With Quote
Old 12-06-2017, 03:44 AM   #3
slaver0110's Avatar

I've been using MMExt for quite a wile, as a prerequisite for certain addons. Had no idea this did the same thing.
Any help on it's usage?

Cheers, and thanx again!
slaver0110 is offline   Reply With Quote
Old 12-06-2017, 09:15 AM   #4
Mostly harmless
Enjo's Avatar


It looks like we've redesigned the wheel, but I still like our compile time checks more than void *data and friends. Such constructs contribute to Orbiter's instability in general.

Originally Posted by slaver0110 View Post
 Any help on it's usage?
First read the documentation.
Then see the examples. It's pretty simple:

LaunchMFD sending out ID of the currently targeted vessel:

TransX sending out burn parameters:

BurnTimeCalculator receiving TransX' parameters:

Last edited by Enjo; 12-06-2017 at 10:23 AM.
Enjo is offline   Reply With Quote
Old 12-07-2017, 01:30 AM   #5
ADSWNJ's Avatar

Our wheel is rounder, Enjo

Actually - just starting a piece of work for new features for MM Ext, for delivery on a Tuesday sometime next year .
ADSWNJ is offline   Reply With Quote
Thanked by:

  Orbiter-Forum > Orbiter Space Flight Simulator > Orbiter SDK

Thread Tools

Posting Rules
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Jump

All times are GMT. The time now is 12:37 PM.

Quick Links Need Help?

About Us | Rules & Guidelines | TOS Policy | Privacy Policy

Orbiter-Forum is hosted at Orbithangar.com
Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Copyright 2007 - 2017, Orbiter-Forum.com. All rights reserved.