I'm currently writing a scrabble-like game in C#. I can get the computer to find the highest point value word that can be made using the current rack, however I have no idea how to check if that word is "Placeable" on the 15*15 Gameboard(2D Array: string[,]).
In it's default state(with no Letters on the board) all elements are set to 0.
Is allowed
---------------
-------H-------
-------E-------
-----FILL------
-------L-------
-------O-------
---------------
How can I check if the word is not For example:
Is Not Allowed
---------------
-H-------------
-E-------------
FILL------------ <-- F is out of bounds
-L-------------
-O-------------
---------------
Is Not Allowed
---------------
-H-------------
-E-W-----------
-L-O-----------
-L-R-----------
FOLL----------- <-- Fill is overlapping with O
---D-----------
Tile Values 1 Point - A, E, I, L, N, O, R, S, T and U. 2 Points - D and G. 3 Points - B, C, M and P. 4 Points - F, H, V, W and Y.
The paper, "The worlds fastest Scrabble engine" (PDF), is from 1988 and describes an efficient Scrabble engine. It's short and surprisingly readable!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With