25 Sep 2013 00:58:26 UTC
- Distribution: Games-Bowling-Scorecard
- Module version: 0.105
- Source (raw)
- Browse (raw)
- How to Contribute
- Testers (395 / 0 / 0)
- KwaliteeBus factor: 1
- 99.41% Coverage
- License: perl_5
- Download (18.71KB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest version
- COPYRIGHT AND LICENSE
Games::Bowling::Scorecard::Frame - one frame on a scorecard
A frame is one attempt to knock down all ten pins -- unless it's the tenth frame, in which case it's so goofy that you need to use a different class, Games::Bowling::Scorecard::Frame::TenPinTenth. A frame is done when you've bowled twice or knocked down all the pins, and it's pending until its score can be definitively be stated.
This method returns a new frame object.
This method records a single ball against the frame. This method is used for both the current frame and for pending frames. It updates the frame's score and whether the frame is done or pending.
This method asserts that given value is an acceptable number to score next in this frame. It checks that:
* the frame is not already done * $ball is defined, an integer, and between 0 and 10 * $ball would not bring the total number of pins downed above 10
This method returns the current score for the frame, even if the frame is not done or is pending further balls.
This method returns true if the frame is pending more balls -- that is, it returns true for strikes or spares which have not yet recorded the results of subsequent balls.
This method returns true if the frame is done.
This method returns the balls recorded against the frame, each ball returned as the number of pins it knocked down. In scalar context, it returns the number of balls recoded against the frame.
Ricardo SIGNES <firstname.lastname@example.org>
This software is copyright (c) 2013 by Ricardo SIGNES.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
Module Install Instructions
To install Games::Bowling::Scorecard, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell install Games::Bowling::Scorecard
For more information on module installation, please visit the detailed CPAN module installation guide.
|s||Focus search bar|
|?||Bring up this help dialog|
|g p||Go to pull requests|
|g i||go to github issues (only if github is preferred repository)|
|g a||Go to author|
|g c||Go to changes|
|g i||Go to issues|
|g d||Go to dist|
|g r||Go to repository/SCM|
|g s||Go to source|
|g b||Go to file browse|