This seems like it should work, but whenever I try it, the characters get printed out individually up to the end of the first word (I'm using the string "Hello, world." as a test, and it just prints "Hello"., and then it stops. Why does this happen? How can I fix it? Thanks.
EDIT: I tried sizeof(sSay)+10 in the 3rd line and it prints out everything just fine. I think something is messed up with the apparent size of the array. Any suggestions?
indeed. sizeof(sSay) = 4, because sSay is a char* (thats how passing arrays works in c++). you need to use c < strlen(sSay) or sSay[c] != 0 (if sSay is a cstring. otherwise you'll have to pass the length of the string into tprint)