Jump to content
  • Advertisement
Sign in to follow this  
patishi

Chess program language & design dilemma

This topic is 1845 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi all.   as i am thinking of start programming chess engine of my own, and ofcourse it would be very comfortable and friendly to program it in OOP style (JAVA),  and the second posibility it to do it in C  which i just started to learn, but i already have a nice grasp of the basics of the language.     

Now..I know that c is "supposed" to be a little faster than java (some disagree with that) but let's leave that issue aside for the discusion,  what i am really trying to figure out is leaning more toward the design of the program.     should i do it in a primitive way or in object oriented fashion?   (In java i can also make NOT object oriented program,but in that case i might as well use C)
 

I am probably going to use bitBoards for the board representation, but i can do in one single file ,and I  can do it in seperate classes (one for each chess piece)  and wrap each bitBoard with an object.            Another example, i can make a single "generateMoves" function , and i can make seperte generateMoves functions inside each object (e.g every chesspiece will be responsible to generate its own moves)   etc'.    
Of course i will try not to use a lot of dynamic structures like lists and such,and use primitives the most,  but still...I am afraid that using objects like this can slow the program.  

(how it is best to represent pieces in chess?) 

 

I would like to hear your opinion about this, and get some insights.  Thx in advance for any info on the subject

Edited by patishi

Share this post


Link to post
Share on other sites
Advertisement

thanx!  I know this one it is great, but i wish that sometimes they would be a little more specific on certain subjects.  but it's a great information never the less 

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!