NAME
Games::Risk::Resources - utility module to load bundled resources
SYNOPSIS
use Games::Risk::Resources qw{ image };
my $image = image('actexit16');
DESCRIPTION
This module is a focal point to access all resources bundled with Games::Risk
. Indeed, instead of each package to reinvent its loading mechanism, this package provides handy functions to do that.
Moreover, by loading all the images at the same location, it will ensure that they are not loaded twice, cutting memory eating.
SUBROUTINES
Games::Risk::Resources
deals with various resources bundled within the distribution. It doesn't export anything by default, but the following subs are available for your import pleasure.
Image resources
The images used for the GUI are bundled and loaded as Tk::Photo
of $poe_main_window
.
Map resources
Map resources are playable maps, to allow more playing fun.
- my $path = map_path( $name )
-
Return the absolute path of the map
$name
. - my @names = maps( )
-
Return the names of all the maps bundled with
Games::Risk
.
SEE ALSO
AUTHOR
Jerome Quelin, <jquelin at cpan.org>
COPYRIGHT & LICENSE
Copyright (c) 2008 Jerome Quelin, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU GPLv3+.