* gerard robin -- Saturday 22 December 2007:
> The problem here is we don't  have a generic solution this must
> be calculated for each carrier or any AI object according to the
> .xml file definition , one calculation for Nimitz one for Foch one
> for .......   and so on. 

That's not the problem. Doing that for each carrier is acceptable.
It's not like we'll have dozens of carriers around in the next time.
And even if: noting down offsets is something that we as modelers
do all the time anyway, as we need it in animations.

What would be a *very* bad idea, is to integrate all the offsets
in every single carrier capable aircraft. What we could do for now
is to just add the cat offsets to the model XML file (see attached
patch). You'd then find the coords in /ai/models/carrier/catapults/.
We'd just have to add such a block to each carrier, which is a
matter of minutes. More values could easily be added. It would be
more elegant to do that as a regular XML block, but that's not
supported yet.

m.
Index: nimitz.xml
===================================================================
RCS file: /var/cvs/FlightGear-0.9/data/Models/Geometry/Nimitz/nimitz.xml,v
retrieving revision 1.3
diff -u -p -r1.3 nimitz.xml
--- nimitz.xml	27 Nov 2006 12:54:49 -0000	1.3
+++ nimitz.xml	22 Dec 2007 19:52:18 -0000
@@ -8,6 +8,17 @@ apart from most of the very excellent te
     <status>early-production</status>
     <path>nimitz.ac</path>
 
+    <nasal>
+      <load>
+        cmdarg().setValues({ catapults: { catapult: [
+          { name: "cat-1", "offset-x-m":   9.2771, "offset-y-m":  16.1661, "offset-z-m": 20 },
+          { name: "cat-2", "offset-x-m":  16.8865, "offset-y-m":  -4.2633, "offset-z-m": 20 },
+          { name: "cat-3", "offset-x-m": 106.5510, "offset-y-m": -19.2771, "offset-z-m": 20 },
+          { name: "cat-4", "offset-x-m": 124.6484, "offset-y-m": -29.6417, "offset-z-m": 20 },
+        ]}});
+      </load>
+    </nasal>
+
     <!-- crew to be added later
 
     <model>
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to