I was looking around the spritefont plugin topic and learned how to single out a word in a string and change its color. I used the method Lucid suggested and ended up with this:
-Write Text: "You found (" & TreasureBox_Item.value('WhichItem') & ")!"
+For Each Word In Phrase
+SpriteFont.currentword = TreasureBox_Item.value('WhichItem')
-Set Text color filter to Red
("Text" is the sprite object I'm using for my font)
So if the value "WhichItem" is "HeartPiece", then the string should read:
"You found (HeartPiece)!"
and "HeartPiece" should be colored red.
WELL, it doesn't work <img src="smileys/smiley5.gif" border="0" align="middle" /> The only word I can get to change colors is the very first word in the string: "You"
I tried comparing the current word to "HeartPiece" itself, I tried converting the "WhichItem" value to a string, I tried putting each word in its own set of quote marks, but nothing works!
Has anyone tried doing this before and/or have any idea what I'm doing wrong?