MCPcopy Create free account
hub / github.com/demoth/jake2 / AddParticle

Method AddParticle

fullgame/src/test/java/jake2/fullgame/TestMap.java:467–482  ·  view source on GitHub ↗
(float[] org, int color, float alpha)

Source from the content-addressed store, hash-verified

465 =====================
466 */
467 void AddParticle(float[] org, int color, float alpha) {
468 if (r_numparticles >= Defines.MAX_PARTICLES)
469 return;
470
471 int i = r_numparticles++;
472
473 int c = particle_t.colorTable[color];
474 c |= (int)(alpha * 255) << 24;
475 particle_t.colorArray.put(i, c);
476
477 i *= 3;
478 FloatBuffer vertexBuf = particle_t.vertexArray;
479 vertexBuf.put(i++, org[0]);
480 vertexBuf.put(i++, org[1]);
481 vertexBuf.put(i++, org[2]);
482 }
483}

Callers 1

animateParticlesMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected