[nexuiz-commits] r8290 - trunk/data/qcsrc/server
DONOTREPLY at icculus.org
DONOTREPLY at icculus.org
Mon Nov 16 02:47:47 EST 2009
Author: div0
Date: 2009-11-16 02:47:47 -0500 (Mon, 16 Nov 2009)
New Revision: 8290
Modified:
trunk/data/qcsrc/server/w_tuba.qc
Log:
slightly improved tuba note handling
Modified: trunk/data/qcsrc/server/w_tuba.qc
===================================================================
--- trunk/data/qcsrc/server/w_tuba.qc 2009-11-15 21:04:14 UTC (rev 8289)
+++ trunk/data/qcsrc/server/w_tuba.qc 2009-11-16 07:47:47 UTC (rev 8290)
@@ -85,8 +85,17 @@
void W_Tuba_NoteThink()
{
- self.owner.tuba_note = world;
- remove(self);
+ self.nextthink = time;
+ if(self.owner.origin != self.origin)
+ {
+ setorigin(self, self.owner.origin);
+ self.SendFlags |= 1;
+ }
+ if(time > self.teleport_time)
+ {
+ self.owner.tuba_note = world;
+ remove(self);
+ }
}
void W_Tuba_Attack(float hittype)
@@ -126,15 +135,11 @@
self.tuba_note.owner = self;
self.tuba_note.cnt = n;
self.tuba_note.think = W_Tuba_NoteThink;
+ self.tuba_note.nextthink = time;
Net_LinkEntity(self.tuba_note, FALSE, 0, W_Tuba_NoteSendEntity);
}
- self.tuba_note.nextthink = time + cvar("g_balance_tuba_refire") * 2; // so it can get prolonged safely
- if(self.origin != self.tuba_note.origin)
- {
- setorigin(self.tuba_note, self.origin);
- self.tuba_note.SendFlags |= 1;
- }
+ self.tuba_note.teleport_time = time + cvar("g_balance_tuba_refire") * 2; // so it can get prolonged safely
//sound(self, c, TUBA_NOTE(n), bound(0, VOL_BASE * cvar("g_balance_tuba_volume"), 1), cvar("g_balance_tuba_attenuation"));
RadiusDamage(self, self, cvar("g_balance_tuba_damage"), cvar("g_balance_tuba_edgedamage"), cvar("g_balance_tuba_radius"), world, cvar("g_balance_tuba_force"), hittype | WEP_TUBA, world);
More information about the nexuiz-commits
mailing list