27 #define ERR_NG LOG_STREAM(err, log_mapgen)
28 #define LOG_NG LOG_STREAM(info, log_mapgen)
55 int main(
int argc,
char** argv)
57 int x = 50, y = 50, iterations = 50,
58 hill_size = 50, lakes=3,
59 nvillages = 25, nplayers = 2;
61 x = std::stoi(argv[1]);
65 y = std::stoi(argv[2]);
69 iterations = std::stoi(argv[3]);
73 hill_size = std::stoi(argv[4]);
77 lakes = std::stoi(argv[5]);
81 nvillages = std::stoi(argv[6]);
85 nplayers = std::stoi(argv[7]);
88 srand(std::time(
nullptr));
89 std::cout << generate_map(x,y,iterations,hill_size,lakes,nvillages,nplayers) <<
"\n";
A config object defines a single node in a WML file, with access to child nodes.
virtual config create_scenario(utils::optional< uint32_t > randomseed={})
virtual std::string create_map(utils::optional< uint32_t > randomseed={})=0
Creates a new map and returns it.
virtual void user_config()
Display the interactive screen, which allows the user to modify how the generator behaves.
virtual bool allow_user_config() const
Returns true if the map generator has an interactive screen, which allows the user to modify how the ...
Definitions for the interface to Wesnoth Markup Language (WML).
Standard logging facilities (interface).
static lg::log_domain log_mapgen("mapgen")