Knits the main control classes together by feeding events raised by one to another
View code on GitHub
Inheritance Hierarchy
Blocks Game
Namespace: Blocks
Assembly: Blocks (in Blocks.exe) Version: 1.1.1.0 (1.1.1)
Syntax
The Game type exposes the following members.
Constructors
Name | Description | |
---|---|---|
Game | Initializes a new instance of the Game class |
Methods
Name | Description | |
---|---|---|
StartGame |
Properties
Name | Description | |
---|---|---|
Controller | ||
DisplayMode | ||
IsInGame | ||
UserInterface |
Remarks
Examples
[Test, CloseAfterFirstFrame] public void CreateGameInPortrait() { var window = Resolve<Window>(); window.ViewportPixelSize = new Size(600, 800); AdvanceTimeAndUpdateEntities(); }
[Test, CloseAfterFirstFrame] public void CreateGameInLandscape() { var window = Resolve<Window>(); window.ViewportPixelSize = new Size(800, 600); AdvanceTimeAndUpdateEntities(); }
[Test, CloseAfterFirstFrame] public void AffixingBlockAddsToScore() { game.StartGame(); Assert.AreEqual(0, game.UserInterface.Score); AdvanceTimeAndUpdateEntities(10.0f); Assert.AreEqual(1, game.UserInterface.Score); }
See Also