Git Product home page Git Product logo

ascii-chess's Introduction

This is a chess program completely written in C Programming Language (C99 standard).It is without GUI, so it can be played on linux terminal.The chess grid is made using Unicode and accepts input in the form :-

             Type in your move{prompt}: 1 b1 c1
The above command moves pawn(1) from it's initial position 'b1' to final position 'c1'.

            The Artificial Intelligence code is written in the file under the name AI.c, which is capable of noticing check conditions and avoiding them too. Game Tree concept has been implemented which gives a lot of room for development as in here the evaluation is being done only for a single future instance i.e. it predicts the human output for the next immediate move only and then from there ,it evaluates the best possible move for itself(computer).So there is enough space to increase the accuracy of the game by evaluating the outcomes for more future instances 
            
            This code is capable of noticing and rejecting "illegal" moves typed-in by a human player, so it goes without saying that with little editing the game can work for human v/s human matches.
            A lot many things are not implemented in this program for example, the code is strictly an "intelligent" code as there is no previous memory or experience, many  algorithms have not been implemented and people may want to write code for GUI interface since it has none.

INTENDED AUDIENCE
  Any person having basic knowledge of C Programming Language and willing to spend a few hours reading and understanding the code.

COMPILATION
Type-in the following command in the directory containing the files chess3.c and AI.h:-
       gcc -std="c99" chess3.c AI.h -o chess
 which will create an executable file under the name chess, open this file and the game will be up and running.
 
FOR WINDOWS USERS
You may download many of the gcc ide's or softwares available for free on the net.Some of the Ide's are given here:

1)Eclipse CDT (you can download bundle from http://eclipse.org)

2)Cygwin (http://www.cygwin.com/)
  gives a linux like environment on windows

3)Code::Blocks IDE (http://www.codeblocks.org/)
  
4)CodeLite opensource cross platform IDE(http://codelite.org/) 
  It works great on almost all Operating Systems: Windows XP/7 and 8, Debian / Ubuntu, Fedora / OpenSUSE, Mac OSX 10.5.8

If you wish to proceed in the direction of software development, using a good shell won't hurt!

Have Fun!!

CREDITS
Sharat Shankar
email Id:[email protected]

Parigyan Chandra Goyal
email Id:[email protected]

ascii-chess's People

Contributors

parigyan avatar sharat20 avatar asheeshr avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.