C# Class UHSampleGame.CoreObjects.Towers.Tower

Inheritance: StaticTileObject
Show file Open project: holtkampw/UH-Sample-XNA-Project Class Usage Examples

Public Properties

Property Type Description
Cost int
Health int
HealthCapacity int
ID int
Level int
LevelString string
PlayerNum int
Position Vector3
Scale float
Status TowerStatus
TeamNum int
TotalInvestedCost int
Transforms Matrix
Type TowerType
UnitTypeToBuild UnitType
XP int
attackStrength int
destroyCost int
repairCost int
tile UHSampleGame.TileSystem.Tile
towerEnumType System.Enum[]
towerUpgradeEnumType System.Enum[]
towersToAttack List
unitToAttack Unit
upgradeCost int

Public Methods

Method Description
Activate ( int playerNum, int teamNum ) : void
AttackUnit ( ) : void
CanUpgrade ( ) : bool
DestroyCost ( ) : int
DrawHud ( GameTime gameTime ) : void
InputDown ( ) : void
InputLeft ( ) : void
InputRight ( ) : void
InputUp ( ) : void
IsActive ( ) : bool
OnDied ( ) : void
RegisterAttackTower ( Tower &tower ) : void
RegisterAttackUnit ( GameEventArgs args ) : void
RegisterAttackUnit ( Unit &unit ) : void
Repair ( int money ) : int
RepairCost ( ) : int
RotateX ( float rotation ) : void
RotateY ( float rotation ) : void
RotateZ ( float rotation ) : void
SetScale ( float newScale ) : void
Setup ( Vector3 position ) : void
TakeDamage ( int damage ) : bool
Tower ( Model model, Tile tile ) : System
Tower ( TowerType type ) : System
UnregisterAttackTower ( Tower &tower ) : void
UnregisterAttackUnit ( Unit &unit ) : void
Update ( GameTime gameTime ) : void
UpdateTransforms ( ) : void
Upgrade ( int money ) : int
UpgradeCost ( ) : int
ValidateUnitInput ( ) : void
XPUpgrade ( ) : void

Private Methods

Method Description
Attack ( GameTime gameTime ) : void
BuildUnit ( GameTime gameTime ) : void
GetNewAttackUnit ( Unit unit ) : void
UpdateScaleRotations ( ) : void

Method Details

Activate() public method

public Activate ( int playerNum, int teamNum ) : void
playerNum int
teamNum int
return void

AttackUnit() public method

public AttackUnit ( ) : void
return void

CanUpgrade() public method

public CanUpgrade ( ) : bool
return bool

DestroyCost() public method

public DestroyCost ( ) : int
return int

DrawHud() public method

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

InputDown() public method

public InputDown ( ) : void
return void

InputLeft() public method

public InputLeft ( ) : void
return void

InputRight() public method

public InputRight ( ) : void
return void

InputUp() public method

public InputUp ( ) : void
return void

IsActive() public method

public IsActive ( ) : bool
return bool

OnDied() public method

public OnDied ( ) : void
return void

RegisterAttackTower() public method

public RegisterAttackTower ( Tower &tower ) : void
tower Tower
return void

RegisterAttackUnit() public method

public RegisterAttackUnit ( GameEventArgs args ) : void
args UHSampleGame.Events.GameEventArgs
return void

RegisterAttackUnit() public method

public RegisterAttackUnit ( Unit &unit ) : void
unit UHSampleGame.CoreObjects.Units.Unit
return void

Repair() public method

public Repair ( int money ) : int
money int
return int

RepairCost() public method

public RepairCost ( ) : int
return int

RotateX() public method

public RotateX ( float rotation ) : void
rotation float
return void

RotateY() public method

public RotateY ( float rotation ) : void
rotation float
return void

RotateZ() public method

public RotateZ ( float rotation ) : void
rotation float
return void

SetScale() public method

public SetScale ( float newScale ) : void
newScale float
return void

Setup() public method

public Setup ( Vector3 position ) : void
position Vector3
return void

TakeDamage() public method

public TakeDamage ( int damage ) : bool
damage int
return bool

Tower() public method

public Tower ( Model model, Tile tile ) : System
model Microsoft.Xna.Framework.Graphics.Model
tile UHSampleGame.TileSystem.Tile
return System

Tower() public method

public Tower ( TowerType type ) : System
type TowerType
return System

UnregisterAttackTower() public method

public UnregisterAttackTower ( Tower &tower ) : void
tower Tower
return void

UnregisterAttackUnit() public method

public UnregisterAttackUnit ( Unit &unit ) : void
unit UHSampleGame.CoreObjects.Units.Unit
return void

Update() public method

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

UpdateTransforms() public method

public UpdateTransforms ( ) : void
return void

Upgrade() public method

public Upgrade ( int money ) : int
money int
return int

UpgradeCost() public method

public UpgradeCost ( ) : int
return int

ValidateUnitInput() public method

public ValidateUnitInput ( ) : void
return void

XPUpgrade() public method

public XPUpgrade ( ) : void
return void

Property Details

Cost public property

public int Cost
return int

Health public property

public int Health
return int

HealthCapacity public property

public int HealthCapacity
return int

ID public property

public int ID
return int

Level public property

public int Level
return int

LevelString public property

public string LevelString
return string

PlayerNum public property

public int PlayerNum
return int

Position public property

public Vector3 Position
return Vector3

Scale public property

public float Scale
return float

Status public property

public TowerStatus Status
return TowerStatus

TeamNum public property

public int TeamNum
return int

TotalInvestedCost public property

public int TotalInvestedCost
return int

Transforms public property

public Matrix Transforms
return Matrix

Type public property

public TowerType Type
return TowerType

UnitTypeToBuild public property

public UnitType UnitTypeToBuild
return UnitType

XP public property

public int XP
return int

attackStrength public property

public int attackStrength
return int

destroyCost public property

public int destroyCost
return int

repairCost public property

public int repairCost
return int

tile public property

public Tile,UHSampleGame.TileSystem tile
return UHSampleGame.TileSystem.Tile

towerEnumType public static property

public static Enum[],System towerEnumType
return System.Enum[]

towerUpgradeEnumType public static property

public static Enum[],System towerUpgradeEnumType
return System.Enum[]

towersToAttack public property

public List towersToAttack
return List

unitToAttack public property

public Unit unitToAttack
return Unit

upgradeCost public property

public int upgradeCost
return int