Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Re: Re: Perl Chess Server

by jotti (Scribe)
on Apr 23, 2002 at 12:06 UTC ( [id://161261] : note . print w/replies, xml ) Need Help??

in reply to Re: Perl Chess Server
in thread Perl Chess Server

Go to I'm quite new at Perl but I'm working nevertheless on a Chess server. So far I have only some C++ code, but I decided to go Perl, because our sysadm doesn't like (for some reason) my server crashing C++ CGI apps.

I've downloaded the file from the site above, but as a newbie to perl I prefere to invent the wheel myself. I have an idea of how to refresh a window or a frame only when needed, like a chess board or a chat window.

Johan Halmén

Replies are listed 'Best First'.
Re: Re: Re: Perl Chess Server
by strat (Canon) on Apr 23, 2002 at 12:31 UTC
      Yes, that was exactly what I was looking for. A very good Perl script for running a chess board on one's server. It has a good routine that checks for legal moves. But it is not very user friendly, you have to type the coordinates of the move.

      But I have some Javascript code that reads user clicks in the chess board and outputs the very same coordinates (e.g. e2 and e4).
        On my scratchboard, I've put some code that allows you to enter moves and checks if they are legal (only promotion and castling over threatened fields are not yet implemented). If I've got more time, maybe there will be a cpan-module for it soon.
        If I remove it from my scratchpad, I'll either put it to CPAN or at least to my homepage, and update this message by putting a link here.

        Best regards,
        perl -le "s==*F=e=>y~\*martinF~stronat~=>s~[^\w]~~g=>chop,print"