public void AddSpriteDefinition(Texture texture, Ur.Grid.Rect subrect, string identity) { var l = spriteDefsByTexture[texture]; var def = new SpriteDefinition(identity, texture, subrect, l.Count); l.Add(def); allSpriteDefinitions.Add(def); spriteDefsByStringID.Add(textureIdentitiesLookup[texture] + ":" + identity, def); }
static internal SFML.Graphics.IntRect ToSFMLIntRect(this Ur.Grid.Rect source) { return(new SFML.Graphics.IntRect(source.X0, source.Y0, source.Width, source.Height)); }