public BaseGameState(Game1 game, GameStateManager manager)
            : base(game, manager)
        {
            GameRef = game;

            playerIndexInControl = PlayerIndex.One;
        }
Ejemplo n.º 2
0
 public GameState(Game1 game, GameStateManager manager)
     : base(game)
 {
     StateManager = manager;
     childComponents = new List<GameComponent>();
     tag = this;
 }
Ejemplo n.º 3
0
        public Game1()
        {
            graphics = new GraphicsDeviceManager(this);
            graphics.PreferredBackBufferWidth = screenRenderWidth;
            graphics.PreferredBackBufferHeight = screenRenderHeight;

            ScreenRectangle = new Rectangle(0, 0, screenWidth, screenHeight);

            Content.RootDirectory = "Content";

            Components.Add(new InputHandler(this));

            stateManager = new GameStateManager(this);
            Components.Add(stateManager);

            // Telas do jogo:
            TitleScreen = new TitleScreen(this, stateManager);
            StartMenuScreen = new StartMenuScreen(this, stateManager);
            GamePlayScreen = new GamePlayScreen(this, stateManager);
            CharacterSelectScreen = new CharacterSelectScreen(this, stateManager);

            stateManager.ChangeState(TitleScreen);
        }
 public GamePlayScreen(Game1 game, GameStateManager manager)
     : base(game, manager)
 {
     player = new Player(game);
 }
 public TitleScreen(Game1 game, GameStateManager manager)
     : base(game, manager)
 {
 }
 public CharacterSelectScreen(Game1 game, GameStateManager stateManager)
     : base(game, stateManager)
 {
 }
 public StartMenuScreen(Game1 game, GameStateManager manager)
     : base(game, manager)
 {
 }