SpriteLibrary
SpriteLibrary
SpriteLibrary
SpriteDatabase Class
SpriteDatabase Methods
CloneByXMLSerializing(T) Method
GetImageFromName Method
GetImageNames Method
LoadObjectFromXmlFile(T) Method
OpenEditWindow Method
ReadFromXmlFile(T) Method
ReadFromXmlString(T) Method
Save Method
SetIcon Method
SetSnapGridSize Method
SpriteFromName Method
SpriteNames Method
WriteToXmlFile(T) Method
WriteToXMLString(T) Method

# SpriteDatabase SpriteFromName 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)
Syntax
C#
Copy

    public Sprite SpriteFromName(
    	string Name,
    	SpriteController ControllerToUse
    )

#### Parameters

Name
  Type: System
  String
  The name of the sprite to load. Names are case-sensitive.
ControllerToUse
  Type: SpriteLibrary
  SpriteController
  The sprite controller that will store the sprite in its cache

#### Return Value

Type: Sprite
A new, named sprite, or null if no such template is found.
See Also

#### Reference

SpriteDatabase Class
SpriteLibrary Namespace