Exemplo n.º 1
0
 static BlusterShotBehavior GetShot(Transform transform, BlusterShotBehavior bluster)
 {
     if (free.Count > 0)
     {
         var shot = free.Pop();
         shot.transform.position = transform.position;
         shot.transform.rotation = transform.rotation;
         return(shot);
     }
     else
     {
         return((BlusterShotBehavior)Instantiate(bluster, transform.position, transform.rotation));
     }
 }
Exemplo n.º 2
0
 public static void Go(BlusterShotBehavior bluster, Transform start, float damage, float speed, float lifeTime, Transform friend, ShipController master)
 {
     GetShot(start, bluster).Go(damage, speed, lifeTime, friend, master);
 }