Boardician (board game framework)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

Boardician (board game framework)

laura
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura
Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

Olivier Auverlot
very cool !

2015-03-24 15:41 GMT+01:00 Laura Risani <[hidden email]>:
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura

Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

kilon.alios
In reply to this post by laura
Well done Laura. I really enjoyed your games and I definitely welcome your documentation.  I will give it a try , thank you .

On Tue, Mar 24, 2015 at 4:41 PM, Laura Risani <[hidden email]> wrote:
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura

Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

stepharo
In reply to this post by laura
We should help laura and do a code review.

Laura I do not know if you change it in the latext version but I would not subclass from Matrix but use composition instead.


Le 24/3/15 15:41, Laura Risani a écrit :
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura

Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

stepharo
In reply to this post by laura
Hi laura

I would do a massive rename :)

EDirector new play.
does not tell me anything

BPDirector new play.
DPDirector new play.
GDirector new play.

neither :)

Stef

Le 24/3/15 15:41, Laura Risani a écrit :
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura

Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

Ben Coman
One pattern is that the main application class be fully named, leaving the mnemonic prefix for the support classes.
cheers -ben 

On Wed, Mar 25, 2015 at 4:14 PM, stepharo <[hidden email]> wrote:
Hi laura

I would do a massive rename :)

EDirector new play.
does not tell me anything

BPDirector new play.
DPDirector new play.
GDirector new play.

neither :)

Stef

Le 24/3/15 15:41, Laura Risani a écrit :
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura


Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

laura
@olivier
I guess that playing to test them should be considered to work.

@kilon
Mail me back if you do develop a game adding from you graphical capabilities.

@stepharo , Ben 
Code review would be nice!

I've tried to chose the most meaningful names, yet i didn't discuss this with anyone, what would be adequate since communication is interpersonal. If you show me, telling why, you think another name would communicate better instead a current one i'll change it. Also i'd like more people to have an opinion on this.

I agree that games' director names are meaningless, seems that something like '(BG)DirectorOfGameName' would communicate better and be more practical since when you type 'BGDirector' code completition will show all the existing game director subclasses, that is all the games.

@stepharo
I subclass from Matrix BGBoardSpace and DPPieceLayout. These  are respectively matrix arrangements of places (BGBoardPlace) and squares (DPSquare) that (potentially) need to understand all Matrix interface in addition to extending it (for example class side methods for instantiating particular space cases like level spaces, instance side methods for telling space properties). I think it's like having to model matrix of numbers that would need to support all math matrix operations, why not to subclass? why to rewrite all matrix interface?
Composition takes place at the level of BGBoard and DPPiece (which are respectively composed by aBGBoardSpace and aDPPieceLayout), so substitution could occur there if you need a non matrix space (is that to be expected?).
Why do you think composing BGBoardSpace and DPPieceLayout would be better?




On Wed, Mar 25, 2015 at 9:01 AM, Ben Coman <[hidden email]> wrote:
One pattern is that the main application class be fully named, leaving the mnemonic prefix for the support classes.
cheers -ben 

On Wed, Mar 25, 2015 at 4:14 PM, stepharo <[hidden email]> wrote:
Hi laura

I would do a massive rename :)

EDirector new play.
does not tell me anything

BPDirector new play.
DPDirector new play.
GDirector new play.

neither :)

Stef

Le 24/3/15 15:41, Laura Risani a écrit :
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura



Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

stepharo


Le 25/3/15 16:32, Laura Risani a écrit :
@olivier
I guess that playing to test them should be considered to work.

@kilon
Mail me back if you do develop a game adding from you graphical capabilities.

@stepharo , Ben 
Code review would be nice!

I've tried to chose the most meaningful names, yet i didn't discuss this with anyone, what would be adequate since communication is interpersonal. If you show me, telling why, you think another name would communicate better instead a current one i'll change it. Also i'd like more people to have an opinion on this.

I agree that games' director names are meaningless, seems that something like '(BG)DirectorOfGameName' would communicate better and be more practical since when you type 'BGDirector' code completition will show all the existing game director subclasses, that is all the games.

@stepharo
I subclass from Matrix BGBoardSpace and DPPieceLayout. These  are respectively matrix arrangements of places (BGBoardPlace) and squares (DPSquare) that (potentially) need to understand all Matrix interface in addition to extending it (for example class side methods for instantiating particular space cases like level spaces, instance side methods for telling space properties). I think it's like having to model matrix of numbers that would need to support all math matrix operations, why not to subclass? why to rewrite all matrix interface?
Favor subtyping over subclassing.
A subclass Matrix should be a specific Matrix with matrix behavior.

Subclassing is not a really good practice. It is code reuse but this is short term.
Imagine that tomorrow we put some eigenvalues in Matrix will this eigenValue make sense for your board. I do not think so.

Following the same we removed in Pharo
Dictionary as subclass of Set.
Now dictionary is a subclass of HashedCollection.

We did not because it did not work but because it sucked and let to all kind of understanding problems.

Composition takes place at the level of BGBoard and DPPiece (which are respectively composed by aBGBoardSpace and aDPPieceLayout), so substitution could occur there if you need a non matrix space (is that to be expected?).
Why do you think composing BGBoardSpace and DPPieceLayout would be better?




On Wed, Mar 25, 2015 at 9:01 AM, Ben Coman <[hidden email]> wrote:
One pattern is that the main application class be fully named, leaving the mnemonic prefix for the support classes.
cheers -ben 

On Wed, Mar 25, 2015 at 4:14 PM, stepharo <[hidden email]> wrote:
Hi laura

I would do a massive rename :)

EDirector new play.
does not tell me anything

BPDirector new play.
DPDirector new play.
GDirector new play.

neither :)

Stef

Le 24/3/15 15:41, Laura Risani a écrit :
Hi all,

A time ago i posted two board games on the list and Stéphane said that he would like to extract from these and other ones he has gathered a framework for doing board games. So i developed a little one called 'Boardician' and implemented four little example games through it.

DOCUMENTATION

DOWNLOAD
You can install configuration BgBoardician from Configuration Browser on 3.0 and 4.0 . This will download packages of framework (BgBoardician) and example games (BgBoxPush, BgEatBullet, BgDropPiece, BgEatElongating)

To run example games send

EDirector new play.
BPDirector new play.
DPDirector new play.
GDirector new play.


FEEDBACK
If you like (i would really like you to) to send any feedback comments on design / names / implementation / functionalities to add / questions you can post a comment on the blog / mail me. 

Next i'll be adding tests and uploading development history to project's repo. 

Best,
Laura




Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

stepharo
In reply to this post by stepharo
Hi laura

I took some moments to look at the code with Olivier.
We think that the name of the project is strange and could be sexier :)

First thumb up.
You developed this really fast and this is a good foundation.

Olivier mentions http://tululoo.com  in JavaScript
     the framework uses event and decomposes the game.
Did you look at the code of the framework developed by damien cassou in
Java?

I will read all the code this week-end so just some first impressions now.

- The classes should be commented
- No as yet unclassified please.
- Did you run the code critics?

The game name should be meaningful
     - BGDirector subclass: #GDirector => BGDirector subclass: #SnakeGame


- for the snake the initial position of the first apple should not be
one the border.

- Do you have the notion of command? Because you can easily implement an
undo/redo
based on the undo/redo framework of Pharo.
    Once you have that you can also build demo.

Missing features:
     - Score, best score
     - Pause
     - Restart
     (next and other)
     - game description and help



Stef


Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

laura
I took some moments to look at the code with Olivier.

Excellent! All feedback is really valuable! 
(dear silent readers i care about your opinion, i assure you i'm not selling it)

We think that the name of the project is strange and could be sexier :)

Previously you suggested 'MetaBoard', 'MetaBorg'. Anyone else any other name idea that balances declarativeness and sexiness? Should we care only for the latter? Declarativeness will kill sexiness?
 
First thumb up.
You developed this really fast and this is a good foundation.

Olivier mentions http://tululoo.com  in JavaScript
    the framework uses event and decomposes the game.
Did you look at the code of the framework developed by damien cassou in Java?

I don't understand the second framework, it's entitled 'Teaching game framework', are there any class notes i can look at?
The first framework has really cool graphics and seems to be quite powerful in it's expressiveness and to have a smooth GUI. I'll try to navigate a little through the code, if possible, to try to get some understanding about it's design, since i don't see any documentation on it on the web, perhaps inside the downloads.

Do you consider first framework's example games to be board games? Mmmm, one could think there is a bigger board that is successively partially displayed when the character moves.
You also asked 'Did you have game where characters are moving not block by block?'.
When developing Boardician i thought, based on game list examples, the characteristic quality of a board game to be having a tiled board. I should explicitly state this constraint at the documentation. Display could show moving as a transition, but i case of adjacent places it doesn't seem to add much, does it?

- Do you have the notion of command? Because you can easily implement an undo/redo
based on the undo/redo framework of Pharo.
   Once you have that you can also build demo.

BgBoxPush (#BPDirector) has implemented undo, it is on it's particular menu. While undoing isn't universally needed it seems useful to have it at framework level to deal with cases that do need it.
 
Missing features:
    - Score, best score
    - Pause
    - Restart
    (next and other)
    - game description and help


Pause and restart are already implemented at framework level, any BGPlayer can be paused/restarted, in particular BGDirector through menu (see menu entries). Score list and description menu entries should be added.


Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

kilon.alios
"
@kilon
Mail me back if you do develop a game adding from you graphical capabilities.
"

hmm making a board game sound like a very nice idea indeed. Will keep you posted, definitely I am making something :)
Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

kilon.alios
I am taking a look at your code and I dont understand something you have in BgEatBullet package EMonster1Mover, EMonster2Mover , EMonster3Mover and EMonster4Mover.  All four classes are identical apart from the return values in some methods. Why not use 1 class and 4 instances of that class instead ?

Also I second the name of the classes is confusing.
Reply | Threaded
Open this post in threaded view
|

Re: Boardician (board game framework)

laura
Excellent!

I have a todo list i'll work on including further class commenting, method classification on example games, ... I wanted to share what i have to get feedback. Feel free to add to the list!

About the issue on EMonsterMover i thought back and forth about having only one configurable (dynamic choices) / the four (static choices). At the moment i went with the last one because i thought that despite not nice, it eased the reading being more explicit also i wasn't completely sure of being able to remove it. Now that it's finished it can be seen that is unnecessary not beautiful. Thank you for pointing it out, i'll change it.

What names do you find confusing, which ones would you use instead? Have you read the first paragraphs of the documentation (mainly class comments)? 



On Thu, Mar 26, 2015 at 3:22 PM, kilon alios <[hidden email]> wrote:
I am taking a look at your code and I dont understand something you have in BgEatBullet package EMonster1Mover, EMonster2Mover , EMonster3Mover and EMonster4Mover.  All four classes are identical apart from the return values in some methods. Why not use 1 class and 4 instances of that class instead ?

Also I second the name of the classes is confusing.