void FGAIEscort::setParent() {
- const SGPropertyNode *ai = fgGetNode("/ai/models", true);
+ const SGPropertyNode_ptr ai = fgGetNode("/ai/models", true);
for (int i = ai->nChildren() - 1; i >= -1; i--) {
- const SGPropertyNode *model;
+ SGPropertyNode_ptr model;
if (i < 0) { // last iteration: selected model
model = _selected_ac;
double _max_speed;
const SGMaterial* _material;
- const SGPropertyNode *_selected_ac;
+ SGPropertyNode_ptr _selected_ac;
bool _MPControl, _patrol, _stn_deg_true;
void FGAIGroundVehicle::setParent() {
- const SGPropertyNode *ai = fgGetNode("/ai/models", true);
+ const SGPropertyNode_ptr ai = fgGetNode("/ai/models", true);
for (int i = ai->nChildren() - 1; i >= -1; i--) {
- const SGPropertyNode *model;
+ SGPropertyNode_ptr model;
if (i < 0) { // last iteration: selected model
model = _selected_ac;
double _dt_count, _next_run, _break_count;
const SGMaterial* _material;
- const SGPropertyNode *_selected_ac;
+ SGPropertyNode_ptr _selected_ac;
string _parent;
double _rightBrakeOutput;
SGPropertyNode_ptr _root;
- SGPropertyNode* _brakeInputs[4];
+ SGPropertyNode_ptr _brakeInputs[4];
SGPropertyNode_ptr _weightOnWheelsNode;
SGPropertyNode_ptr _engineControlsNode;
SGPropertyNode_ptr _groundspeedNode;
SGPropertyNode_ptr _apTargetAltitudeFt;
SGPropertyNode_ptr _apAltitudeLock;
- std::vector<SGPropertyNode*> _tiedNodes;
+ std::vector<SGPropertyNode_ptr> _tiedNodes;
};
bool build ();
private:
- SGPropertyNode *config_props;
+ SGPropertyNode_ptr config_props;
bool _explicitGps;
};
double _gsNeedleDeflectionNorm;
SGSharedPtr<SGSampleGroup> _sgr;
- std::vector<SGPropertyNode*> _tiedNodes;
+ std::vector<SGPropertyNode_ptr> _tiedNodes;
bool updateWithPower(double aDt);
template <typename T>
void tie(const char* aRelPath, const SGRawValue<T>& aRawValue)
{
- SGPropertyNode* nd = _radio_node->getNode(aRelPath, true);
+ SGPropertyNode_ptr nd = _radio_node->getNode(aRelPath, true);
_tiedNodes.push_back(nd);
nd->tie(aRawValue);
}
string name;
int num;
string path;
- SGPropertyNode *config_props;
+ SGPropertyNode_ptr config_props;
bool enabled;
bool build ();
private:
- SGPropertyNode *config_props;
+ SGPropertyNode_ptr config_props;
bool enabled;
};