Function Blam::Config::LoadConfig(std::string, bool, int, const char *)

Function Documentation

int Blam::Config::LoadConfig(std::string filename, bool load_defaults, int defaults_resource_id, const char *defaults_res_type)

Loads a configuration file from the specified path.

Return

- Will return negative if the file failed to load, will return 0 if file was loaded without error.

Parameters
  • filename: - The path to the configuration file

  • load_defaults: - Whether or not to load defaults from an embedded resource.

  • defaults_resource_id: - The resource ID that refers to the file containing the default configuration file contents.

  • defaults_res_type: - The type of resource that the default configuration file is stored in. Should almost always be "CFG"