C# Class GPSTD_RM.LaserProjectile

Inheritance: Projectile
Show file Open project: dideler/gps-tower-defense Class Usage Examples

Public Properties

Property Type Description
DEFAULT_LIFESPAN System.TimeSpan

Public Methods

Method Description
Draw ( GameTime time ) : void

The drawing of the laser projectile should be different because it's not a sprite

LaserProjectile ( Microsoft.Xna.Framework.Game g, Vector2 position, Vector2 velocity, Vector2 direction, int attackPower ) : System

Construct a laser projectile with a direction.

Update ( GameTime time ) : void

Basic update logic.

Private Methods

Method Description
LaserProjectile ( Microsoft.Xna.Framework.Game g, Vector2 position, Vector2 velocity, int attackPower ) : System

Method Details

Draw() public method

The drawing of the laser projectile should be different because it's not a sprite
public Draw ( GameTime time ) : void
time Microsoft.Xna.Framework.GameTime The current game time.
return void

LaserProjectile() public method

Construct a laser projectile with a direction.
public LaserProjectile ( Microsoft.Xna.Framework.Game g, Vector2 position, Vector2 velocity, Vector2 direction, int attackPower ) : System
g Microsoft.Xna.Framework.Game The game containing this object.
position Vector2 Initial position.
velocity Vector2 This really has no effect on this type of projectile.
direction Vector2 Which way is the laser going?
attackPower int How much damage will it do?
return System

Update() public method

Basic update logic.
public Update ( GameTime time ) : void
time Microsoft.Xna.Framework.GameTime The current game time.
return void

Property Details

DEFAULT_LIFESPAN public static property

public static TimeSpan,System DEFAULT_LIFESPAN
return System.TimeSpan