forked from cgvr/DeltaVR
professor says good job after first config done
This commit is contained in:
@@ -35,11 +35,13 @@ public class ShapeScannerConfiguration
|
||||
|
||||
public class ShapeScanner : MonoBehaviour
|
||||
{
|
||||
public delegate void OnShapeScannerCompletedDelegate();
|
||||
public event OnShapeScannerCompletedDelegate OnShapeScannerCompleted;
|
||||
public delegate void OnConfigCompletedDelegate();
|
||||
public event OnConfigCompletedDelegate OnConfigCompleted;
|
||||
public delegate void OnAllCompletedDelegate();
|
||||
public event OnAllCompletedDelegate OnAllCompleted;
|
||||
|
||||
[Header("Static References")]
|
||||
public List<ShapeScannerConfiguration> configurations = new List<ShapeScannerConfiguration>();
|
||||
public List<ShapeScannerConfiguration> configurations = new();
|
||||
public ShapeScannerRay rayPrefab;
|
||||
public Transform raySpawnCorner1;
|
||||
public Transform raySpawnCorner2;
|
||||
@@ -163,6 +165,8 @@ public class ShapeScanner : MonoBehaviour
|
||||
AudioManager.Instance.PlayAttachedInstance(FMODEvents.Instance.ShapeScannerSuccess, gameObject);
|
||||
if (!particles.isPlaying) particles.Play();
|
||||
particles.Emit(100);
|
||||
|
||||
OnConfigCompleted?.Invoke();
|
||||
}
|
||||
|
||||
private float CalculateCorrectPercentage()
|
||||
@@ -235,6 +239,6 @@ public class ShapeScanner : MonoBehaviour
|
||||
// Create line renderer from shape scanner to door card reader
|
||||
lineRenderer.enabled = true;
|
||||
|
||||
OnShapeScannerCompleted?.Invoke();
|
||||
OnAllCompleted?.Invoke();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user