Ludii Forum
(is Connected <region> ) failing to compile - Printable Version

+- Ludii Forum (https://ludii.games/forums)
+-- Forum: Problems (https://ludii.games/forums/forumdisplay.php?fid=5)
+--- Forum: Grammar Problems (https://ludii.games/forums/forumdisplay.php?fid=24)
+--- Thread: (is Connected <region> ) failing to compile (/showthread.php?tid=144)



(is Connected <region> ) failing to compile - dale walton - 08-19-2020

I am trying to use (is Connected <region> ) in a way you may not have foreseen - the documentation states that the region must be disjoint.  However it would be useful if the value would be <true> in the case that the region is not disjointed.

Then

     (not (is Connected (difference (sites Board) (sites Mover)))

would tell me that the Mover had blocked the Next player from the possibility of group connection by dividing the board into separate regions, which is one of the winning conditions of Muster.
However, when I try this the game does not compile.

Can you add it as an allowed use of the Connection ludeme.


RE: (is Connected <region> ) failing to compile - Eric Piette - 09-06-2020

Hi,

To use (is Connected ...) with regions, you need to provide many regions (not only one), that's why your example does not compile.

Regards,
Eric Piette


RE: (is Connected <region> ) failing to compile - dale walton - 09-06-2020

Yes, that is in the documentation. But I cannot find a way around this - any suggestions?

I have requested you all to change this, as a logical extension to the language: i.e. a single fully connected region should return true, and a set of sites that are not fully connected should return false.

Or else to provide a separate ludeme for counting the number of disjoint regions within a set of sites.


RE: (is Connected <region> ) failing to compile - Eric Piette - 09-06-2020

We have the ludeme (is Blocked ...) which detects whether regions cannot possibly be connected by a player. I guess you can use it to do what you suggest here?

Can you send me a link with the rules of the game Muster?

Regards,
Eric Piette


RE: (is Connected <region> ) failing to compile - dale walton - 09-06-2020

Blocked has the same documentation: i.e. it also requires a disjoint set of sites to work. Is it exactly the same as (not (is Connected...? or does it mean something else?

Many regions.... Is there any technical difference between a region and a set of sites? Does many regions mean many NAMED or predefined regions, or simply a disjoint set of sites where the algorithm discovers the regions that need to be connected in order to make it a fully connected set?

https://boardgamegeek.com/thread/2433903/rules-make-muster-abstract-games-forum-and-ai-ai