- Home /
Getting a text to appear when you pick up an items in order?
Hi guys I am in need of some scripting help. In the game the player needs to pick up these newspaper clippings. I want that when he picks up the item a text appears with the newspaper headline. At first I was just going to add individual text script on each item, but I feel it will be better if the headlines appear in a certain order. Is there perhaps a script that can be written. (Perhaps an array) So it doesn't matter which newspaper piece he picks up first it will always show in order?
Answer by kaushik-d · Jan 26, 2015 at 06:15 AM
You can keep an array (like you said) of string type in a separate script (and attach that to a GameObject, of course). You reference this array with the count of papers picked up so far to get the text associated.
Your answer
Follow this Question
Related Questions
need particle help 1 Answer
Can someone explain 'Using ..." and "MonoBehaviour" in C# 7 Answers
Unity Scripting armv7 Error 1 Answer
Good or Bad ending 1 Answer
Script that switches between first and third person controller 3 Answers