AutomaticallyUpdatedSprites
Introduction
Adding and Removing from AutomaticallyUpdatedSprites
AutomaticallyUpdatedSprites is a SpriteList which is exposed for debugging, tools development, and advanced FlatRedBall programming. Most games do not need to add or remove Sprites directly from this list. This list is added to and removed from using more common FlatRedBall methods.
Adding to AutomaticallyUpdatedSprites
AutomaticallyUpdatedSprites gets populated whenever a Sprite is added through the SpriteManager. For example:
Adding existing instances also adds the Sprite to AutomaticallyUpdatedSprites:
Also adding a Sprite to a Layer will add it to AutomaticallyUpdatedSprites:
Removing from AutomaticallyUpdatedSprites
AutomaticallyUpdatedSprites is a SpriteList which means it inherits from PositionedObjectList so it shares a two-way relationship with any Sprite that is added to it. Calling SpriteManager.RemoveSprite is the recommended way of removing a Sprite from this List.
Last updated