public ScoreBoard(Texture2D texture, Vector2 position, Trex trex, SoundEffect scoreSfx) { _texture = texture; _trex = trex; Position = position; _scoreSfx = scoreSfx; }
public CactusGroup(Texture2D spriteSheet, bool isLarge, GroupSize size, Trex trex, Vector2 position) : base(trex, position) { IsLarge = isLarge; Size = size; // The order matters size needs to be set first Sprite = GenerateSprite(spriteSheet); }
public ObstacleManager(EntityManager entityManager, Trex trex, ScoreBoard scoreBoard, Texture2D spriteSheet) { _entityManager = entityManager; _trex = trex; _scoreBoard = scoreBoard; _random = new Random(); _spriteSheet = spriteSheet; }
public SkyManager(Trex trex, Texture2D spriteSheet, EntityManager entityManager, ScoreBoard scoreBoard) { _trex = trex; _spriteSheet = spriteSheet; _entityManager = entityManager; _scoreBoard = scoreBoard; _random = new Random(); }
public GroundManager(Texture2D spriteSheet, EntityManager entityManager, Trex trex) { _spriteSheet = spriteSheet; _entityManager = entityManager; _groundTiles = new List <GroundTile>(); _regularSprite = new Sprite(spriteSheet, SPRITE_POS_X, SPRITE_POS_Y, SPRITE_WIDTH, SPRITE_HEIGHT); _bumpySprite = new Sprite(spriteSheet, SPRITE_POS_X + SPRITE_WIDTH, SPRITE_POS_Y, SPRITE_WIDTH, SPRITE_HEIGHT); _trex = trex; _random = new Random(); }
public FlyingDino(Trex trex, Vector2 position, Texture2D spriteSheet) : base(trex, position) { Sprite spriteA = new Sprite(spriteSheet, TEXTURE_COORDS_X, TEXTURE_COORDS_Y, SPRITE_WIDTH, SPRITE_HEIGHT); Sprite spriteB = new Sprite(spriteSheet, TEXTURE_COORDS_X + SPRITE_WIDTH, TEXTURE_COORDS_Y, SPRITE_WIDTH, SPRITE_HEIGHT); _trex = trex; _animation = new SpriteAnimation(); _animation.AddFrame(spriteA, 0); _animation.AddFrame(spriteB, ANIMATION_FRAME_LENGTH); _animation.AddFrame(spriteA, ANIMATION_FRAME_LENGTH * 2); _animation.ShouldLoop = true; _animation.Play(); }
public Star(Texture2D spriteSheet, Trex trex, Vector2 position) : base(trex, position) { _animation = SpriteAnimation.CreateSimpeAnimation( spriteSheet, new Point(INITIAL_FRAME_TEXTURE_COORDS_X, INITIAL_FRAME_TEXTURE_COORDS_Y), SPRITE_WIDTH, SPRITE_HEIGHT, new Point(0, SPRITE_HEIGHT), 3, ANIMATION_FRAME_LENGTH ); _animation.ShouldLoop = true; _animation.Play(); }
public SkyManager(Trex trex, Texture2D spriteSheet, Texture2D invertedSpriteSheet, EntityManager entityManager, ScoreBoard scoreBoard) { this._entityManager = entityManager; this._scoreBoard = scoreBoard; _random = new Random(); this._trex = trex; _spriteSheet = spriteSheet; _invertedSpriteSheet = invertedSpriteSheet; _textureData = new Color[_spriteSheet.Width * _spriteSheet.Height]; _invertedTextureData = new Color[_invertedSpriteSheet.Width * _invertedSpriteSheet.Height]; _spriteSheet.GetData(_textureData); _invertedSpriteSheet.GetData(_invertedTextureData); _overlay = new Texture2D(spriteSheet.GraphicsDevice, 1, 1); Color[] overlayData = new[] { Color.Gray }; _overlay.SetData(overlayData); }
public Moon(IDayNightCycle dayNightCycle, Texture2D spriteSheet, Trex trex, Vector2 position) : base(trex, position) { _dayNightCycle = dayNightCycle; _sprite = new Sprite(spriteSheet, RIGHTMOST_SPRITE_COORDS_X, RIGHTMOST_SPRITE_COORDS_Y, SPRITE_WIDTH, SPRITE_HEIGHT); }
protected Obstacle(Trex trex, Vector2 position) { _trex = trex; Position = position; }
public Cloud(Texture2D spriteSheet, Trex trex, Vector2 position) : base(trex, position) { _sprite = new Sprite(spriteSheet, TEXTURE_COORDS_X, TEXTURE_COORDS_Y, SPRITE_WIDTH, SPRITE_HEIGHT); }
protected SkyObject(Trex trex, Vector2 position) { _trex = trex; Position = position; }
public CactusGroup(Texture2D spriteSheet, bool isLarge, GroupSize size, Trex trex, Vector2 position) : base(trex, position) { IsLarge = isLarge; Size = size; Sprite = GenerateSprite(spriteSheet); }
public SkyObject(Trex trex, Vector2 position) { _trex = trex; Position = position; }