示例#1
0
文件: GameWorld.cs 项目: tivtag/Fly
        public static GameWorld Create(FlyScene scene, IRand rand)
        {
            var playerEmpire = new Empire();
            var enemyEmpire  = new Empire();

            return(new GameWorld(playerEmpire, enemyEmpire, scene, rand));
        }
示例#2
0
文件: GameWorld.cs 项目: tivtag/Fly
 public GameWorld(Empire playerEmpire, Empire enemyEmpire, FlyScene scene, IRand rand)
 {
     this.playerEmpire = playerEmpire;
     this.enemyEmpire  = enemyEmpire;
     this.scene        = scene;
     this.gravity      = new SceneGravityApplicator(scene);
 }
示例#3
0
文件: JukeBox.cs 项目: tivtag/Fly
        /// <summary>
        /// Initializes a new instance of the <see cref="JukeBox"/> class.
        /// </summary>
        /// <param name="rand">
        /// A random number generator.
        /// </param>
        /// <param name="audioSystem">
        /// The audo system responsible
        /// </param>
        public JukeBox(IRand rand, AudioSystem audioSystem)
        {
            this.rand        = rand;
            this.audioSystem = audioSystem;

            this.ManualChangeAllowed = true;
            this.FadeInIsEnabled     = true;
            this.FadeOutIsEnabled    = true;
        }
示例#4
0
        public AsteroidPusher(IRand rand)
        {
            Contract.Requires(rand != null);

            this.rand = rand;
        }
示例#5
0
 public KamikazeBlubWave(IRand rand)
 {
     this.rand       = rand;
     this.enemyCount = DefaultEnemyCount.GetRandomValue(this.rand);
 }
示例#6
0
 public Generator(IRand rand)
 {
     this.rand = rand;
 }
示例#7
0
 public FixedIntervalWaveGuide(GameWorld world, IRand rand)
 {
     this.world = world;
     this.rand  = rand;
 }
示例#8
0
 public RecursiveSplitMazeGenerator(IRand rand, Dimension dimension)
 {
     this.rand = rand;
     maze      = Maze.Build(dimension);
 }
 public RandomMazeGenerator(IRand rand)
 {
     this.rand = rand;
 }