Hey guys. I'm making an RPG map, and there are several NPCs in the game. When a player uses the "Interact" ability on an NPC, I would like some sort of text to display. Similar to this... "Villager: Oh hello there!". But I want it to be random. There will be 5 or 6 different lines, so it will be random each time the NPC is selected.
I succeeded in this. But sometimes there is no text displayed at all. Let's say I interact with the NPC 10 times. About 2 of those times he won't say anything. Are there any memory leaks with displaying text messages? This is quite annoying. I can't seem to fix it. Any ideas?
I succeeded in this. But sometimes there is no text displayed at all. Let's say I interact with the NPC 10 times. About 2 of those times he won't say anything. Are there any memory leaks with displaying text messages? This is quite annoying. I can't seem to fix it. Any ideas?