public void Start() { MenuBackgroundSound.PlayBackground(); Button[] buttons = GetComponentsInChildren <Button>(true); foreach (Button b in buttons) { b.onClick.AddListener(PlayButtonSound); } }
private void Awake() { Events.OnSetMoney += OnSetMoney; Events.OnRequestMoney += OnRequestMoney; Events.OnHealthDestroyed += OnHealthDestroyed; Events.OnEndLevel += OnEndLevel; BackgroundMusic.PlayBackground(); }