[Add] Star system can now set nebuale density and volatility.

This commit is contained in:
Allanis 2013-07-21 13:33:43 +01:00
parent 9fb781d27e
commit df8af779ee

View File

@ -634,6 +634,14 @@ static StarSystem* system_parse(const xmlNodePtr parent) {
flags |= FLAG_INTEFERENCESET; flags |= FLAG_INTEFERENCESET;
tmp->interference = xml_getFloat(cur)/100; tmp->interference = xml_getFloat(cur)/100;
} }
else if(xml_isNode(cur, "nebulae")) {
ptrc = xml_nodeProp(cur, "volatility");
if(ptrc != NULL) { /* Has volatility. */
tmp->nebu_volatility = atof(ptrc);
free(ptrc);
}
tmp->nebu_density = xml_getFloat(cur);
}
}while(xml_nextNode(cur)); }while(xml_nextNode(cur));
} }
/* Load all the planets. */ /* Load all the planets. */