The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Games::Risk::Player - risk player

VERSION

version 3.112820

DESCRIPTION

This module implements a risk player, with all its characteristics.

ATTRIBUTES

type

Player type (human, ai, etc.)

name

Player name.

color

Player color to be used in the gui.

ai_class

The class of the artificial intelligence, if player is an AI.

ai

The reference to the actual AI object, if player is an AI.

cards

The cards (a Games::Risk::Deck object) currently owned by $player.

METHODS

countries

    my @countries = $player->countries;

Return the list of countries (Games::Risk::Country objects) currently owned by $player.

greatness

    my $greatness = $player->greatness;

Return an integer reflecting the greatness of $player. It will raise with the number of owned territories, as well as the number of armies.

AUTHOR

Jerome Quelin

COPYRIGHT AND LICENSE

This software is Copyright (c) 2008 by Jerome Quelin.

This is free software, licensed under:

  The GNU General Public License, Version 3, June 2007