Пример #1
0
GearSubsystem::GearSubsystem (DeltaGlider *v)
: DGSubsystem (v)
{
	// create component instances
	AddSubsystem (gearctrl = new GearControl (this));
	AddSubsystem (wheelbrake = new Wheelbrake (this));
}
Пример #2
0
//------------------------------------------------------------------------
//  Get engines system
//------------------------------------------------------------------------
void CFuiProbe::GetEngSubsystems()
{ std::vector<CEngine *>engs;           // List of engines
  veh->eng.GetAllEngines(engs);
  std::vector<CEngine*>::iterator si;
  for (si = engs.begin(); si != engs.end(); si++)
  { CEngine   *eng = (*si);
    AddSubsystem(eng);
    CDependent *dp1 = eng->GetPart(1);
    if (dp1) AddSubsystem(dp1);
    CDependent *dp2 = eng->GetPart(2);
    if (dp2) AddSubsystem(dp2);
  }
  engs.clear();
  return;
}
Пример #3
0
//------------------------------------------------------------------------
//  Init lists of subsystems
//------------------------------------------------------------------------
void CFuiProbe::Init()
{   sBox.SetParameters(this,'lsub',0);
    GetAmpSubsystems();
    GetGasSubsystems();
    GetEngSubsystems();
    GetWhlSubsystems();
    AddSubsystem(globals->clk);
    //--------------------------------------------------------
    sBox.SortAndDisplay();
    globals->dBug = 1;
    //------Display PID --------------------------------------
    spid  = 0;
    GetPidSubsystems();
    bPID.SortAndDisplay();
    globals->wpb  = this;
    ReplacePID();
    //-----Init Popup ----------------------------------------
    pob1.pop->CreatePage(&pob1.men,pob1.lst);
    pob2.pop->CreatePage(&pob2.men,pob2.lst);
    pob1.sub = veh->GetNullSubsystem();
    pob2.sub = veh->GetNullSubsystem();
    ViewOption(pob1,0);
    ViewOption(pob2,0);
    return;
}
Пример #4
0
//------------------------------------------------------------------------
//  Get electrical systems
//------------------------------------------------------------------------
void CFuiProbe::GetAmpSubsystems()
{ std::vector<CSubsystem*>amps;         // List of electrical subsystems
  veh->amp.GetAllSystems(amps);
  std::vector<CSubsystem*>::iterator si;
  for (si = amps.begin(); si != amps.end(); si++) AddSubsystem(*si);
  amps.clear();
}
Пример #5
0
//------------------------------------------------------------------------
//  Get wheel system
//------------------------------------------------------------------------
void CFuiProbe::GetWhlSubsystems()
{ std::vector<CSuspension*>whls;              // List of wheels
  veh->whl.GetAllWheels(whls);
  std::vector<CSuspension*>::iterator wh;
  for (wh = whls.begin(); wh != whls.end(); wh++) AddSubsystem(*wh);
  whls.clear();
  return;
}
Пример #6
0
//------------------------------------------------------------------------
//  Get gas systems
//------------------------------------------------------------------------
void CFuiProbe::GetGasSubsystems()
{   std::vector<CFuelSubsystem*>gass;     // List of gas subsystems
    CFuelSystem *gas = globals->gas;
    if (0 == gas)         return;
    gas->GetAllSystems(gass);
    std::vector<CFuelSubsystem*>::iterator si;
    for (si = gass.begin(); si != gass.end(); si++) AddSubsystem(*si);
    gass.clear();
}