The Perl and Raku Conference 2025: Greenville, South Carolina - June 27-29 Learn more

NAME

Game::TextMapper::Solo - generate a map generated step by step

SYNOPSIS

my $map = Game::TextMapper::Solo->new->generate_map();
print $map;

DESCRIPTION

This starts the map and generates all the details directly, for each step, without knowledge of the rest of the map. The tricky part is to generate features such that no terrible geographical problems arise.

ATTRIBUTES

rows

The height of the map, defaults to 15.

my $map = Game::TextMapper::Solo->new(rows => 20)
->generate_map;
print $map;

cols

The width of the map, defaults to 30.

my $map = Game::TextMapper::Solo->new(cols => 40)
->generate_map;
print $map;

METHODS

generate_map

This method takes no arguments. Set the properties of the map using the attributes.