RevHardt wrote in Sat Jun 14, 2014 10:57 am:Can I get objects that I add to the scenery to show up on the map and/or the radar?
it would be better to raise the same question in your original thread, my inbox is filling up like crazy due to inquiries like yours, and this one is obviously not just of private interest.RevHardt wrote in Fri Apr 10, 2009 6:31 pm:Sorry to chase you down like this. I'm the guy with the noob questions on Canvas Radar and MapStructure, and how to "Get objects to show up on Map/Radar", if you remember. So here's another:
Now that I'm finally done cloning fgdata.bundle, I realize I don't fully understand what you all you implied when you said "probably consider cloning all 3 repos and building from source". There's canvas-hackers/topics/canvas-map-dialog and there's canvas-hackers/topics/canvas-radar, but I can't find the third repo in question... unless you meant the latest fgdata itself?
Hooray wrote in Mon Jun 16, 2014 1:09 pm:Next, you could adapt this new layer to add some radar-based filtering, or to ensure that scenery objects show up.
now, add the new files to MapStructure.nas: near the end of MapStructure.nas, in the loading code, there's a vector that contains the names to load, e.g. "VOR", "DME", and "TFC"
once that is done, use the new "TARGET" identifier in the foreach vector in the Nasal section of the dialog seen above and its embedded canvas/nasal/load block
modify the ufo to copy such info to a global data structure
RevHardt wrote in Sun Jun 22, 2014 8:22 pm:But that won't work if I want to use another aircraft to fly a sortie. The UFO was used only to export the XML file to be loaded every time via command line.
var searchCmd = func
{
var results = [];
var loadedModels = props.globals.getNode("models").getChildren();
foreach (var model; loadedModels)
if (cmp(substr(model.getValue("path"), 0, 10), "Models/AA/") == 0) # only process models loaded from $FG_ROOT/Models/AA/
append(results, geo.Coord.new().set_latlon(model.getValue("latitude-deg"), model.getValue("longitude-deg")));
return results;
};
If you are adapting an existing navaid layer (e.g. NDB), you may still want to change your lcontroller file to provide a custom layer.searcher._equals function, and make it inherit from MultiSymbolLayer instead of NavaidSymbolLayer.
layer.searcher._equals = func(l, r) 0;
Users browsing this forum: No registered users and 2 guests