Esempio n. 1
0
File: tech.c Progetto: Anatolis/naev
/**
 * @brief Creates a tech group from an XML node.
 */
tech_group_t *tech_groupCreateXML( xmlNodePtr node )
{
   tech_group_t *tech;
   /* Load data. */
   tech  = tech_groupCreate();
   tech_parseNodeData( tech, node );
   return tech;
}
Esempio n. 2
0
/**
 * @brief Creates a tech group from an XML node.
 */
tech_group_t *tech_groupCreateXML( xmlNodePtr node )
{
   tech_group_t *tech;

   /* Load data. */
   tech  = tech_groupCreate();
   tech_parseNodeData( tech, node );

   if (tech->items == NULL) {
      tech_groupDestroy(tech);
      tech = NULL;
   }

   return tech;
}