Strings not updating!?

Hey, all,

I’m just putting the dialogue text into my latest game and have come up against another issue…! :rage:

I have a UIController script that I’ve written myself, which includes an array of all the strings used in the game, like this:

     public string[] CharacterChat = { "Hello",
                                                    "The Next Line etc...",
                                                    ... };

which is then accessed from other files, like so:

     ~~~~pseudo code~~~~~

      UIController UICont;

      UICont.CharacterChat[CurrentString];

That all works fine - the problem is that the strings seem to be cached somewhere when I press PLAY on the editor, as I’ve updated the CONTENT of the first string (shown here as “Hello”), but it doesn’t update it in the game. The same “Hello” is still being displayed…

So effectively I need to be able to “Clean” the editor’s cache - any ideas how I can do this? Is it a bug?

Cheers,

SB

If thats all thats setting the string array it should work fine.
Potentially you reset its state somewhere else?

Public variables always take their values from the editor, not your code.

–Eric

Cheers, Eric - I’ll give that a try…