From be6936be80566b8bc376ccbaa89c0efc30fbb5b4 Mon Sep 17 00:00:00 2001 From: ehofman Date: Mon, 23 Aug 2004 17:22:55 +0000 Subject: [PATCH] Vivian Meazza: Well here's some tracer stuff. If fiddled around with submodel.cxx. It now does what it says - you need to put this: true 120 In the *-set.xml file NOT within . Trouble is it still defaults to serviceable=true, but it also defaults to amount=0. Unless this bit of code is included it wont run, so other models can't fire inappropriate tracer. Revised submodel.cxx file attached. I've changed to a non-billboard solution. I tried to make the viewing angle of the tracer less than 180 degs, but failed. Close enough I think. It's still a bit big, but a reasonable compromise. .AC file attached. I remain concerned about the tracer colour. In practice, red is better (and it's what I am used to) but David seems set on white, and I don't want to upset him. I'm going to adjust the texture a bit more tomorrow. --- src/Systems/submodel.cxx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/Systems/submodel.cxx b/src/Systems/submodel.cxx index a1a3e5fae..228a01a2d 100644 --- a/src/Systems/submodel.cxx +++ b/src/Systems/submodel.cxx @@ -26,12 +26,14 @@ void SubmodelSystem::init () { _serviceable_node = fgGetNode("/systems/submodel/serviceable", true); - _serviceable_node->setBoolValue(true); + _serviceable_node->setBoolValue(false); + _trigger_node = fgGetNode("/systems/submodel/trigger", true); _trigger_node->setBoolValue(false); + _amount_node = fgGetNode("/systems/submodel/amount", true); - _amount_node->setIntValue(60); - + _amount_node->setIntValue(0); + _user_lat_node = fgGetNode("/position/latitude-deg", true); _user_lon_node = fgGetNode("/position/longitude-deg", true); _user_alt_node = fgGetNode("/position/altitude-ft", true); @@ -85,7 +87,7 @@ SubmodelSystem::release (double dt) if (elapsed_time < 0.25) return false; elapsed_time = 0.0; - int rval = ai->createBallistic( "Models/Geometry/tracer.xml", + int rval = ai->createBallistic( "Models/Geometry/tracer.ac", _user_lat_node->getDoubleValue(), _user_lon_node->getDoubleValue(), _user_alt_node->getDoubleValue() + z_offset,