summaryrefslogtreecommitdiff
path: root/src/cgame
diff options
context:
space:
mode:
authorTim Angus <tim@ngus.net>2003-08-30 18:49:40 +0000
committerTim Angus <tim@ngus.net>2003-08-30 18:49:40 +0000
commit703dcc641a188c128dc5acb7bfc6d7b8333bdd35 (patch)
treec8a7d119bd82a9ee4b31c7e8eeb3109223e90f02 /src/cgame
parent5ede5ba58b780c817941eff29617056d599a9ba8 (diff)
* Poison kills are now properly credited
* Buildable weapons now have their effects properly applied
Diffstat (limited to 'src/cgame')
-rw-r--r--src/cgame/cg_buildable.c22
-rw-r--r--src/cgame/cg_event.c16
2 files changed, 27 insertions, 11 deletions
diff --git a/src/cgame/cg_buildable.c b/src/cgame/cg_buildable.c
index c34561d1..00c7bf68 100644
--- a/src/cgame/cg_buildable.c
+++ b/src/cgame/cg_buildable.c
@@ -932,15 +932,27 @@ void CG_Buildable( centity_t *cent )
break;
}
- if( cg.time - cent->muzzleFlashTime > MUZZLE_FLASH_TIME && es->eFlags & EF_FIRING )
+ //weapon effects for turrets
+ if( es->eFlags & EF_FIRING )
{
weaponInfo_t *weapon = &cg_weapons[ es->weapon ];
-
- if( weapon->flashDlightColor[ 0 ] || weapon->flashDlightColor[ 1 ] || weapon->flashDlightColor[ 2 ] )
+
+ if( cg.time - cent->muzzleFlashTime > MUZZLE_FLASH_TIME ||
+ BG_FindProjTypeForBuildable( es->modelindex ) == WP_TESLAGEN )
+ {
+ if( weapon->flashDlightColor[ 0 ] || weapon->flashDlightColor[ 1 ] || weapon->flashDlightColor[ 2 ] )
+ {
+ trap_R_AddLightToScene( cent->lerpOrigin, 300 + ( rand( ) & 31 ), weapon->flashDlightColor[ 0 ],
+ weapon->flashDlightColor[ 1 ], weapon->flashDlightColor[ 2 ] );
+ }
+ }
+
+ if( weapon->firingSound )
{
- trap_R_AddLightToScene( cent->lerpOrigin, 300 + ( rand( ) & 31 ), weapon->flashDlightColor[ 0 ],
- weapon->flashDlightColor[ 1 ], weapon->flashDlightColor[ 2 ] );
+ trap_S_AddLoopingSound( es->number, cent->lerpOrigin, vec3_origin, weapon->firingSound );
}
+ else if( weapon->readySound )
+ trap_S_AddLoopingSound( es->number, cent->lerpOrigin, vec3_origin, weapon->readySound );
}
//smoke etc for damaged buildables
diff --git a/src/cgame/cg_event.c b/src/cgame/cg_event.c
index 87f10a8d..7d8f38c5 100644
--- a/src/cgame/cg_event.c
+++ b/src/cgame/cg_event.c
@@ -111,12 +111,6 @@ static void CG_Obituary( entityState_t *ent )
case MOD_SLOWBLOB:
message = "should have visited a medical station";
break;
- case MOD_POISON:
- message = "should have remembered the antitox";
- break;
- case MOD_HYDRA_PCLOUD: //FIXME
- message = "was gassed by a hydra";
- break;
default:
message = NULL;
break;
@@ -258,6 +252,16 @@ static void CG_Obituary( entityState_t *ent )
message2 = "'s big mofo";
break;
+ case MOD_POISON:
+ message = "should have used antitox against";
+ message2 = "'s poison";
+ break;
+ case MOD_HYDRA_PCLOUD:
+ message = "was gassed by";
+ message2 = "'s hydra";
+ break;
+
+
case MOD_TELEFRAG:
message = "tried to invade";
message2 = "'s personal space";