28 #define ERR_NG LOG_STREAM(err, log_mapgen) 29 #define LOG_NG LOG_STREAM(info, log_mapgen) 56 int main(
int argc,
char** argv)
58 int x = 50, y = 50, iterations = 50,
59 hill_size = 50, lakes=3,
60 nvillages = 25, nplayers = 2;
62 x = std::stoi(argv[1]);
66 y = std::stoi(argv[2]);
70 iterations = std::stoi(argv[3]);
74 hill_size = std::stoi(argv[4]);
78 lakes = std::stoi(argv[5]);
82 nvillages = std::stoi(argv[6]);
86 nplayers = std::stoi(argv[7]);
89 srand(std::time(
nullptr));
90 std::cout << generate_map(x,y,iterations,hill_size,lakes,nvillages,nplayers) <<
"\n";
int main(int, char **argv)
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).
virtual void user_config()
Display the interactive screen, which allows the user to modify how the generator behaves...
virtual config create_scenario(std::optional< uint32_t > randomseed={})
static lg::log_domain log_mapgen("mapgen")
Standard logging facilities (interface).
A config object defines a single node in a WML file, with access to child nodes.
virtual std::string create_map(std::optional< uint32_t > randomseed={})=0
Creates a new map and returns it.