mirror of
https://github.com/nzp-team/glquake.git
synced 2025-02-07 16:31:25 +00:00
Major particle overhaul/fixes
This commit is contained in:
parent
1c38cda5aa
commit
d6aefb4aa2
5 changed files with 173 additions and 670 deletions
|
@ -555,7 +555,7 @@ void HUD_MaxAmmo(void)
|
|||
maxammoy -= cl.time * 0.003;
|
||||
maxammoopac -= 5;
|
||||
|
||||
Draw_ColoredString(vid.width/2 - strlen("MAX AMMO!")*2, maxammoy, "MAX AMMO!", 255, 255, 255, maxammoopac, 1);
|
||||
Draw_ColoredString(vid.width/2 - strlen("MAX AMMO!")/2, maxammoy, "MAX AMMO!", 255, 255, 255, maxammoopac, 1);
|
||||
|
||||
if (maxammoopac <= 0) {
|
||||
domaxammo = false;
|
||||
|
|
|
@ -604,7 +604,7 @@ void CL_RelinkEntities (void)
|
|||
|
||||
AngleVectors (tempangles, v_forward, v_right, v_up);
|
||||
VectorCopy (cl_entities[cl.viewentity].origin, smokeorg);
|
||||
smokeorg[2] += 32;
|
||||
smokeorg[2] += cl.viewheight;
|
||||
VectorCopy(smokeorg,start);
|
||||
|
||||
right_offset = sv_player->v.Flash_Offset[0];
|
||||
|
@ -619,12 +619,7 @@ void CL_RelinkEntities (void)
|
|||
VectorMA (smokeorg, up_offset, v_up ,smokeorg);
|
||||
VectorMA (smokeorg, right_offset, v_right ,smokeorg);
|
||||
VectorAdd(smokeorg,CWeaponOffset,smokeorg);
|
||||
|
||||
if (sv_player->v.weapon != W_RAY && sv_player->v.weapon != W_PORTER) {
|
||||
QMB_MuzzleFlash (smokeorg);
|
||||
} else {
|
||||
QMB_RayFlash(smokeorg, sv_player->v.weapon);
|
||||
}
|
||||
QMB_MuzzleFlash (smokeorg);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -729,7 +724,7 @@ void CL_RelinkEntities (void)
|
|||
|
||||
if (ent->effects & EF_RAYGREEN)
|
||||
{
|
||||
R_RocketTrail (oldorg, ent->origin, 12);
|
||||
QMB_RocketTrail(oldorg, ent->origin, RAYGREEN_TRAIL);
|
||||
dl = CL_AllocDlight (i);
|
||||
VectorCopy (ent->origin, dl->origin);
|
||||
dl->radius = 25;
|
||||
|
@ -742,7 +737,7 @@ void CL_RelinkEntities (void)
|
|||
|
||||
if (ent->effects & EF_RAYRED)
|
||||
{
|
||||
R_RocketTrail (oldorg, ent->origin, 13);
|
||||
QMB_RocketTrail(oldorg, ent->origin, RAYRED_TRAIL);
|
||||
dl = CL_AllocDlight (i);
|
||||
VectorCopy (ent->origin, dl->origin);
|
||||
dl->radius = 25;
|
||||
|
|
816
source/gl_qmb.c
816
source/gl_qmb.c
File diff suppressed because it is too large
Load diff
|
@ -346,7 +346,6 @@ void QMB_DrawParticles (void);
|
|||
void QMB_Q3TorchFlame (vec3_t org, float size);
|
||||
void QMB_RunParticleEffect (vec3_t org, vec3_t dir, int color, int count);
|
||||
void QMB_RocketTrail (vec3_t start, vec3_t end, trail_type_t type);
|
||||
void QMB_RayFlash (vec3_t org, float weapon);
|
||||
void QMB_BlobExplosion (vec3_t org);
|
||||
void QMB_ParticleExplosion (vec3_t org);
|
||||
void QMB_LavaSplash (vec3_t org);
|
||||
|
|
|
@ -63,8 +63,7 @@ void R_InitParticles (void)
|
|||
particles = (particle_t *)
|
||||
Hunk_AllocName (r_numparticles * sizeof(particle_t), "particles");
|
||||
|
||||
// naievil -- particles are not drawn correctly, making it look bad
|
||||
//QMB_InitParticles();
|
||||
QMB_InitParticles();
|
||||
}
|
||||
|
||||
void R_DarkFieldParticles (entity_t *ent)
|
||||
|
@ -405,7 +404,7 @@ R_RunParticleEffect
|
|||
===============
|
||||
*/
|
||||
|
||||
#define RunParticleEffect(var, org, dir, color, count) \
|
||||
#define RunParticleEffect(org, dir, color, count) \
|
||||
if (qmb_initialized) \
|
||||
QMB_RunParticleEffect (org, dir, color, count); \
|
||||
else \
|
||||
|
@ -415,7 +414,7 @@ void R_RunParticleEffect (vec3_t org, vec3_t dir, int color, int count)
|
|||
{
|
||||
if (color == 73 || color == 225)
|
||||
{
|
||||
RunParticleEffect(/*blood*/0, org, dir, color, count);
|
||||
RunParticleEffect(org, dir, color, count);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -424,10 +423,10 @@ void R_RunParticleEffect (vec3_t org, vec3_t dir, int color, int count)
|
|||
case 10:
|
||||
case 20:
|
||||
case 30:
|
||||
RunParticleEffect(/*sparks*/0, org, dir, color, count);
|
||||
RunParticleEffect(org, dir, color, count);
|
||||
break;
|
||||
default:
|
||||
RunParticleEffect(/*gunshots*/0, org, dir, color, count);
|
||||
RunParticleEffect(org, dir, color, count);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue