Games::Risk::Country - map country
version 4.000
This module implements a map country, with all its characteristics. The word country is a bit loose, since for some maps it can be either a region, a suburb... or a planet! :-)
The country name.
A Games::Risk::Continent object in which the country is located.
An integer between 1 and 254 corresponding at the grey (all RGB values set to greyval()) used to draw the country on the grey-scale map.
greyval()
Alias for greyval.
greyval
The x location of the country capital.
The y location of the country capital.
A list of country ids that can be accessed from the country. Note that it's not always reciprocical (connections can be one-way).
A Games::Risk::Player object currently owning the country.
Games::Risk::Player
Number of armies currently in the country.
my @neighbours = $country->neighbours;
Return the list of $country's neighbours (Games::Risk::Country objects).
$country
my $bool = $country->is_neighbour( $c );
Return true if $country is a neighbour of country $c, false otherwise.
$c
Jerome Quelin
This software is Copyright (c) 2008 by Jerome Quelin.
This is free software, licensed under:
The GNU General Public License, Version 3, June 2007
To install Games::Risk, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Games::Risk
CPAN shell
perl -MCPAN -e shell install Games::Risk
For more information on module installation, please visit the detailed CPAN module installation guide.