C# Class Gruppe22.Client.TileObject

All animations used in displaying a specific tile
Inheritance: IXmlSerializable
显示文件 Open project: propra13-orga/gruppe22 Class Usage Examples

Public Methods

Method Description
AddAnimation ( string src, Backend start, int cols = 1, int rows = 1, Backend offset = null, Backend crop = null, bool order = false ) : void

Add multiple animation phases from a single file

FinalAnimation ( ) : void

Show the final phase of the animation

GetSchema ( ) : System.Xml.Schema.XmlSchema

Useless function from the IXmlSerializable-Interface

NextAnimation ( ) : bool

Loop animation to next frame

ReadXml ( System reader ) : void

Get XML-data from a file

ResetAnimation ( ) : void

Restart current animation at first frame

TileObject ( ) : System
TileObject ( Microsoft.Xna.Framework.Content.ContentManager content, int width = 128, int height = 192 ) : System

WriteXml ( System writer ) : void

Dump the whole group of animations to an XML-file

Private Methods

Method Description
Clear ( ) : void

Method Details

AddAnimation() public method

Add multiple animation phases from a single file
public AddAnimation ( string src, Backend start, int cols = 1, int rows = 1, Backend offset = null, Backend crop = null, bool order = false ) : void
src string Source File
start Backend TOp left corner of first frame (width and height determined by animation object!)
cols int Number of columns used in the animation
rows int Number of rows used in the animation
offset Backend
crop Backend
order bool Whether to read row by row (false, default) or column by column (true)
return void

FinalAnimation() public method

Show the final phase of the animation
public FinalAnimation ( ) : void
return void

GetSchema() public method

Useless function from the IXmlSerializable-Interface
public GetSchema ( ) : System.Xml.Schema.XmlSchema
return System.Xml.Schema.XmlSchema

NextAnimation() public method

Loop animation to next frame
public NextAnimation ( ) : bool
return bool

ReadXml() public method

Get XML-data from a file
public ReadXml ( System reader ) : void
reader System The file from which data will be read
return void

ResetAnimation() public method

Restart current animation at first frame
public ResetAnimation ( ) : void
return void

TileObject() public method

public TileObject ( ) : System
return System

TileObject() public method

public TileObject ( Microsoft.Xna.Framework.Content.ContentManager content, int width = 128, int height = 192 ) : System
content Microsoft.Xna.Framework.Content.ContentManager
width int
height int
return System

WriteXml() public method

Dump the whole group of animations to an XML-file
public WriteXml ( System writer ) : void
writer System The file used to write the data
return void