Jon S. Berndt wrote:
> I haven't been following this thread very closely. Can someone
> concisely recap what is wanted, here? It's most likely a very simple
> addition for us if it's something we don't now model.
Actually, YASim uses a Nasal-based fuel system that was designed to be
FDM-independent. It doesn't handle the stuff internally at all.
Instead, each engine sets an /engine/engines[n]/fuel-consumed-lbs
property. Each iteration, it adds its newly consumed fuel (that is,
just flow rate * timestep) to this property. The Nasal script then
comes around in a polling loop, sucks this stuff out and subtracts it
from the tanks according to the fuel selector properties.
YASim then just uses each tanks level-lbs property as a pure input
property to set weights on the tank objects.
There are some comments at the top of fuel.nas that try to explain
The big advantage here is that you get to use the fancy fuel dialog
(which works entirely in the property system) to twiddle fuel tank
amounts and selection states at runtime. You can bounce an aircraft
up and down on its gear by filling and emptying its tanks. It's kinda
cool, but then I'm biased because I wrote it. :)
FWIW, another cool thing this dialog gets you is automatic weight
management. You can assign "named" weight objects in your -set.xml
file and use sliders to control their sizes at runtime. Not many of
the YASim aircraft are doing this yet (I did the pa28-161 and a4, I
know). It's a much cleaner interface than having separate FDM
configurations for each aircraft loadout.
Flightgear-devel mailing list