/// <summary> /// Initializes a new instance of the <see cref="TopTenComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public TopTenComponent(EverLite game) : base(game) { this.game = game; this.volume = VolumeManager.Instance; this.sound = SoundManager.Instance; }
/// <summary> /// Initializes a new instance of the <see cref="MenuComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public MenuComponent(EverLite game, MenuItemsComponent menuItems) : base(game) { this.game = game; this.menuItems = menuItems; this.volume = VolumeManager.Instance; this.sound = SoundManager.Instance; }
public GameScene(EverLite game, params GameComponent[] components) { this.game = game; this.components = new List <GameComponent>(); foreach (GameComponent component in components) { AddComponent(component); } }
/// <summary> /// Initializes a new instance of the <see cref="CollisionDetector"/> class. /// </summary> /// <param name="activeEnemies"> reference to list of all active enemies.</param> /// <param name="enemyBullets">reference to enemy bullets.</param> /// <param name="playerBullets">reference to player bullet.</param> /// <param name="player">reference to a current player.</param> /// <param name="score">reference to GameScore instance.</param> public CollisionDetector(List <LifetimeEntity> activeEnemies, List <Bullet> enemyBullets, List <Bullet> playerBullets, List <Item> items, Player player, EverLite score) { this.activeEnemies = activeEnemies; this.playerBullets = playerBullets; this.enemyBullets = enemyBullets; this.items = items; this.player = player; this.scoreKeeper = score; this.sound = SoundManager.Instance; }
/// <summary> /// Initializes a new instance of the <see cref="SidePanelComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public SidePanelComponent(EverLite game) : base(game) { this.game = game; this.playerSettings = PlayerSettings.Instance; this.sidePanel = this.game.Content.Load <Texture2D>(@"Sprites\background_narrowspace"); this.highScore = new HighScore { Id = 0, Name = "AAA", Score = 0 }; this.volume = VolumeManager.Instance; }
/// <summary> /// Initializes a new instance of the <see cref="MenuComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public MenuItemsComponent(EverLite game, Vector2 position, Color itemColor, Color selectedItemColor) : base(game) { this.game = game; this.position = position; this.itemColor = itemColor; this.selectedItemColor = selectedItemColor; items = new List <MenuItem>(); selectedItem = null; this.textSize = 80; }
/// <summary> /// Initializes a new instance of the <see cref="ScrollingStarsBackgroundComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public ScrollingStarsBackgroundComponent(EverLite game) : base(game) { this.game = game; this.texture = this.game.Content.Load <Texture2D>(@"Sprites\background_stars"); this.r1 = this.texture.Bounds; this.r2 = this.r1; this.r1.Y = -this.r1.Height; this.currentState = ScrollState.Start; this.transformManager = TransformManager.Instance; }
/// <summary> /// Initializes a new instance of the <see cref="GameWonComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public GameWonComponent(EverLite game) : base(game) { this.game = game; this.alphabet1 = this.alphabet2 = this.alphabet3 = new List <string> { "A", "B", "C", "D", "E", "F", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "!", "@", "#", "$" }; this.itemColor = Color.Red; this.selectedItemColor = Color.Yellow; this.letter1 = this.letter2 = this.letter3 = "A"; this.listName = ListName.letters1; this.volume = VolumeManager.Instance; this.sound = SoundManager.Instance; }
/// <summary> /// Initializes a new instance of the <see cref="PlayerSettingsComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public PlayerSettingsComponent(EverLite game) : base(game) { this.game = game; this.playerSettings = PlayerSettings.Instance; this.volume = VolumeManager.Instance; this.sound = SoundManager.Instance; this.controlList = new List <string> { "Move Up:", "Move Left:", "Move Down:", "Move Right:", "Shoot:", "Use Bomb:", "Slow Down:", "Change Weapon:", "Pause:" }; this.itemColor = Color.Red; this.selectedItemColor = Color.Yellow; this.selectedControl = "Move Up:"; }
/// <summary> /// Initializes a new instance of the <see cref="PlanetExplodeBackgroundComponent"/> class. /// </summary> /// <param name="game">game reference object.</param> public PlanetExplodeBackgroundComponent(EverLite game) : base(game) { this.game = game; }
/// <summary> /// Initializes a new instance of the <see cref="PlanetRingsBackgroundCompnent"/> class. /// </summary> /// <param name="game">game reference object.</param> public PlanetRingsBackgroundCompnent(EverLite game) : base(game) { this.game = game; }
static void Main() { using (var game = new EverLite()) game.Run(); }