1
\$\begingroup\$

Naively, I would assume that there's an even probability of any of the 26 given letters appearing in a tile and that each tile is generated independently. After playing around a hundred times, though, I have some doubt; the number of times I've seen three or four of the same letter, as well as uncommon letters like 'z' or 'w' feels too small, but I could absolutely be wrong.

Does anyone know how I can generate boards for this game? Should I generate each tile independently, or are there rules for how many of the same letters should appear?

example of a standard, 4x4 board

\$\endgroup\$
4
  • \$\begingroup\$ not everybody has played that game. Could you gives us some examples of boards you try to create? If it is similar to scrabble, there is a distinct letter distribution: en.wikipedia.org/wiki/Scrabble_letter_distributions \$\endgroup\$
    – Zibelas
    Apr 13, 2022 at 21:39
  • \$\begingroup\$ @Zibelas sure, I've added an example board. Let me know if there's any other missing information. \$\endgroup\$
    – suburb1a
    Apr 13, 2022 at 21:45
  • 1
    \$\begingroup\$ We generally can't answer questions of the form "How did game X implement feature Y". Often, only the developer who worked on that feature knows, and they might never visit this site, or be barred by NDA from revealing those details even if they do. What we can generally answer better is "How can I implement feature Y "in my game*?" We won't be able to guarantee the answers exactly match the source game, but who knows, you might get even better suggestions than what the source game uses. \$\endgroup\$
    – DMGregory
    Apr 14, 2022 at 10:47
  • \$\begingroup\$ This game looks similar to the physical game Boggle, which uses dice to make its board. So one strategy you could try is to look at the letter frequencies on Boggle dice, and the constraints imposed by each die appearing only once. \$\endgroup\$
    – DMGregory
    Apr 14, 2022 at 10:50

1 Answer 1

3
\$\begingroup\$

If I had to create a board like that that has to have a certain amount of valid words, I would first create an algorith that can find words given a wordlist within that matrix. This has the following benefits:

  • You can see how hard a board is to solve. The more words your algorith finds, the easier the board gets.
  • If your game has a fixed level layout (means lvl XYZ should return always the same board), you can calculate the total points a level can give and reward accordingly stars for a level

Now that you can test a level, you can actually pick multiple ways how to generate a board. The laziest version would be to use a random letter for each field. Since you can test it, if you do not get enough words, simply recreate a new board.

A slightly better result would be to use a scrabble list for the language you target. They usually are a distribution of how often a letter is used. Now instead of randomly using a letter, you pick one by random from the list. Since some letters are more often in there, you will pick them up more often. (Might be better to pick and remove the letter from the list to not have the rare choosing of 4x Z and 3xY)

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .