public static void Draw() { BasicSpriteRegistry.Draw(); foreach (IMultiSpriteInstance inst in _multiInstances) { foreach (IMovingSpriteInstance movinst in inst.Sprites) { if (movinst.Drawing) { _advancedSource = movinst.Animation.StartingSource; _advancedSource.X += _advancedSource.Width * movinst.Frame; _drawRect = new Rectangle((int)movinst.Location.X, (int)(movinst.Location.Y), (int)(_advancedSource.Width * movinst.Scale.X), (int)(_advancedSource.Height * movinst.Scale.Y)); if (movinst.SpriteBase.Draw(movinst, _drawRect) == 0) { UniversalVariables.spriteBatch.Draw(_advancedInstance.Animation.SpriteSheet, _drawRect, _advancedSource, movinst.DrawColor, movinst.Rotation, movinst.SpriteBase.Origin, movinst.DrawEffects, movinst.Depth); } } } } }
public static void AddInstance(ISpriteInstance instance) { BasicSpriteRegistry.AddInstance(instance); }
public static bool CheckCollision(string instancename1, string instancename2, bool AllowTranslucent1, bool AllowTranslucent2) { return(BasicSpriteRegistry.CheckCollision(instancename1, instancename2, AllowTranslucent1, AllowTranslucent2)); }
public static void UnLoadAll() { BasicSpriteRegistry.UnLoadAll(); }
public static void UnLoad(string spriteID) { BasicSpriteRegistry.UnLoad(spriteID); }
public static void LoadAllSprites(ContentManager content) { BasicSpriteRegistry.LoadAllSprites(content); }
public static void Load(string spriteID, ContentManager content) { BasicSpriteRegistry.Load(spriteID, content); }
public static void Add(ISprite2 sprite, ContentManager content) { BasicSpriteRegistry.Add(sprite, content); }
public static void UnloadAllText() { BasicSpriteRegistry.UnloadAllText(); }
public static void UnloadText(string TextID) { BasicSpriteRegistry.UnloadText(TextID); }
public static void LoadText(string TextID, ContentManager content) { BasicSpriteRegistry.LoadText(TextID, content); }
public static void Add(ISpriteText text, ContentManager content) { BasicSpriteRegistry.Add(text, content); }