Small bugfix, the previous test always sets _property (these days)
This commit is contained in:
@@ -109,7 +109,10 @@ SGXmlSound::init(SGPropertyNode *root, SGPropertyNode *node,
|
||||
if ( !strcmp(type_str, "avionics") )
|
||||
is_avionics = true;
|
||||
|
||||
_property = root->getNode(node->getStringValue("property", ""), true);
|
||||
string propval = node->getStringValue("property", "");
|
||||
if (propval != "")
|
||||
_property = root->getNode(propval, true);
|
||||
|
||||
SGPropertyNode *condition = node->getChild("condition");
|
||||
if (condition != NULL)
|
||||
_condition = sgReadCondition(root, condition);
|
||||
|
||||
Reference in New Issue
Block a user