C# Class MyGame.CModel

Inheritance: IEvent
Show file Open project: mahmoudbahaa/XNA-Game-project Class Usage Examples

Protected Properties

Property Type Description
events List
modelTransforms Matrix[]
myGame MyGame

Public Methods

Method Description
CModel ( MyGame game, Model Model ) : System
Draw ( GameTime game ) : void

This method renders the current state.

SetModelEffect ( Effect effect, bool CopyEffect ) : void
addEvent ( Event ev ) : void

Add event to the event queue

buildBoundingBox ( ) : Microsoft.Xna.Framework.BoundingBox
buildBoundingSphere ( ) : BoundingSphere
updateBaseWorld ( Vector3 position, Vector3 rotation, Vector3 scale, Matrix baseWorld ) : void

Protected Methods

Method Description
reinitialize ( Model Model ) : void
setEffectParameter ( Effect effect, string paramName, object val ) : void

Private Methods

Method Description
generateTags ( ) : void

Method Details

CModel() public method

public CModel ( MyGame game, Model Model ) : System
game MyGame
Model Microsoft.Xna.Framework.Graphics.Model
return System

Draw() public method

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

SetModelEffect() public method

public SetModelEffect ( Effect effect, bool CopyEffect ) : void
effect Microsoft.Xna.Framework.Graphics.Effect
CopyEffect bool
return void

addEvent() public method

Add event to the event queue
public addEvent ( Event ev ) : void
ev Event Event to be added
return void

buildBoundingBox() public method

public buildBoundingBox ( ) : Microsoft.Xna.Framework.BoundingBox
return Microsoft.Xna.Framework.BoundingBox

buildBoundingSphere() public method

public buildBoundingSphere ( ) : BoundingSphere
return BoundingSphere

reinitialize() protected method

protected reinitialize ( Model Model ) : void
Model Microsoft.Xna.Framework.Graphics.Model
return void

setEffectParameter() protected method

protected setEffectParameter ( Effect effect, string paramName, object val ) : void
effect Microsoft.Xna.Framework.Graphics.Effect
paramName string
val object
return void

updateBaseWorld() public method

public updateBaseWorld ( Vector3 position, Vector3 rotation, Vector3 scale, Matrix baseWorld ) : void
position Vector3
rotation Vector3
scale Vector3
baseWorld Matrix
return void

Property Details

events protected property

protected List events
return List

modelTransforms protected property

protected Matrix[] modelTransforms
return Matrix[]

myGame protected property

protected MyGame,MyGame myGame
return MyGame