CFxBatch Class Reference

Effects. More...

#include <fxBatch.h>

List of all members.

Enum data

enum  eType {
  kFXNone = 0, kFXHole = 1, kFXSpark1, kFXSpark2,
  kFXSmoke, kFXBeam, kFXTracer, kFXMuzzleFlash1,
  kFXMuzzleFlash2, kFXBrassEject1, kFXBrassEject2
}
 FX type enums. More...
static eType string_to_eType (const char *str)
 Get CFxBatch eType from a string value.

Play methods

bool play (const CVector3D &vPos, const CVector3D &vVel) const
 Play all the effects stored in this batch.

Public Member Functions

Create methods
 CFxBatch ()
 CFxBatch (eType type, int num=-1)
Add methods
bool add (eType type, int num=-1)
 Add an FX.
Misc methods
bool is_empty () const
 
Returns:
true if there are no effect(s)

int size () const
 
Returns:
The number of FXs in this batch


Detailed Description

Effects.

Preform one or more effects when played.

(c) 2007-2008 oP group Germany GbR. All rights reserved.
This source code is provided "as is" with no warranty and must not be distributed without written permission.

Author:
Doug Poston
Version:
1.3
Date:
12/28/2007

Member Enumeration Documentation

enum CFxBatch::eType

FX type enums.

Enumerator:
kFXNone  No FX.
kFXHole  Bullet hole drawn at Pos (Vel = facing normal).
kFXSpark1  Create sparks at Pos (Vel = init vel).
kFXSpark2  Second Spark FX .
kFXSmoke  Create smoke at Pos (Vel = init vel).
kFXBeam  Laser beam drawn from Pos along Vel.
kFXTracer  Broken line drawn from Pos along Vel.
kFXMuzzleFlash1  Muzzle flash fx drawn at Pos along Vel.
kFXMuzzleFlash2  Secondary Muzzle flash fx drawn at Pos along Vel.
kFXBrassEject1  Draw spent casings from Pos along Vel.
kFXBrassEject2  Secondary spent casings from Pos along Vel.


Member Function Documentation

CFxBatch::eType CFxBatch::string_to_eType ( const char *  str  )  [static]

Get CFxBatch eType from a string value.

Parameters:
str String containing eType name.
Returns:
eType enum.

bool CFxBatch::add ( eType  type,
int  num = -1 
)

Add an FX.

Parameters:
type Type of effect.
num Number of particles (-1 to use default).
Returns:
true if the FX was added.

bool CFxBatch::play ( const CVector3D vPos,
const CVector3D vVel 
) const

Play all the effects stored in this batch.

Parameters:
vPos Postion vector.
vVel Velocity vector (or length, orientation, color, etc.)
Returns:
false if no effect was played


The documentation for this class was generated from the following files:
Generated on Fri Dec 28 12:55:07 2007 for template7 by  doxygen 1.5.4