コード例 #1
0
 // Use this for initialization
 void Start()
 {
     createdPanel = (GameObject)Instantiate(textPanel, transform);
     createdPanel.transform.position      = new Vector3(0, 0, 0);
     createdPanel.transform.localPosition = new Vector3(0, 0, 0);
     Text[] textComponents = GetComponentsInChildren <Text>();
     promptText = textComponents[0];
     answerText = textComponents[1];
     button     = GetComponentInChildren <Button>();
     button.onClick.AddListener(SubmitChoices);
     promptText.text = "Enter the address to connect to";
     this.jndp       = GetComponentInParent <GameManager>().jndp;
 }