Gardenlog: Moves

What I'd like to do this week: Get the logic for moves/turns sorted. I might update this post at the end of the week for 'how it went'.

So now that some really basic row/column movement code is in, and with the items wrapping around as they move off the end of the grid, it's time to look at the turn structure. The plan is:

  • You'll be given a target state or pattern to achieve in your garden, and your initial garden state.
  • There may be a target number of moves also: if there was, I'm thinking smallish numbers like 3 or 4. My gut says the complexity burden for humans thinking out to 7 or 8 moves is going to be way too high.
  •  When you start moving a row or a column, you can shift it as many times as you want forward or backward until you get it just right: then you lock it in. That would count as one move.
  • Your other option is to cancel - this would reset that row/column back to its state before the move started. This would not count as a move.
  •  When a move is confirmed, it then takes effect - that is, rules which change the garden based on your move resolve at that time. So you don't see the effects of your move before until you lock it in. This one isn't set in stone - maybe it will work better to be able to see a preview. Let's see how we go.

Leave a comment

Log in with to leave a comment.