- Home /
How to edit 3D Text at runtime?
I need to have the player be able to type in whatever they want into their "journal" using 3D text. Is anybody able to point me in the right direction?
This concept is sort of like minecraft's books like this:
Heres A Good Asset They $$anonymous$$ay Help You - https://www.assetstore.unity3d.com/#/content/1874
Answer by 3lem3n7 · Nov 04, 2013 at 09:38 PM
One way to do this is to use Text Mesh component. Simply add it to your game object.
Then you can get a reference to the newly added text mesh via script like this (I'm using c# in this case):
TextMesh myText;
// Use this for initialization
void Start () {
myText = GetComponent<TextMesh>();
}
You can set text to be displayed via myText.text property.
And lastly, to get the keyboard input, I would suggest using Input.inputString (http://docs.unity3d.com/Documentation/ScriptReference/Input-inputString.html)
Your answer
Follow this Question
Related Questions
How to edit navmesh at a runtime? 1 Answer
editable 3d text? 2 Answers
Export objects to a .3DS file at runtime 1 Answer