zwol: ((mad) science)
[personal profile] zwol

because i'm sick and playing way too much match-3...

in a standard match-3 game where one move is swapping two adjacent tiles, each move must create at least one line of 3 or more tiles of the same color, all such lines are immediately removed and scored, and there are no special moves or tiles: what is the maximum number of tiles that can be removed in the first scoring round, i.e. before the empty space is filled? from this configuration you can get 14 tiles...

........
...AB...
...AB...
.AABABB.
...AB...
...AB...
........

(swap bold tiles) and i don't think you can do better, but maybe i'm missing something.

The number of tiles that can be removed on the second and subsequent scoring rounds is bounded only by the height of the board, because of this pattern:

.|||..
.BAA..
.ABB..
.BAA..
.ABB..
.B   .
......

(vertical bars indicate repetition) but it's still interesting to ask what is the largest kingwise connected pattern around the pattern removed in the first round that can be removed in the second round. you might think it's this pattern:

..........
...AABB...
...AABB...
.AA    BB.
...AABB...
...AABB...
..........

with 18 tiles to be removed, but there is no way to create this pattern by exchanging two tiles, from a legal game position.

Date: 2011-06-07 02:25 am (UTC)
brooksmoses: (Default)
From: [personal profile] brooksmoses
There's a minor variation on on your second pattern that's reachable, though, starting from the first pattern. How about:
..............
....AA  BB....
....AA  BB....
..AA      BB..
....AA  BB....
....AA  BB....
..............


We got there from here (lower-case removed in the first round) by swapping the central pair:
..............
....AAbaBB....
....AAbaBB....
..AAbbabaaBB..
....AAbaBB....
....AAbaBB....
..............


And you can take out 8 more in the second round by putting matched pairs beyond the ends of the central column as well -- though I'm not sure I'm understanding exactly what you mean by "kingwise-connected":

..............
......AB......
......AB......
....AA  BB....
....AA  BB....
..AA      BB..
....AA  BB....
....AA  BB....
......AB......
......AB......
..............

Date: 2011-06-07 03:14 am (UTC)
From: [identity profile] zwol.livejournal.com
That's clever, I like that.

"Kingwise connected" is what I thought was the standard term for a pattern of square tiles connected by chess-king moves (i.e. one square orthogonally or diagonally - no hops). Thus your third pattern fits my constraints fine.

Date: 2011-06-07 03:16 am (UTC)
From: [identity profile] zwol.livejournal.com
... it occurs to me that my alternating-ABB-BAA-rows pattern fits that too. Maybe I need to add "bounded" or something like that.

Date: 2011-06-07 04:03 am (UTC)
brooksmoses: (Default)
From: [personal profile] brooksmoses
Right, that's what was confusing me. And you couldn't have meant "singly kingwise-connected" (in the sense of everything that gets removed is one king-move away from the original pattern), because a lot of these are two squares away.

One plausible revision is that every 3-row that's removed in the second round must contain a square that's one king-move from the squares removed in the first round.

Even then, though, since kings move diagonally, my suggestion earlier is incomplete. Consider this small revision:
..............
......BA......
..............
..............
......AB......
....BBABAA....
...BBA  BAA...
..BBAA  BBAA..
..AA      BB..
....AA  BB....
....AA  BB....
......AB......
......AB......
..............


The intriguing bit there is that, although the pattern after collapse is king-wise connected (and fits the "every 3-row contains a square..." rule), it's not king-wise connected before the collapse. Although the top island is not actually necessary for any of the other squares; it turns 3-rows into 4-rows.

So, counting the top island, 40 squares.

April 2017

S M T W T F S
      1
2345678
9101112131415
16171819 202122
23242526272829
30      

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated Oct. 24th, 2017 09:41 am
Powered by Dreamwidth Studios