Menu

#2193 JSBSim, replay: spawning with CG at set coordinates instead of VRP

None
New
nobody
Low
2022-04-19
2020-03-05
No

If you respawn either after closing replay, the aircraft is moved a bit. It always happens, but is much more pronounced if JSBSim <location name="CG"> is non-zero.

Reload Scenery function does not seem to expecience this problem.

Do not know if YASim is affected.

Discussion

  • xDraconian

    xDraconian - 2020-07-19
    • labels: --> Aircraft, Replay, Respawn
     
  • Anonymous

    Anonymous - 2022-04-19

    Reproduction

    Add this to Models/Tu-144D of https://gitlab.com/mdanil/Tu-144D
    (the values from Tu-144D-jsbsim/metrics.xml and Tu-144D-jsbsim/mass.xml, and VRP cursor should always be at 0 (or the main <offsets> of the model.xml), and all other points must have it subtracted from them):

     <model>
      <name>VRP</name>
      <path>Aircraft/ufo/Models/cursor.ac</path>
      <offsets>
       <x-m>0.0</x-m>
       <y-m>0.0</y-m>
       <z-m>0.0</z-m>
      </offsets>
     </model>
    
     <model>
      <name>CG</name>
      <path>Aircraft/ufo/Models/cursor.ac</path>
      <offsets>
       <x-m>2.610</x-m>
       <y-m>0.0</y-m>
       <z-m>0.0</z-m>
      </offsets>
     </model>
    
     <model>
      <name>AERORP</name>
      <path>Aircraft/ufo/Models/cursor.ac</path>
      <offsets>
       <x-m>2.378</x-m>
       <y-m>0.0</y-m>
       <z-m>-0.58</z-m>
      </offsets>
     </model>
    
     <model>
      <name>EYEPOINT</name>
      <path>Aircraft/ufo/Models/cursor.ac</path>
      <offsets>
       <x-m>-27.7515</x-m>
       <y-m>-0.5</y-m>
       <z-m>1.16375</z-m>
      </offsets>
     </model>
    
     <animation>
      <type>material</type>
      <object-name>VRP</object-name>
      <emission>
       <red>1.0</red>
       <green>0.0</green>
       <blue>0.0</blue>
      </emission>
     </animation>
     <animation>
      <type>material</type>
      <object-name>CG</object-name>
      <emission>
       <red>0.0</red>
       <green>1.0</green>
       <blue>0.0</blue>
      </emission>
     </animation>
     <animation>
      <type>material</type>
      <object-name>AERORP</object-name>
      <emission>
       <red>0.0</red>
       <green>0.0</green>
       <blue>1.0</blue>
      </emission>
     </animation>
     <animation>
      <type>material</type>
      <object-name>EYEPOINT</object-name>
      <emission>
       <red>1.0</red>
       <green>1.0</green>
       <blue>0.0</blue>
      </emission>
     </animation>
    

    Run FG with some coordinats, for example aparking in EDDH: --lat=53.62807947785572 --lon=9.993584269256779 --heading=241.5559801997424

    Run this in Nasal console:

    geo.put_model("Aircraft/ufo/Models/cursor.ac", 53.62807947785572, 9.993584269256779, geo.elevation(53.62807947785572, 9.993584269256779));
    

    Expected: cursor spawns under the model's VRP
    Have: cursor spawns under empty CG

     

    Last edit: Anonymous 2022-04-19
  • Anonymous

    Anonymous - 2022-04-19
    • summary: JSBSim, replay: moving forward on respawn. --> JSBSim, replay: spawning with CG at set coordinates instead of VRP
     
  • Anonymous

    Anonymous - 2022-04-19

    And I have made a model.xml that can be included in any JSBSim aircraft to visualize the points:

     

    Last edit: Anonymous 2022-04-19

Log in to post a comment.

MongoDB Logo MongoDB