08-19-2020, 09:11 AM

First of all, I would like to say thank you for Ludii! I'm over the moon about this project!

I do find it quite difficult to get my head around this grammar, though. I don't have much experience learning these kinds of technical languages, but I don't doubt for a second that it will be worth it. My most fundamental difficulties are quite general, and I haven't even been able to put them into words, so I will try to be quite concrete.

I have managed to make a trivial basis for a game where one is adding stones to empty cells and gaining a point per stone. The next step is to restrict which empty cells one may add a stone to, but the restriction is quite complicated and I don't know how to implement any part of it. The restriction is this:

You may add a stone at a cell that is part of an isolated connected set of empty cells whose size is greater than the number of friendly stones in the cell’s line of sight.

By "connected set of empty cells" I mean that any pair of cells in the set is connected through a chain of orthogonal adjacencies (and counting a set of a single empty cell as connected) – so it's a "chain" of empty cells, in Go terms. By calling such a set "isolated" I mean to exclude from consideration any cell that is orthogonally adjacent to a stone. To try to put it in constructive terms: First, take all empty cells. Then ignore all cells adjacent to a stone. Then you may add a stone to one of the remaining cells, given that it is part of a connected set of cells that meet a certain size-condition.

Could someone point me in the right direction here? I simply don't understand how to think about these things in Ludii terms.

I do find it quite difficult to get my head around this grammar, though. I don't have much experience learning these kinds of technical languages, but I don't doubt for a second that it will be worth it. My most fundamental difficulties are quite general, and I haven't even been able to put them into words, so I will try to be quite concrete.

I have managed to make a trivial basis for a game where one is adding stones to empty cells and gaining a point per stone. The next step is to restrict which empty cells one may add a stone to, but the restriction is quite complicated and I don't know how to implement any part of it. The restriction is this:

You may add a stone at a cell that is part of an isolated connected set of empty cells whose size is greater than the number of friendly stones in the cell’s line of sight.

By "connected set of empty cells" I mean that any pair of cells in the set is connected through a chain of orthogonal adjacencies (and counting a set of a single empty cell as connected) – so it's a "chain" of empty cells, in Go terms. By calling such a set "isolated" I mean to exclude from consideration any cell that is orthogonally adjacent to a stone. To try to put it in constructive terms: First, take all empty cells. Then ignore all cells adjacent to a stone. Then you may add a stone to one of the remaining cells, given that it is part of a connected set of cells that meet a certain size-condition.

Could someone point me in the right direction here? I simply don't understand how to think about these things in Ludii terms.