private void InitBulletPool()
        {
            this.bullets = new Bullet[this.bulletMax];

            for(int i = 0; i < this.bulletMax; i++)
            {
                Bullet bullet = new Bullet();
                this.bullets[i] = bullet;
                this.EntityManager.Add(bullet.Entity);
            }
        }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BulletBehavior" /> class.
 /// </summary>
 /// <param name="bullet">The bullet.</param>
 public BulletBehavior(Bullet bullet)
 {
     this.bullet = bullet;
 }