Exemple #1
0
 public void DestroyWithoutScore()
 {
     lockOn.RemoveMe(transform);
     OnDestroyWithoutScore.Invoke();
     if (!Addressables.ReleaseInstance(this.gameObject))
     {
         Destroy(gameObject);
     }
 }
Exemple #2
0
 void Start()
 {
     enemys = GetComponent <BezierSolution.BezierWalkerLocomotion>().Tail.Select(x => x.GetComponent <SnakeSlave>()).ToList();
     foreach (SnakeSlave s in enemys)
     {
         s.transform.parent = transform;
     }
     OnDestroyWithScore.AddListener(MultiEnemyDestroyWithScore);
     OnDestroyWithoutScore.AddListener(MultiEnemyDestroyWithoutScore);
 }
Exemple #3
0
 public void DestroyWithoutScore()
 {
     lockOn.RemoveMe(transform);
     OnDestroyWithoutScore.Invoke();
     StartCoroutine(this.DelayMethod(1f, () =>
     {
         if (!Addressables.ReleaseInstance(this.gameObject))
         {
             Destroy(gameObject);
         }
     }));
 }
Exemple #4
0
 void Start()
 {
     OnDestroyWithScore.AddListener(EnemyDestroyWithScore);
     OnDestroyWithoutScore.AddListener(EnemyDestroyWithoutScore);
 }