25 inline float randf() {
return (rand()-16384.0f)/32768.0f; }
30 float bspeed,
float dr,
float s,
float bloom,
float dec,
float rate,
31 bool cont,
bool trail,
bool rise,
int a,
int nframes)
32 : nparts(np), base_speed(bspeed), max_speed(bspeed*3.0f),
33 drag(dr), min_scale(s), max_scale(bloom), decay(dec),
34 release_rate(rate), continuous(cont), trailing(trail), rising(rise),
35 blend(a), extra(0.0f), point_sprite(0), emitting(true)
59 for (
int i = 0; i <
nverts; i++) {
118 float scaled_drag = (float) exp(-
drag * seconds);
121 for (
int i = 0; i <
nverts; i++) {
130 scale[i] += scale_inc * (float) ((i%3)/3.0);
133 double rho =
angle[i];
136 case 0: rho += seconds * 0.13;
break;
137 case 1: rho -= seconds * 0.11;
break;
138 case 2: rho += seconds * 0.09;
break;
139 case 3: rho -= seconds * 0.07;
break;
143 angle[i] = (float) rho;
162 int new_parts = (int) (delta +
extra);
169 for (
int i = nv; i <
nverts; i++) {
187 for (
int i = 0; i <
nverts; i++) {
195 angle[i] = (float) (
PI * rand() / 16384.0);
218 float particle_radius = base *
max_scale;
246 for (
int i = 0; i <
nverts; i++) {