Ejemplo n.º 1
0
	void read_justice_zones()
	{
	  gamestate.justicedef = new JusticeDef( "Justice" );
	  read_region_data( *gamestate.justicedef,
						"regions/justice.cfg", // preferred
						"regions/regions.cfg", // other
						"JusticeRegion Region" );


	}
Ejemplo n.º 2
0
void read_resources_dat()
{
  std::string resourcefile = Plib::systemstate.config.world_data_path + "resource.dat";

  if ( Clib::FileExists( resourcefile ) )
  {
    Clib::ConfigFile cf( resourcefile, "GLOBALRESOURCEPOOL REGIONALRESOURCEPOOL" );
    Clib::ConfigElem elem;
    while ( cf.read( elem ) )
    {
      if ( elem.type_is( "GlobalResourcePool" ) )
      {
        read_global_data( elem );
      }
      else
      {
        read_region_data( elem );
      }
    }
  }
}