private void Awake() { interactedBefore = false; activateText = new ActivateText(gameObject); resetNpcs = this.ResetNpcs; yesAnswer = this.YesButtonEvent; noAnswer = this.NoButtonEvent; }
/// <summary> /// Alustukset /// </summary> void Awake() { poi = FindObjectOfType <PointOfInterestController>(); player = FindObjectOfType <Player>(); hitbox = FindObjectOfType <ActivateText>(); inv = FindObjectOfType <InventoryManager>(); will = willEditor; william = new William(0); if (will != null) { will.SetActive(false); } count = -10; if (textFile != null) { textLines = (textFile.text.Split('\n')); charLine = textLines[currentLine].ToCharArray(); } if (isActive) { EnableTextBox(); } else { DisableTextBox(); } if (!canvasAdded) { DontDestroyOnLoad(transform.root.gameObject); canvasAdded = true; } else { Destroy(transform.root.gameObject); } }
new void Awake() { base.Awake(); activateText = new ActivateText(null); }