Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Perl for hobbyists

by ELISHEVA (Prior)
on Oct 08, 2009 at 12:31 UTC ( [id://799945]=perlmeditation: print w/replies, xml ) Need Help??

On Monday Lady_Aleena posted her first ever module for D&D fans. Today in the CB, herveus told us about his module Weaving::Tablet which generates patterns for a weaving machine. I thought that was pretty cool, so I tried look up other hobbyist related modules on CPAN. I didn't have much luck with crossstitch, needlepoint, knitting or even pattern. The last however just had too many hits to go through. purl pulled up a few hits, but they weren't exactly games.

I had a bit more luck with baseball, football (N.B. that was by a soccer fan, not an American football fan), soccer, tennis and basketball. I even found hits for blackjack.

music also turned up a lot of interesting modules (+300!). In addition to reams of modules for various music file formats, there were modules to retrieve Yahoo music ratings, compose music using gestalts, fetch lyrics, and track distribution history.

Under games I found several modules for fans of cards, chess, checkers, bingo, various adventure games, SuperMario(TM), and of course, modules that implement the traditional on-line games from my computer "childhood" - worms, hunt the wumpus, and rogue.

I have a feeling there are lots more out there.

So what hobbiest modules do you know about? What is your favorite? Have you written one? Did you publish it? Why or why not?

Best, beth

Replies are listed 'Best First'.
Re: Perl for hobbyists
by moritz (Cardinal) on Oct 08, 2009 at 12:39 UTC

    This example of quilting has become quite famous in the perl community.

    There's also frozen bubbles, which is currently on its way to CPAN.

    Most of my hobby-related scripts are just a few lines, and nothing worth storing or even publishing, mostly when I needed to calculate a few angles or lengths or so.

    Perl 6 - links to (nearly) everything that is Perl 6.
Re: Perl for hobbyists
by bruno (Friar) on Oct 08, 2009 at 13:12 UTC
    I've ran into Kite, and impressively complete framework for the design and construction of kites, by the author of Template Toolkit.

    Also, by Paul Fenkwick, there's a module to assist in calculation of no-decompression diving times, SCUBA::Table::NoDeco.

    Weewar is a Perl interface to the online turn-based strategy game Weewar.

    I'm pretty sure there are many more!

Re: Perl for hobbyists
by Tux (Canon) on Oct 08, 2009 at 14:01 UTC

    What if my hobby is perl itself? Do all modules count?

    I've never looked for modules for my sports: Badminton and Skiing, but I see no direct relation with perl.

    Once I did horsebackriding, I used perl/Tk to work out the patterns our group had to ride and gave every rider a colored printout.


    Enjoy, Have FUN! H.Merijn

      I play badminton and have a Perl/Tk application that we use to generate random doubles teams for club nights. The application tracks the people present, the number of times each has played and the games that have been drawn already. A draw is generated for each 15 minute round. After a draw is generated players can be moved between games or swapped with an undrawn player to even teams up or provide teacher/student pairings etc.

      The drawing process doesn't take player rankings into account or any other player attributes. It simply tries to give everyone about the same amount of court time. To that end it works very well and the club is well pleased with it despite a few rough edges.


      True laziness is hard work
Re: Perl for hobbyists
by redgreen (Priest) on Oct 10, 2009 at 03:45 UTC

    Mazes. Mazes for my wife and I. Instead of trying to port some of my old MS-DOS C code to linux, I found Games::Maze.

    I was excited, until I found how simple and predictable the mazes were. It seems that once it is boxed in, it backtracks the way it came. Making a simple change fixes that:

    # Right here is where things get predictable! Mix it up. # ($c, $r, $l) = splice @queue, 0, 3; ($c, $r, $l) = splice @queue, (rand(@queue / 3) *3), 3;

    Yes, my code uses more memory, but the mazes are more challenging. I guess 'more memory' is all relative, I remember how many hoops I had to jump through to use more then 64k of data in MS-DOS.

    I have code that takes the Games::Maze square data and creates a png file.

    Now if I could only find a good way to represent the maze, and have the output span a few dozen pages.

        Wow, nice article. I didn't care about the speed problem because when I wrote my program, computers were fast enough. I only wrote the fast algorithm eight years later in the perl rewrite. Otoh, I think my program generates better (more interesting) mazes.

Re: Perl for hobbyists
by goibhniu (Hermit) on Oct 09, 2009 at 18:45 UTC

    Not a module, but Perl uses for Cryptograms - Part 1: One-liners and Word Patterns was certainly for my Cryptogram hobby. That's been neglected for some time, but if I ever get back into it, I certainly will be using Perl.


    #my sig used to say 'I humbly seek wisdom. '. Now it says:
    use strict;
    use warnings;
    I humbly seek wisdom.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlmeditation [id://799945]
Approved by moritz
Front-paged by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (8)
As of 2024-03-28 18:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found