C# Class AnimatedSprite.PlayerWithWeapon

Inheritance: Sprite
Datei anzeigen Open project: itsligoGames/MonoGameTileSheetExample Class Usage Examples

Public Properties

Property Type Description
Health int
MovingState STATE
TargetTilePos Vector2
speed float

Protected Properties

Property Type Description
Site CrossHair

Public Methods

Method Description
Draw ( SpriteBatch spriteBatch, Microsoft.Xna.Framework.Graphics.Texture2D tx ) : void
PlayerWithWeapon ( Vector2 userPosition, Vector2 tileBounds, List InitialSheetRefs, int frameWidth, int frameHeight, float layerDepth ) : System
Update ( GameTime gameTime ) : void
checkforMovement ( ) : void
loadProjectile ( Projectile r ) : void
setFrameSet ( DIRECTION d, List sheetRefs ) : void
setHealthBar ( GraphicsDevice gDev ) : void

Method Details

Draw() public method

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

PlayerWithWeapon() public method

public PlayerWithWeapon ( Vector2 userPosition, Vector2 tileBounds, List InitialSheetRefs, int frameWidth, int frameHeight, float layerDepth ) : System
userPosition Vector2
tileBounds Vector2
InitialSheetRefs List
frameWidth int
frameHeight int
layerDepth float
return System

Update() public method

public Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
return void

checkforMovement() public method

public checkforMovement ( ) : void
return void

loadProjectile() public method

public loadProjectile ( Projectile r ) : void
r Projectile
return void

setFrameSet() public method

public setFrameSet ( DIRECTION d, List sheetRefs ) : void
d DIRECTION
sheetRefs List
return void

setHealthBar() public method

public setHealthBar ( GraphicsDevice gDev ) : void
gDev GraphicsDevice
return void

Property Details

Health public_oe property

public int Health
return int

MovingState public_oe property

public STATE MovingState
return STATE

Site protected_oe property

protected CrossHair,AnimatedSprite Site
return CrossHair

TargetTilePos public_oe property

public Vector2 TargetTilePos
return Vector2

speed public_oe property

public float speed
return float