If it was a single word I would probably approach it by grabbing a position in the text using tokenat(text,var,"") where var is a random number between 0 and text.length. Then I would check that this value is not already a * and change it to *, else run the check again. With several words, I guess you expand this into first checking if value at position is equal to "" (a gap) and if so then run the check again. There might be a simpler way to run through it randomly but that would be my approach.
edit : just noticed your example wasn't randomly filling in but in order so you would add 1 to var every 5 seconds, and set at tokenat(text,var,"") to *. Then when you come across a gap you could set to * if that's relevant to the design of the game, or skip it.