Object Oriented Design Questions

Posted by Robert on Stack Overflow See other posts from Stack Overflow or by Robert
Published on 2010-05-10T23:27:44Z Indexed on 2010/05/10 23:44 UTC
Read the original article Hit count: 623

Hello there.

I am going to develop a Tic-Tac-Toe game using Java(or maybe other OO Languages).Now I have a picture in my mind about the general design.

Interface: Player ,then I will be able to implement a couple of Player classes,based on how I want the opponent to be,for example,random player,intelligent player.

Classes: Board class,with a two-dimensional array of integers,0 indicates open,1 indicates me,-1 indicates opponent.The evaluation function will be in here as well,to return the next best move based on the current board arrangement and whose turn it is.

Refree class,which will create instance of the Board and two player instances,then get the game begin.

This is a rough idea of my OO design,could anybody give me any critiques please,I find this is really beneficial,thank you very much.

© Stack Overflow or respective owner

Related posts about object-oriented-design

Related posts about completely-incomprehensib