コード例 #1
0
 public void EjectSpawnEgg()
 {
     if (enemyCount < maxAttackCount)
     {
         if (gameObject.activeInHierarchy && aSource)
         {
             aSource.Play();
         }
         EggSpawner egg           = ObjectPoolManager.Spawn(eggSpawnerPrefab, transform.position, Quaternion.identity);
         Vector2    randDirection = EssoUtility.GetVectorFromAngle(Random.Range(0f, 360f));
         egg.EjectEgg(ejectForce, randDirection);
         egg.SetUpEgg(playerTransform, GetRandomEnemyFromList(), this);
     }
 }