Vegastrike 0.5.1 rc1
1.0
Original sources for Vegastrike Evolved
|
#include <mesh.h>
Public Member Functions | |
MeshFX () | |
MeshFX (const float TTL, const float delta, const bool enabled, const GFXColor &vect, const GFXColor &diffuse=GFXColor(0, 0, 0, 1), const GFXColor &specular=GFXColor(0, 0, 0, 1), const GFXColor &ambient=GFXColor(0, 0, 0, 1), const GFXColor &attenuate=GFXColor(1, 0, 0)) | |
Makes a meshFX given TTL and delta values. More... | |
void | MergeLights (const MeshFX &other) |
Merges two MeshFX in a given way to seamlessly blend multiple hits on a shield. More... | |
bool | Update (float ttime) |
updates the growth and death of the FX. Returns false if dead More... | |
![]() | |
GFXLight () | |
GFXLight (const bool enabled, const GFXColor &vect, const GFXColor &diffuse=GFXColor(0, 0, 0, 1), const GFXColor &specular=GFXColor(0, 0, 0, 1), const GFXColor &ambient=GFXColor(0, 0, 0, 1), const GFXColor &attenuate=GFXColor(1, 0, 0), const GFXColor &direction=GFXColor(0, 0, 0), float exp=0.0f, float cutoff=180.0f, float size=0.0f) | |
void | SetProperties (enum LIGHT_TARGET, const GFXColor &color) |
GFXColor | GetProperties (enum LIGHT_TARGET) const |
void | setSize (float size_) |
float | getSize () const |
Vector | getPosition () const |
void | disable () |
void | enable () |
bool | attenuated () const |
void | apply_attenuate (bool attenuated) |
Public Attributes | |
float | delta |
The ammt of change that such meshFX objects attenuation get. More... | |
float | TTL |
The Time to live of the current light effect. More... | |
float | TTD |
After it has achieved its time to live max it has to slowly fade out and die. More... | |
![]() | |
int | target |
physical GL light its saved in More... | |
float | vect [3] |
last is w for positional, otherwise 3 for spec More... | |
int | options |
float | diffuse [4] |
float | specular [4] |
float | ambient [4] |
float | attenuate [3] |
float | direction [3] |
float | exp |
float | cutoff |
float | size |
Mesh FX stores various lights that light up shield or hull for damage They may be merged and they grow and shring based on their TTL and TTD and delta values They must be updated every frame or every physics frame if not drawn (pass in time
|
inline |
MeshFX::MeshFX | ( | const float | TTL, |
const float | delta, | ||
const bool | enabled, | ||
const GFXColor & | vect, | ||
const GFXColor & | diffuse = GFXColor( 0, 0, 0, 1 ) , |
||
const GFXColor & | specular = GFXColor( 0, 0, 0, 1 ) , |
||
const GFXColor & | ambient = GFXColor( 0, 0, 0, 1 ) , |
||
const GFXColor & | attenuate = GFXColor( 1, 0, 0 ) |
||
) |
void MeshFX::MergeLights | ( | const MeshFX & | other) |
Merges two MeshFX in a given way to seamlessly blend multiple hits on a shield.
Definition at line 29 of file mesh_fx.cpp.
References GFXLight::ambient, AvLights(), delta, GFXLight::diffuse, GFXLight::options, GFXLight::specular, TTD, TTL, GFXLight::vect, and Vector.
updates the growth and death of the FX. Returns false if dead
Definition at line 64 of file mesh_fx.cpp.
References GFXLight::attenuate, delta, TTD, and TTL.
float MeshFX::delta |
The ammt of change that such meshFX objects attenuation get.
Definition at line 65 of file mesh.h.
Referenced by MergeLights(), MeshFX(), and Update().
float MeshFX::TTD |
After it has achieved its time to live max it has to slowly fade out and die.
Definition at line 69 of file mesh.h.
Referenced by MergeLights(), MeshFX(), and Update().
float MeshFX::TTL |
The Time to live of the current light effect.
Definition at line 67 of file mesh.h.
Referenced by MergeLights(), MeshFX(), and Update().