示例#1
0
 protected override void Awake()
 {
     base.Awake();
     laserPool = new Queue <LaserBehaviour>();
     instance  = this;
     AllocPool();
 }
示例#2
0
 public SpaceForceGame()
 {
     graphics = new GraphicsDeviceManager(this);
     SetFullScreen();
     Content.RootDirectory = "Content";
     asteroidPool          = new AsteroidPool(this);
     backgroundPool        = new BackgroundPool(this);
     enemyShipPool         = new EnemyShipPool(this);
     laserPool             = new LaserPool(this);
     lifeGui = new LifeGui(this);
     SoundEffect.MasterVolume = 0.1f;
     MediaPlayer.Volume       = 0.1f;
 }
 void Awake()
 {
     Instance  = this;
     laserPool = new LaserPool(2000);
 }
示例#4
0
 void Start()
 {
     laserPool = FindObjectOfType <LaserPool>();
 }