public void Open(InteractiblePuzzle ip) { messageText.text = ip.message; foreach (Button child in ip.myPuzzleCanvas.GetComponentsInChildren<Button>(true)) { if (child.tag == "ExitButton") { exitButton = child; } } exitButton.onClick.AddListener (Exit); currentPuzzleObject = ip; ActivateExit (true); base.Open(); }
public void Open(InteractiblePuzzle ip) { messageText.text = ip.message; foreach (Button child in ip.myPuzzleCanvas.GetComponentsInChildren <Button>(true)) { if (child.tag == "ExitButton") { exitButton = child; } } exitButton.onClick.AddListener(Exit); currentPuzzleObject = ip; ActivateExit(true); base.Open(); }