private void bindGame() { Sumo blueSumo = new Sumo(Sumo.Type.Blue, iGetScoreOf(Sumo.Type.Blue), m_sumoSettings); Sumo redSumo = new Sumo(Sumo.Type.Red, iGetScoreOf(Sumo.Type.Red), m_sumoSettings); Game game = new Game(new Sumo[] { blueSumo, redSumo }); Container.Bind <Game>().FromInstance(game).AsSingle(); }
/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { // Create a new SpriteBatch, which can be used to draw textures. spriteBatch = new SpriteBatch(GraphicsDevice); bakgrund = new bakgrund(Content.Load <Texture2D>("isplatta"), Window.ClientBounds.Width / 2, Window.ClientBounds.Height / 2); sumo = new Sumo(Content.Load <Texture2D>("stone"), 400, 300, 0f, 0f); sumo2 = new Sumo2(Content.Load <Texture2D>("mine"), 400, 400, 10.5f, 8.5f); // TODO: use this.Content to load your game content here }
public void Construct(SumoControls _controls, Slime.Factory _slimeFactory, Sumo _sumoModel, Game _game) { m_controls = _controls; m_slimeFactory = _slimeFactory; m_sumoModel = _sumoModel; m_game = _game; }
public void Construct(SumoAnimator _animator, SumoControls _controls, Sumo _sumoModel, Game _game) { m_animator = _animator; m_controls = _controls; m_sumoModel = _sumoModel; m_game = _game; }
private void checkForScoreIcrease(int _iHealth) { if (_iHealth > 0) { return; } foreach (Sumo.Type type in Enum.GetValues(typeof(Sumo.Type))) { Sumo sumo = m_game.sumoGet(type); if (sumo.iHealth > 0) { sumo.increaseScore(); } } }
public void Construct(Sumo _sumoModel, Game _game) { m_sumoModel = _sumoModel; m_game = _game; }
public void Construct(Sumo _sumoModel) { m_sumoModel = _sumoModel; }
public void Construct(Sumo _sumo, Game _game) { m_sumo = _sumo; m_game = _game; }
private void Construct(Sumo _sumo) { m_sumo = _sumo; }
public void Construct(Sumo _sumo) { m_sumo = _sumo; }