NAME

wordguess - Word guess game

VERSION

This document describes version 0.02 of wordguess (from Perl distribution Games-WordGuess), released on 2014-08-07.

SYNOPSIS

Run game:

% wordguess ; # defaults: word length 5, 5 guesses/word, 10 words, wordlist SGB

Customize some options (wordlist is Games::Word::Wordlist::* module):

% wordguess --min-len 5 --max-len 6 --num-words 5 --word-list KBBI

Other options:

% arrange-number --help
% arrange-number --version

An example game session:

Word 1:
o  _  _  _  _  Your guess (1/5)? ovale
o  _  _  _  _  Sorry, not a word! Your guess (1/5)? odors
o  _  _  r  _  Your guess (2/5)? overt
o  _  e  r  _  Your guess (3/5)? owers
o  _  e  r  _  Sorry, not a word! Your guess (3/5)? o
o  _  e  r  _  Sorry, not a word! Your guess (3/5)? our
o  _  e  r  _  Sorry, not a 5-letter word! Your guess (3/5)?
o  _  e  r  _  Sorry, not a word! Your guess (3/5)? otero
o  _  e  r  _  Sorry, not a word! Your guess (3/5)? overt
o  _  e  r  _  Your guess (4/5)? overt
o  _  e  r  _  Your last guess? overt
o  _  e  r  _  Chances used up. The correct word is: opera

Word 2:
g  _  _  _  _  Your guess (1/5)? grand
g  r  _  _  _  Your guess (2/5)? greet
g  r  _  _  _  Your guess (3/5)? groom
g  r  _  _  _  Your guess (4/5)? grips
g  r  _  _  s  Your last guess? grubs
Correct!

Word 4:
d  _  _  _  _  Your guess (1/5)? drives
d  _  _  _  _  Sorry, not a 5-letter word! Your guess (1/5)? drive
d  _  _  _  e* Your guess (2/5)? deers
d  _  _  _  _  Sorry, not a word! Your guess (2/5)? dears
d  _  _  _  _  Sorry, not a word! Your guess (2/5)? delve
d  e* _  _  _  Your guess (3/5)? dream
d  _  e* _  _  Your guess (4/5)? dared
d  _  _  e  _  Your last guess? dunes
d  _  _  e  s  Chances used up. The correct word is: dotes

DESCRIPTION

wordguess is a word-guessing game, a variation on "Hangman". Like in Hangman, you must guess a word in a certain number of allowed guesses. Unlike in Hangman, you guess word-by-word, not letter-by-letter. The first letter is always revealed beforehand so you can have a better idea of the word. Also, unlike in Hangman, if there is a letter in the your guess word that exists in the answer word but at the wrong position, the game will not tell you the correct position but instead will display the letter in the guessed position with an accompanied * mark. This way, you know that the letter exists but at a different position.

Scoring. For each correctly guessed word, you get a score. The score depends on word length and number of guesses. For example, if you guess a 5-letter word correctly on the first guess, you get 100. On the second guess, 80. And so on.

OPTIONS

--min-len=i, -a (default: 5)

Minimum word length.

--max-len=i, -b (default: 5)

Maximum word length.

--max-guesses=i, -g

Maximum number of guesses per word. The default is the word length (so if you have a 6-character word, the default is 6).

--word-list=s, -l

Select wordlist. Wordlists are searched in Games::Word::Wordlist::* modules. Two default wordlist are used: KBBI (if running under Indonesian locale), or SGB.

Only words containing the lowercase latin letter a-z are used.

--num-words=i, -w (default: 10)

Number of words per game.

TODO

  • Write statistics file

  • Colors

HISTORY

First created as a Perl script on 2010-04-04. First packaged as a CPAN module on 2014-08-07.

HOMEPAGE

Please visit the project's homepage at https://metacpan.org/release/Games-WordGuess.

SOURCE

Source repository is at https://github.com/sharyanto/perl-Games-WordGuess.

BUGS

Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=Games-WordGuess

When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.

AUTHOR

Steven Haryanto <stevenharyanto@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2014 by Steven Haryanto.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.