I think I have found a bug that has been haunting me. It is related to the issue I reported here, about the Test Ludeme dialog. It seems the issue might have to do with the ludeme (sites Distance).
The .lud I have attached here works exactly as I would expect. It identifies the site that is the farthest away from the center (counted in steps onto empty cells) and lets you add to any empty cell one less than that number of steps away from the center. However, if I remove the "one less" part, things break down. If you remove the (- … 1) part in the define ("RelativePerimeter"), like this
then there are no legal moves.
The .lud I have attached here works exactly as I would expect. It identifies the site that is the farthest away from the center (counted in steps onto empty cells) and lets you add to any empty cell one less than that number of steps away from the center. However, if I remove the "one less" part, things break down. If you remove the (- … 1) part in the define ("RelativePerimeter"), like this
Code:
(define "RelativePerimeter"
(sites Distance
from:(centrePoint)
(exact
//(-
("BiggestDistanceFromCenterInRegion"
("ReachableByStepOntoEmpty" #1)
)
//1)
)
)
)