C# Class PantheonPrototype.Trigger

An entity designed to trigger and event when another entity collides with it.
Inheritance: Entity
Exibir arquivo Open project: Bacon41/PantheonPrototype

Protected Properties

Property Type Description
active bool
reactivateTime int

Public Methods

Method Description
Load ( Microsoft.Xna.Framework.Content.ContentManager contentManager ) : void
Trigger ( Rectangle locationBox, Pantheon gameReference ) : System

The constructor for a Trigger entity. Note that the bounding box and drawing box are the same since the Trigger will not be drawn. The location is also specified by the location box. The action point is defaultly located in the center of the trigger.

Update ( GameTime gameTime, Pantheon gameReference ) : void
triggerHandler ( Event eventInfo ) : void

The handler for the Trigger which will be registered to an event with the same name as the trigger.

Method Details

Load() public method

public Load ( Microsoft.Xna.Framework.Content.ContentManager contentManager ) : void
contentManager Microsoft.Xna.Framework.Content.ContentManager
return void

Trigger() public method

The constructor for a Trigger entity. Note that the bounding box and drawing box are the same since the Trigger will not be drawn. The location is also specified by the location box. The action point is defaultly located in the center of the trigger.
public Trigger ( Rectangle locationBox, Pantheon gameReference ) : System
locationBox Microsoft.Xna.Framework.Rectangle There is no location box...
gameReference Pantheon
return System

Update() public method

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

triggerHandler() public method

The handler for the Trigger which will be registered to an event with the same name as the trigger.
public triggerHandler ( Event eventInfo ) : void
eventInfo Event The general event information structure.
return void

Property Details

active protected_oe property

Flag indicating if the trigger is active or not.
protected bool active
return bool

reactivateTime protected_oe property

protected int reactivateTime
return int