public virtual void Draw(SpriteBatch batch, Vector2 position, StageCamera camera) { position.X += m_currentAnimation[m_currentFrame].XOffset; position.Y += m_currentAnimation[m_currentFrame].YOffset; SpriteEffects effects = m_currentAnimation[m_currentFrame].Mirrored ? SpriteEffects.FlipHorizontally : SpriteEffects.None; batch.Draw(m_sprite.Texture, camera.ToCameraPosition(position), m_sprite.GetSourceFrame(m_currentAnimation[m_currentFrame].FrameIndex), Color.White, 0, Vector2.Zero, 1, effects, 0); }
public virtual void Draw(SpriteBatch batch, Vector2 position, int frameIndex, StageCamera camera) { batch.Draw(m_sprite, camera.ToCameraPosition(position), m_sourceRects[frameIndex], Color.White, 0, Vector2.Zero, 1, SpriteEffects.None, 0); }
public void Draw(SpriteBatch batch, StageCamera camera) { m_texture.Draw(batch, camera.ToCameraPosition(new Vector2(m_bounds.X, m_bounds.Y)), 0); }