April 8, 200323 yr Hello there..I want to build an add-on that requires an overlay window. It will be like a moving map that I'd like to be available from a drop-down menu item rather than as a gauge that needs to be associated with each aircraft. Can somebody provide me with any pointers on doing this? All I need from the simulator is lat-long info in real-time. I've looked through the gauges SDK, but didn't see it.Any and all help greatly appreciated.JM
April 8, 200323 yr Welcome to the forums! :-)From the Panels and Gauges SDK, TokenVar.doc:PLANE_LATITUDETo get degrees divide by 40007000 and multiply by 360;PLANE_LONGITUDETo get degrees divide by 281474976710656 and multiply by 360.Furthermore you will need special code for the in-menu thing.Etienne :-wave
April 8, 200323 yr Thanks for the prompt response! I've checked this out and it may be the solution. May be more than what I need, but it looks good..CheerioJM
April 8, 200323 yr Can anybody give me more pointers on "special code?" I looked at FSUIPC--it's a start, but perhaps doesnt help me too much in this regard from what I can tell.I'm an experienced programmer, but new to FS.thanksJ
April 9, 200323 yr Hi JM,for the menus, here is a good start. For going further:http://ftp.avsim.com/dcforum/DCForumID9/2339.html#12====================================================================#define MENOPT1 MF_BYCOMMAND|MF_ENABLED|MF_STRING|MF_DEFAULT|MF_SYSMENU|MF_HELP|MF_MOUSESELECT#define MENOPT2 MF_BYCOMMAND|MF_ENABLED|MF_STRINGvoid MakeFSMEnu(void){ fshwnd = FindWindow("FS98MAIN", NULL); // now get the handle to the FS menu if (fshwnd != NULL) { fsmenu = GetMenu(fshwnd); if (fsmenu != NULL) { optionmenu = GetSubMenu(fsmenu,3); if (optionmenu != NULL) { AppendMenu(optionmenu, MF_SEPARATOR | MENOPT2, 0, NULL); menu = CreatePopupMenu(); AppendMenu(menu, MENOPT2 , 0x9800, "Piper Meridian"); AppendMenu(menu, MENOPT2 , 0x9801, "Flight Line Avionics"); AppendMenu(optionmenu, MF_POPUP | MENOPT2, menu, "Reality XP");// AppendMenu(fsmenu, MENOPT2, menu, "Reality XP"); DrawMenuBar(fshwnd); }Hope this helps!
Create an account or sign in to comment