adding a dictionary behind the game

I am making a game in which randomly balls create of different colors… i have to add alphabets from a to z on the ball… i also have to add a dictionary behind the game so when ever during the game a word is formed it compare it from words in dictionary and remove them… now i have three questions:

  1. if i use textures for writing the alphabets can they be compare with the dictionary
  2. how a dictionary can be added behind the game
  3. and if textures alphabets an not be compared then what should i do

Of course they can be compared, because somewhere you’ll need to define which letter is on the ball. When you do that, keep hold of the letter itself (not the texture) and compare that. Quite often, what the user sees (the rendering, textures and such) and what the game engine sees (data in the code that it can manipulate and read) are different in games. As for “adding a dictionary behind the game” (which by the way doesn’t really make sense - you’re not adding it “behind” anything, you just need to search a dictionary), you’ll need to actually get a dictionary from somewhere. There is a C# class called Dictionary, but don’t be confused, it’s not an English dictionary, it’s just a data structure allowing you to store data as “keys” (like the words in a dictionary) and “values” (like the definitions). What your best chance is, I think, is to find an implementation of an English dictionary from the internet. Once you have all the dictionary entries, your issue will be searching it fast enough to be of use. I think a state machine search with Regular Expressions would probably be a good choice, but finding the implementation of the dictionary is where you need to start, though again, keep in mind that you want and English Dictionary, not the data structure Dictionary.