C# Class Defend_your_home.UI.ButtonImage

Inheritance: IGraphicsControl
Datei anzeigen Open project: MandragoraStudio/Defend-your-home

Protected Properties

Property Type Description
image Microsoft.Xna.Framework.Graphics.Texture2D
position Vector2
pressed bool
rotation float
textSize Vector2
tintColor Color
tintWhenTouched Color

Public Methods

Method Description
ButtonImage ( string imagen, Vector2 position, Color c ) : System
ButtonImage ( string imagen, Vector2 position, Color c, float rotation ) : System
Draw ( SpriteBatch spriteBatch ) : void
Update ( ) : void

Protected Methods

Method Description
CheckIfFirstTouchDown ( Vector2 touchPosition ) : bool
CheckIfTouchRelease ( Vector2 touchPosition ) : bool
DoOnTouchDown ( ) : void
DoOnTouchRelease ( ) : void
OnClick ( EventArgs e ) : void
OnTouchDown ( EventArgs e ) : void

Method Details

ButtonImage() public method

public ButtonImage ( string imagen, Vector2 position, Color c ) : System
imagen string
position Vector2
c Color
return System

ButtonImage() public method

public ButtonImage ( string imagen, Vector2 position, Color c, float rotation ) : System
imagen string
position Vector2
c Color
rotation float
return System

CheckIfFirstTouchDown() protected method

protected CheckIfFirstTouchDown ( Vector2 touchPosition ) : bool
touchPosition Vector2
return bool

CheckIfTouchRelease() protected method

protected CheckIfTouchRelease ( Vector2 touchPosition ) : bool
touchPosition Vector2
return bool

DoOnTouchDown() protected method

protected DoOnTouchDown ( ) : void
return void

DoOnTouchRelease() protected method

protected DoOnTouchRelease ( ) : void
return void

Draw() public method

public Draw ( SpriteBatch spriteBatch ) : void
spriteBatch Microsoft.Xna.Framework.Graphics.SpriteBatch
return void

OnClick() protected method

protected OnClick ( EventArgs e ) : void
e System.EventArgs
return void

OnTouchDown() protected method

protected OnTouchDown ( EventArgs e ) : void
e System.EventArgs
return void

Update() public method

public Update ( ) : void
return void

Property Details

image protected_oe property

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

position protected_oe property

protected Vector2 position
return Vector2

pressed protected_oe property

protected bool pressed
return bool

rotation protected_oe property

protected float rotation
return float

textSize protected_oe property

protected Vector2 textSize
return Vector2

tintColor protected_oe property

protected Color tintColor
return Color

tintWhenTouched protected_oe property

protected Color tintWhenTouched
return Color