SpriteDatabaseSpriteFromName Method |
Generate a new, named sprite from a sprite template stored in the database. Most of the time you do
not want to use this yourself. SpriteControllers that are defined with a database will automatically
look up sprite templates that they do not have sprites for. This function is just a wrapper for SmartDuplicateSprite.
Namespace:
SpriteLibrary
Assembly:
SpriteLibrary (in SpriteLibrary.dll) Version: 1.0.0.6 (1.0.0.6)
Syntaxpublic Sprite SpriteFromName(
string Name,
SpriteController ControllerToUse
)
Parameters
- Name
- Type: SystemString
The name of the sprite to load. Names are case-sensitive. - ControllerToUse
- Type: SpriteLibrarySpriteController
The sprite controller that will store the sprite in its cache
Return Value
Type:
SpriteA new, named sprite, or null if no such template is found.
See Also