C# Class Bug.Display.Button

Inheritance: UiElement
Show file Open project: Projectfights/Fight-insect Class Usage Examples

Public Properties

Property Type Description
select OnSelect

Public Methods

Method Description
Button ( int x, int y, Microsoft.Xna.Framework.Graphics.Texture2D up_, Microsoft.Xna.Framework.Graphics.Texture2D down_ ) : Microsoft.Xna.Framework
Collide ( int pointX, int pointY ) : bool
Draw ( SpriteBatch batch ) : void
SetPressed ( bool pressed_, bool toggle = true ) : void

Private Methods

Method Description
IsPressed ( ) : bool

Method Details

Button() public method

public Button ( int x, int y, Microsoft.Xna.Framework.Graphics.Texture2D up_, Microsoft.Xna.Framework.Graphics.Texture2D down_ ) : Microsoft.Xna.Framework
x int
y int
up_ Microsoft.Xna.Framework.Graphics.Texture2D
down_ Microsoft.Xna.Framework.Graphics.Texture2D
return Microsoft.Xna.Framework

Collide() public method

public Collide ( int pointX, int pointY ) : bool
pointX int
pointY int
return bool

Draw() public method

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

SetPressed() public method

public SetPressed ( bool pressed_, bool toggle = true ) : void
pressed_ bool
toggle bool
return void

Property Details

select public property

public OnSelect select
return OnSelect