diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cgame/cg_buildable.c | 14 | ||||
-rw-r--r-- | src/game/bg_misc.c | 12 |
2 files changed, 14 insertions, 12 deletions
diff --git a/src/cgame/cg_buildable.c b/src/cgame/cg_buildable.c index a931638a..e56e62ec 100644 --- a/src/cgame/cg_buildable.c +++ b/src/cgame/cg_buildable.c @@ -446,6 +446,9 @@ void CG_Buildable( centity_t *cent ) //run animations CG_BuildableAnimation( cent, &ent.oldframe, &ent.frame, &ent.backlerp ); + // add to refresh list + trap_R_AddRefEntityToScene(&ent); + //turret barrel bit if( cg_buildables[ es->modelindex ].models[ 1 ] ) { @@ -455,9 +458,9 @@ void CG_Buildable( centity_t *cent ) memset( &turretBarrel, 0, sizeof( turretBarrel ) ); turretBarrel.hModel = cg_buildables[ es->modelindex ].models[ 1 ]; - VectorCopy( cent->lerpOrigin, turretBarrel.lightingOrigin ); - CG_PositionEntityOnTag( &turretBarrel, &ent, ent.hModel, "tag_turret" ); + CG_PositionRotatedEntityOnTag( &turretBarrel, &ent, ent.hModel, "tag_turret" ); + VectorCopy( cent->lerpOrigin, turretBarrel.lightingOrigin ); AnglesToAxis( es->angles2, flatAxis ); RotatePointAroundVector( turretBarrel.axis[ 0 ], xNormal, flatAxis[ 0 ], -rotAngle ); @@ -484,9 +487,9 @@ void CG_Buildable( centity_t *cent ) swivelAngles[ PITCH ] = 0.0f; turretTop.hModel = cg_buildables[ es->modelindex ].models[ 2 ]; - VectorCopy( cent->lerpOrigin, turretTop.lightingOrigin ); - CG_PositionEntityOnTag( &turretTop, &ent, ent.hModel, "tag_turret" ); + CG_PositionRotatedEntityOnTag( &turretTop, &ent, ent.hModel, "tag_turret" ); + VectorCopy( cent->lerpOrigin, turretTop.lightingOrigin ); AnglesToAxis( swivelAngles, flatAxis ); RotatePointAroundVector( turretTop.axis[ 0 ], xNormal, flatAxis[ 0 ], -rotAngle ); @@ -499,7 +502,4 @@ void CG_Buildable( centity_t *cent ) trap_R_AddRefEntityToScene( &turretTop ); } - - // add to refresh list - trap_R_AddRefEntityToScene(&ent); } diff --git a/src/game/bg_misc.c b/src/game/bg_misc.c index d7925ef2..f497ef82 100644 --- a/src/game/bg_misc.c +++ b/src/game/bg_misc.c @@ -1288,8 +1288,8 @@ buildableAttributes_t bg_buildableList[ ] = "booster", //char *buildName; "team_droid_booster", //char *entityName; { "models/buildables/booster/booster.md3", 0, 0, 0 }, - { -15, -15, -15 }, //vec3_t mins; - { 15, 15, 15 }, //vec3_t maxs; + { -26, -26, -9 }, //vec3_t mins; + { 26, 26, 9 }, //vec3_t maxs; TR_GRAVITY, //trType_t traj; 0.0, //float bounce; 80, //int buildPoints; @@ -1483,9 +1483,11 @@ buildableAttributes_t bg_buildableList[ ] = BA_H_DEF2, //int buildNum; "mgturret", //char *buildName; "team_human_def2", //char *entityName; - { "models/buildables/mgturret/turret_base.md3", "models/buildables/mgturret/turret_barrel.md3", "models/buildables/mgturret/turret_top.md3", 0 }, - { -24, -24, -11 }, //vec3_t mins; - { 24, 24, 11 }, //vec3_t maxs; + { "models/buildables/mgturret/turret_base.md3", + "models/buildables/mgturret/turret_barrel.md3", + "models/buildables/mgturret/turret_top.md3", 0 }, + { -36, -36, -30 }, //vec3_t mins; + { 36, 36, 30 }, //vec3_t maxs; TR_GRAVITY, //trType_t traj; 0.0, //float bounce; 80, //int buildPoints; |