mirror of
https://github.com/UberGames/ioef.git
synced 2024-11-23 20:52:54 +00:00
Fix weapon barrel angle on Gauntlet and BFG items in Team Arena
The barrels were rotated 90 degrees from what they should be. Used barrel code from CG_AddPlayerWeapon to fix them.
This commit is contained in:
parent
424122c366
commit
b0561e5fb4
1 changed files with 6 additions and 1 deletions
|
@ -352,6 +352,7 @@ static void CG_Item( centity_t *cent ) {
|
|||
#ifdef MISSIONPACK
|
||||
if ( item->giType == IT_WEAPON && wi && wi->barrelModel ) {
|
||||
refEntity_t barrel;
|
||||
vec3_t angles;
|
||||
|
||||
memset( &barrel, 0, sizeof( barrel ) );
|
||||
|
||||
|
@ -361,9 +362,13 @@ static void CG_Item( centity_t *cent ) {
|
|||
barrel.shadowPlane = ent.shadowPlane;
|
||||
barrel.renderfx = ent.renderfx;
|
||||
|
||||
angles[YAW] = 0;
|
||||
angles[PITCH] = 0;
|
||||
angles[ROLL] = 0;
|
||||
AnglesToAxis( angles, barrel.axis );
|
||||
|
||||
CG_PositionRotatedEntityOnTag( &barrel, &ent, wi->weaponModel, "tag_barrel" );
|
||||
|
||||
AxisCopy( ent.axis, barrel.axis );
|
||||
barrel.nonNormalizedAxes = ent.nonNormalizedAxes;
|
||||
|
||||
trap_R_AddRefEntityToScene( &barrel );
|
||||
|
|
Loading…
Reference in a new issue