Sprite Sheet: Monogame

// For manual region mapping (JSON/XML defined) public void AddRegion(string name, Rectangle region)

public class SpriteSheet

public void Update(GameTime gt)

public void Draw(SpriteBatch sb)

string json = File.ReadAllText(jsonPath); var data = JsonSerializer.Deserialize<SpriteSheetData>(json); Texture2D texture = content.Load<Texture2D>(data.Texture); var sheet = new SpriteSheet(texture, data.FrameWidth, data.FrameHeight); foreach (var region in data.Regions) monogame sprite sheet

public void Draw(SpriteBatch spriteBatch, Vector2 position, Color color) // For manual region mapping (JSON/XML defined) public