Ejemplo n.º 1
0
 private void OnEnable()
 {
     _stateReporter          = stateReporter.GetComponent <IARSessionStateReporter>();
     _planeManager           = GetComponent <ARPlaneManager>();
     ARSession.stateChanged += StateChangedEvent;
     if (_planeManager != null)
     {
         _planeManager.planesChanged += PlaneChangedEvent;
     }
 }
Ejemplo n.º 2
0
 private void OnValidate()
 {
     if (stateReporter == null)
     {
         return;
     }
     _stateReporter = stateReporter.GetComponent <IARSessionStateReporter>();
     if (_stateReporter == null)
     {
         stateReporter = null;
     }
 }