GclkCounter - The Heart of GameClock
Version 1.0
This module does everythings at counter level. It makes counters,inits them, update them, captures events, start , halt , eventually print the internal datas
use GclkCounter; $whites=GclkCounter->new ; $whites->init($arg,$color) ; $whites-> cntupdate{$timestamp); $whites->print ; # the functions hereafter are only used inside callbacks &start($whites,$blacks,$mainwindow,$white_move_button,$black_move_button)= ; &stop($halt_button,$whites,$blacks) ; &capture($mouse_event,$whites,$blacks ) ;
&capture &stop $start
Create object GclkCounter
Get the parameters from GameClock directly or via Gamesettings and adapts the datas for the counters
When an event more precisely a mouse button is released the state of the counter changes. This determines the following actions:
Change the counter states.
Check times
Update the time counters
Update the move counters
Update the sequence pointers
When a mouse event occurs the first time after enabling the start mode, it determines the mouse button for each player, knowing that the Blacks must push the button at first. It set the newsate of each counter accorging to the mouse button pressed, and after that, it gets a timestamp for calling the methode cntupdate.
Initialization of the program to begin the counting mode.
This routines halt counters , necessary if one player receive a phone call in a friendly situation ;=) or in some case, when people need that an arbiter comes.
Could help for people that wants add new cadences.
Charles Minc, <charles.minc@wanadoo.fr>
<charles.minc@wanadoo.fr>
Please report any bugs or feature requests to bug-gclkcounter at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=GameClock. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-gclkcounter at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc GameClock
You can also look for information at:
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/GameClock
CPAN Ratings
http://cpanratings.perl.org/d/GameClock
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=GameClock
Search CPAN
http://search.cpan.org/dist/GameClock
Copyright 2006 Charles Minc, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install GclkData, copy and paste the appropriate command in to your terminal.
cpanm
cpanm GclkData
CPAN shell
perl -MCPAN -e shell install GclkData
For more information on module installation, please visit the detailed CPAN module installation guide.