C# Class Dodgeball.Engine.Sprite

Inheritance: GameObject
Mostrar archivo Open project: schonstal/BLOODBALL

Public Properties

Property Type Description
alpha float
blend Microsoft.Xna.Framework.Graphics.BlendState
color Color
graphicHeight int
graphicWidth int
offset Vector2
screenPositioning ScreenPositioning
sheetOffset Vector2
visible bool

Protected Properties

Property Type Description
animations Animation>.Dictionary
atlas Microsoft.Xna.Framework.Graphics.Texture2D
currentAnimation String

Public Methods

Method Description
Draw ( ) : void
Sprite ( float x = 0f, float y = 0f, int width, int height ) : System
Update ( ) : void
addAnimation ( String name, List frames, int fps = 15, bool looped = false ) : void
addAnimationCallback ( String animationName, Action callback ) : void
addOnCompleteCallback ( String animationName, Action callback ) : void
loadGraphic ( String textureName, int width, int height ) : void
play ( String animation ) : void
stop ( ) : void

Method Details

Draw() public method

public Draw ( ) : void
return void

Sprite() public method

public Sprite ( float x = 0f, float y = 0f, int width, int height ) : System
x float
y float
width int
height int
return System

Update() public method

public Update ( ) : void
return void

addAnimation() public method

public addAnimation ( String name, List frames, int fps = 15, bool looped = false ) : void
name String
frames List
fps int
looped bool
return void

addAnimationCallback() public method

public addAnimationCallback ( String animationName, Action callback ) : void
animationName String
callback Action
return void

addOnCompleteCallback() public method

public addOnCompleteCallback ( String animationName, Action callback ) : void
animationName String
callback Action
return void

loadGraphic() public method

public loadGraphic ( String textureName, int width, int height ) : void
textureName String
width int
height int
return void

play() public method

public play ( String animation ) : void
animation String
return void

stop() public method

public stop ( ) : void
return void

Property Details

alpha public_oe property

public float alpha
return float

animations protected_oe property

protected Dictionary animations
return Animation>.Dictionary

atlas protected_oe property

protected Texture2D,Microsoft.Xna.Framework.Graphics atlas
return Microsoft.Xna.Framework.Graphics.Texture2D

blend public_oe property

public BlendState,Microsoft.Xna.Framework.Graphics blend
return Microsoft.Xna.Framework.Graphics.BlendState

color public_oe property

public Color color
return Color

currentAnimation protected_oe property

protected String currentAnimation
return String

graphicHeight public_oe property

public int graphicHeight
return int

graphicWidth public_oe property

public int graphicWidth
return int

offset public_oe property

public Vector2 offset
return Vector2

screenPositioning public_oe property

public ScreenPositioning screenPositioning
return ScreenPositioning

sheetOffset public_oe property

public Vector2 sheetOffset
return Vector2

visible public_oe property

public bool visible
return bool