コード例 #1
0
        private WorldScreen makeWorldScreen()
        {
            WeaponAugmentFactory         factory   = new WeaponAugmentFactory();
            List <WeaponAugmentTemplate> templates = new List <WeaponAugmentTemplate>()
            {
                factory.Damager, factory.Flier
            };
            WeaponStats weaponStats = factory.BasicWeapon.WithAugments(templates);

            List <WeaponStats> enemyWeapons = new List <WeaponStats>()
            {
                weaponStats
            };

            Size         size         = this.size;
            WorldFactory worldFactory = new WorldFactory(new Random());
            WorldLoader  worldLoader  = worldFactory.Build(2, this.size);
            LevelPlayer  levelPlayer  = this.player.PrepareForNewLevel();

            worldLoader.addItemAndDisableUnloading(levelPlayer);
            this.worldScreen = new WorldScreen(size, levelPlayer, worldLoader);
            this.worldScreen.setEscapeEnabled(true);
            return(this.worldScreen);
        }