hi all…
first of all, would like to thanks those forum members that have helped me with my newbee questions…
here’s another one ![]()
I just managed to insert a textfield through my script and I’m having some trouble in changing it’s default text value… meaning, I can select it but can’t actually write any new text in it…
thank you all, once again ![]()
here’s the code:
// ########## my main .js file ############
function OnGUI () {
var janelaParedes: Rect = Rect (Screen.width / 2 - 200 ,Screen.height / 2 - 150, 400, 300);
var janelaParedes1: Rect = Rect (Screen.width / 2 - 200 ,Screen.height / 2 - 150, 400, 300);
if (doWindow0)
janelaParedes = GUI.Window (0, janelaParedes, DoWindow0, "Criar Paredes - Escolher Opcao");
if (doWindow1) {
janelaParedes1 = GUI.Window (1, janelaParedes1, DoWindow1, "Wizard para layout de paredes");
WizardQuatroParedes.CriarWizard();
}
if (GUI.Button(Rect (10, 10, 100,30), "Criar Paredes")){
if (doWindow0 == true) {
doWindow0 = false;
} else {
doWindow0 = true;
}
}
}
// ########## my WizardQuatroParedes.js file ############
static function CriarWizard()
{
var textAreaString = "text area";
textAreaString = GUI.TextArea(new Rect (120, 10, 200, 100), textAreaString, 160);
if (GUI.TextArea.changed) {
textAreaString = GUI.TextArea.text;
}
}