sprintf(buf, "/consumables/fuel/tank[%d]/density-ppg", i);
fgSetDouble(buf, density * (KG2LBS/CM2GALS));
- sprintf(buf, "/consumables/fuel/tank[%d]/level-gal_us", i);
- fgSetDouble(buf, _airplane.getFuel(i) * CM2GALS / density);
+// set in TankProperties class
+// sprintf(buf, "/consumables/fuel/tank[%d]/level-gal_us", i);
+// fgSetDouble(buf, _airplane.getFuel(i) * CM2GALS / density);
sprintf(buf, "/consumables/fuel/tank[%d]/capacity-gal_us", i);
fgSetDouble(buf, CM2GALS * _airplane.getTankCapacity(i)/density);
w->setMaxteeterdamp(attrf(a,"maxteeterdamp",1000));
w->setRelLenTeeterHinge(attrf(a,"rellenteeterhinge",0.01));
w->setBalance(attrf(a,"balance",1.0));
+ w->setMinTiltYaw(attrf(a,"mintiltyaw",0.0));
+ w->setMinTiltPitch(attrf(a,"mintiltpitch",0.0));
+ w->setMinTiltRoll(attrf(a,"mintiltroll",0.0));
+ w->setMaxTiltYaw(attrf(a,"maxtiltyaw",0.0));
+ w->setMaxTiltPitch(attrf(a,"maxtiltpitch",0.0));
+ w->setMaxTiltRoll(attrf(a,"maxtiltroll",0.0));
+ w->setTiltCenterX(attrf(a,"tiltcenterx",0.0));
+ w->setTiltCenterY(attrf(a,"tiltcentery",0.0));
+ w->setTiltCenterZ(attrf(a,"tiltcenterz",0.0));
+ w->setDownwashFactor(attrf(a, "downwashfactor", 1));
if(attrb(a,"ccw"))
w->setCcw(1);
if(attrb(a,"sharedflaphinge"))
if(a->hasAttribute("compression"))
eng->setCompression(attrf(a, "compression"));
+ if(a->hasAttribute("min-throttle"))
+ eng->setMinThrottle(attrf(a, "min-throttle"));
+
if(a->hasAttribute("turbo-mul")) {
float mul = attrf(a, "turbo-mul");
float mp = attrf(a, "wastegate-mp", 1e6) * INHG2PA;
if(eq(name, "EXTEND")) return ControlMap::EXTEND;
if(eq(name, "HEXTEND")) return ControlMap::HEXTEND;
if(eq(name, "LEXTEND")) return ControlMap::LEXTEND;
+ if(eq(name, "LACCEL")) return ControlMap::LACCEL;
if(eq(name, "INCIDENCE")) return ControlMap::INCIDENCE;
if(eq(name, "FLAP0")) return ControlMap::FLAP0;
+ if(eq(name, "FLAP0EFFECTIVENESS")) return ControlMap::FLAP0EFFECTIVENESS;
if(eq(name, "FLAP1")) return ControlMap::FLAP1;
+ if(eq(name, "FLAP1EFFECTIVENESS")) return ControlMap::FLAP1EFFECTIVENESS;
if(eq(name, "SLAT")) return ControlMap::SLAT;
if(eq(name, "SPOILER")) return ControlMap::SPOILER;
if(eq(name, "CASTERING")) return ControlMap::CASTERING;
if(eq(name, "COLLECTIVE")) return ControlMap::COLLECTIVE;
if(eq(name, "CYCLICAIL")) return ControlMap::CYCLICAIL;
if(eq(name, "CYCLICELE")) return ControlMap::CYCLICELE;
+ if(eq(name, "TILTROLL")) return ControlMap::TILTROLL;
+ if(eq(name, "TILTPITCH")) return ControlMap::TILTPITCH;
+ if(eq(name, "TILTYAW")) return ControlMap::TILTYAW;
if(eq(name, "ROTORGEARENGINEON")) return ControlMap::ROTORENGINEON;
if(eq(name, "ROTORBRAKE")) return ControlMap::ROTORBRAKE;
if(eq(name, "ROTORENGINEMAXRELTORQUE"))
return ControlMap::ROTORENGINEMAXRELTORQUE;
- if(eq(name, "ROTORELTARGET")) return ControlMap::ROTORELTARGET;
+ if(eq(name, "ROTORRELTARGET")) return ControlMap::ROTORRELTARGET;
+ if(eq(name, "ROTORBALANCE")) return ControlMap::ROTORBALANCE;
if(eq(name, "REVERSE_THRUST")) return ControlMap::REVERSE_THRUST;
if(eq(name, "WASTEGATE")) return ControlMap::WASTEGATE;
if(eq(name, "WINCHRELSPEED")) return ControlMap::WINCHRELSPEED;
return s2;
}
-int FGFDM::attri(XMLAttributes* atts, char* attr)
+int FGFDM::attri(XMLAttributes* atts, const char* attr)
{
if(!atts->hasAttribute(attr)) {
SG_LOG(SG_FLIGHT,SG_ALERT,"Missing '" << attr <<
return attri(atts, attr, 0);
}
-int FGFDM::attri(XMLAttributes* atts, char* attr, int def)
+int FGFDM::attri(XMLAttributes* atts, const char* attr, int def)
{
const char* val = atts->getValue(attr);
if(val == 0) return def;
else return atol(val);
}
-float FGFDM::attrf(XMLAttributes* atts, char* attr)
+float FGFDM::attrf(XMLAttributes* atts, const char* attr)
{
if(!atts->hasAttribute(attr)) {
SG_LOG(SG_FLIGHT,SG_ALERT,"Missing '" << attr <<
return attrf(atts, attr, 0);
}
-float FGFDM::attrf(XMLAttributes* atts, char* attr, float def)
+float FGFDM::attrf(XMLAttributes* atts, const char* attr, float def)
{
const char* val = atts->getValue(attr);
if(val == 0) return def;
else return (float)atof(val);
}
-double FGFDM::attrd(XMLAttributes* atts, char* attr)
+double FGFDM::attrd(XMLAttributes* atts, const char* attr)
{
if(!atts->hasAttribute(attr)) {
SG_LOG(SG_FLIGHT,SG_ALERT,"Missing '" << attr <<
return attrd(atts, attr, 0);
}
-double FGFDM::attrd(XMLAttributes* atts, char* attr, double def)
+double FGFDM::attrd(XMLAttributes* atts, const char* attr, double def)
{
const char* val = atts->getValue(attr);
if(val == 0) return def;
// Unfortunately, this usage creeped into existing configuration files
// while I wasn't active, and it's going to be hard to remove. Issue
// a warning to nag people into changing their ways for now...
-bool FGFDM::attrb(XMLAttributes* atts, char* attr)
+bool FGFDM::attrb(XMLAttributes* atts, const char* attr)
{
const char* val = atts->getValue(attr);
if(val == 0) return false;