Games::HotPotato - A random length hot-potato timer with a dramatic ending
version 0.110020
use Games::HotPotato; my $hot_potato = Games::HotPotato->new; $hot_potato->minimum_time({ seconds => 20 }); $hot_potato->maximum_time({ seconds => 40 }); $hot_potato->maximum_rush({ seconds => 15 }); $hot_potato->minimum_rush({ seconds => 5 }); $hot_potato->start_alert('bing.wav'); $hot_potato->start_music('calm.wav'); $hot_potato->start_rush_alert('dumdumdum.wav'); $hot_potato->rush_music('urgent.wav'); $hot_potato->final_alert('crash.wav'); $hot_potato->run;
This class holds the internals for the hot-potato game. See hot-potato.
This is the minimum duration for the hot potato timer. Default is 20 seconds.
This is the maximum duration for the hot potato timer. Defaut is 40 seconds. This must be greater than or equal to "minumum_time".
This is the minimum duration for the rush time. Default is 5 seconds. This must be less than the "minimum_time".
This is the maximum duration for the rush time. Default is 15 seconds. This must be greater than or equal to "minimum_rush" and must be less than the "minimum_time".
This is the sound theme to use. This is set to "zostay" by default.
This is the sound to play to announce that the game has begun.
This is the sound to play when the rush starts.
This is the sound to announce that the game is over.
This is the sound or music to play and repeat at the start of the game after the "start_alert" is played.
This is the sound or music to play and repeat during the rush at the end of the game after the "rush_alert" is played.
This contains a hash of configuration information for the game.
The configuration is loaded from the data section of this module file and then merged with the configuration found at .hotpotato/config.ini in the user's home directory.
Loads a configured file path from the current sound theme and returns.
Looks for a file in the resource directories for Games::HotPotato. This includes the directory named after this module in the Perl library directory. The secondary location is the .hotpotato directory in the user's home directory.
Generate a random time.
Start the timer.
hot-potato
Andrew Sterling Hanenkamp <hanenkamp@cpan.org>
This software is copyright (c) 2011 by Qubling Software LLC.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Games::HotPotato, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Games::HotPotato
CPAN shell
perl -MCPAN -e shell install Games::HotPotato
For more information on module installation, please visit the detailed CPAN module installation guide.