protected override void Awake() { _devicesCurrent = new List <Device>(); _devicesAddedOnDiscovery = new List <Device>(); _devicesRemovedOnDiscovery = new List <Device>(); SetupButtonPool(); SetupAudio(); // Cache animation state _animatedDividerTransform.SetPivotCenterMiddle(); _animatedDividerTransform.SetAnchorCenterMiddle(); _parentRectTransform = ((RectTransform)_animatedDividerTransform.parent); _waitAnimationDelay = new WaitForSecondsRealtimeCacheable(_animationIntervalDelay); _repeatAudioIntervalDelay = new WaitForSecondsRealtimeCacheable(REPEAT_INTERVAL); _repeatAudioDelay = new WaitForSecondsRealtimeCacheable(_sfxSearching.length); _panel.DeviceSearching += OnDeviceSearching; _panel.DeviceConnecting += OnDeviceConnecting; _panel.DeviceConnectFailure += OnDeviceConnectEnd; _panel.DeviceConnectSuccess += OnDeviceConnectEnd; _panel.DevicesFound += OnDevicesFound; _panel.Closed += OnPanelClosed; base.Awake(); }
protected override void Awake() { SetupAudio(); _wait = new WaitForSecondsRealtimeCacheable(_showSuccessDelay); base.Awake(); }