Hi How i can create a box with a button that player can type in box and if player click on the button all of text send in unity as a variable ? sorry for my english
Hi,
What you want to use is the built-in GUI Object GUI.TextArea
http://unity3d.com/support/documentation/ScriptReference/GUI.TextArea.html
Details on how to implement this are at the link. Basically TextArea has a string association called "text." You can have a GUI.Button that "submits" this text to wherever you like through code. So something like:
void submitText() {
string submittedText = myTextArea.text;
}
EZGUI, a commercial product, also has some nice low-draw-call text area functionality: