C# Class MyGame.CDrawableComponent

This class represent a custom Drawable Component that has a CModel that handle drawing and a Unit that hanlde updating of the Drawable game component.
Inheritance: Microsoft.Xna.Framework.DrawableGameComponent
Mostra file Open project: mahmoudbahaa/XNA-Game-project

Public Properties

Property Type Description
cModel CModel
unit Unit

Protected Properties

Property Type Description
myGame MyGame

Public Methods

Method Description
CDrawableComponent ( MyGame game, Unit unit, CModel model ) : System
Draw ( GameTime gameTime ) : void

This method renders the current state.

Update ( GameTime gameTime ) : void

Allows the game component to update itself.

Method Details

CDrawableComponent() public method

public CDrawableComponent ( MyGame game, Unit unit, CModel model ) : System
game MyGame
unit Unit
model CModel
return System

Draw() public method

This method renders the current state.
public Draw ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime The elapsed game time.
return void

Update() public method

Allows the game component to update itself.
public Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime Provides a snapshot of timing values.
return void

Property Details

cModel public_oe property

public CModel,MyGame cModel
return CModel

myGame protected_oe property

protected MyGame,MyGame myGame
return MyGame

unit public_oe property

public Unit,MyGame unit
return Unit