}
if(!self.silent)
- sound(self, CHAN_PAIN, strcat("misc/gib_splat0", ftos(floor(prandom() * 4 + 1)), ".wav"), VOL_BASE, ATTN_NORM);
+ sound(self, CH_PAIN, strcat("misc/gib_splat0", ftos(floor(prandom() * 4 + 1)), ".wav"), VOL_BASE, ATTN_NORM);
pointparticles(particleeffectnum(strcat(species_prefix(self.cnt), "blood")), self.origin + '0 0 1', '0 0 30', 10);
Gib_Delete();
{
case 0x01:
if(!issilent)
- sound (self, CHAN_PAIN, "misc/gib.wav", VOL_BASE, ATTN_NORM);
+ sound (self, CH_PAIN, "misc/gib.wav", VOL_BASE, ATTN_NORM);
if(prandom() < amount)
TossGib ("models/gibs/eye.md3", org, vel, prandomvec() * 150, specnum, 0, issilent);
if(alarm1time < time)
{
alarm1time = time + 2;
- sound(world, CHAN_PAIN, "vehicles/alarm.wav", VOL_BASEVOICE, ATTN_NONE);
+ sound(world, CH_PAIN, "vehicles/alarm.wav", VOL_BASEVOICE, ATTN_NONE);
}
drawpic(hudloc + picloc, hud_hp_ico, picsize, '1 0 0' + '0 1 1' * sin(time * 8), 1, DRAWFLAG_NORMAL);
}
drawpic(hudloc + picloc, hud_hp_ico, picsize, '1 1 1', 1, DRAWFLAG_NORMAL);
if(alarm1time)
{
- sound(world, CHAN_PAIN, "misc/null.wav", VOL_BASEVOICE, ATTN_NONE);
+ sound(world, CH_PAIN, "misc/null.wav", VOL_BASEVOICE, ATTN_NONE);
alarm1time = 0;
}
}
if(alarm1time < time)
{
alarm1time = time + 2;
- sound(self, CHAN_PAIN, "vehicles/alarm.wav", VOL_BASEVOICE, ATTN_NONE);
+ sound(self, CH_PAIN_SINGLE, "vehicles/alarm.wav", VOL_BASEVOICE, ATTN_NONE);
}
drawpic(hudloc + picloc, hud_hp_ico, picsize, '1 0 0' + '0 1 1' * sin(time * 8), 1, DRAWFLAG_NORMAL);
drawpic(hudloc + picloc, hud_hp_ico, picsize, '1 1 1', 1, DRAWFLAG_NORMAL);
if(alarm1time)
{
- sound(self, CHAN_PAIN, "misc/null.wav", VOL_BASEVOICE, ATTN_NONE);
+ sound(self, CH_PAIN_SINGLE, "misc/null.wav", VOL_BASEVOICE, ATTN_NONE);
alarm1time = 0;
}
}
if(alarm1time < time)
{
alarm1time = time + 2;
- sound(self, CHAN_PAIN, "vehicles/alarm.wav", VOL_BASEVOICE, ATTN_NONE);
+ sound(self, CH_PAIN_SINGLE, "vehicles/alarm.wav", VOL_BASEVOICE, ATTN_NONE);
}
drawpic(hudloc + picloc, hud_hp_ico, picsize, '1 0 0' + '0 1 1' * sin(time * 8), 1, DRAWFLAG_NORMAL);
drawpic(hudloc + picloc, hud_hp_ico, picsize, '1 1 1', 1, DRAWFLAG_NORMAL);
if(alarm1time)
{
- sound(self, CHAN_PAIN, "misc/null.wav", VOL_BASEVOICE, ATTN_NONE);
+ sound(self, CH_PAIN_SINGLE, "misc/null.wav", VOL_BASEVOICE, ATTN_NONE);
alarm1time = 0;
}
}
float CH_SHOTS_SINGLE = 4; // only on players, entities, csqc
float CH_WEAPON_B = 5; // only on players and entities
float CH_PAIN = 6; // only on players and csqc
+float CH_PAIN_SINGLE = 6; // only on players and csqc
float CH_PLAYER = 7; // only on players and entities
+float CH_TRIGGER2_SINGLE = 6; // only on entities
#else
float CH_INFO = 0;
-float CH_TRIGGER_SINGLE = 3;
-float CH_SHOTS_SINGLE = 4;
float CH_TRIGGER = 256;
float CH_WEAPON_A = 257;
float CH_VOICE = 258;
float CH_BGM = 260;
+float CH_TRIGGER_SINGLE = 3;
+float CH_SHOTS_SINGLE = 4;
float CH_WEAPON_B = 257;
float CH_PAIN = 262;
+float CH_PAIN_SINGLE = 6;
float CH_PLAYER = 263;
+float CH_TRIGGER2_SINGLE = 16;
#endif
// this assignment must match menu/xonotic/dialog_settings_misc.c!
self.team = self.team_saved;
if(self.flags & FL_PROJECTILE) // remove any projectiles left
- {
- stopsound(self, CHAN_PAIN);
remove(self);
- }
}
// Waypoints and assault start come LAST
// exclude pain sounds for laserjumps as long as you aren't REALLY low on health and would die of the next two
{
if(deathtype == DEATH_FALL)
- PlayerSound(playersound_fall, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_fall, CH_PAIN, VOICETYPE_PLAYERSOUND);
else if(self.health > 75) // TODO make a "gentle" version?
- PlayerSound(playersound_pain100, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_pain100, CH_PAIN, VOICETYPE_PLAYERSOUND);
else if(self.health > 50)
- PlayerSound(playersound_pain75, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_pain75, CH_PAIN, VOICETYPE_PLAYERSOUND);
else if(self.health > 25)
- PlayerSound(playersound_pain50, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_pain50, CH_PAIN, VOICETYPE_PLAYERSOUND);
else
- PlayerSound(playersound_pain25, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_pain25, CH_PAIN, VOICETYPE_PLAYERSOUND);
}
}
if(sound_allowed(MSG_BROADCAST, attacker))
{
if(deathtype == DEATH_DROWN)
- PlayerSound(playersound_drown, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_drown, CH_PAIN, VOICETYPE_PLAYERSOUND);
else
- PlayerSound(playersound_death, CHAN_PAIN, VOICETYPE_PLAYERSOUND);
+ PlayerSound(playersound_death, CH_PAIN, VOICETYPE_PLAYERSOUND);
}
// get rid of kill indicator
pointparticles(particleeffectnum("electricity_sparks"), self.origin + randompos('-10 -10 -20', '10 10 20'), '0 0 0', 1);
if(random() > 0.8)
- sound(self, CHAN_PAIN, "onslaught/ons_spark1.wav", VOL_BASE, ATTN_NORM);
+ sound(self, CH_PAIN, "onslaught/ons_spark1.wav", VOL_BASE, ATTN_NORM);
else if (random() > 0.5)
- sound(self, CHAN_PAIN, "onslaught/ons_spark2.wav", VOL_BASE, ATTN_NORM);
+ sound(self, CH_PAIN, "onslaught/ons_spark2.wav", VOL_BASE, ATTN_NORM);
}
};
{
//self.sounds = 2;
self.strength_finished = time + 10.922667; //soundlength("vehicles/racer_boost.wav");
- sound (self, CHAN_PAIN, "vehicles/racer_boost.wav", VOL_VEHICLEENGINE, ATTN_NORM);
+ sound (self, CH_TRIGGER2_SINGLE, "vehicles/racer_boost.wav", VOL_VEHICLEENGINE, ATTN_NORM);
}
}
else
{
self.strength_finished = 0;
- sound (self, CHAN_PAIN, "misc/null.wav", VOL_VEHICLEENGINE, ATTN_NORM);
+ sound (self, CH_TRIGGER2_SINGLE, "misc/null.wav", VOL_VEHICLEENGINE, ATTN_NORM);
}
self.think = racer_think;
self.nextthink = time;
self.movetype = MOVETYPE_TOSS;
- sound (self, CHAN_PAIN, "misc/null.wav", VOL_VEHICLEENGINE, ATTN_NORM);
+ sound (self, CH_TRIGGER2_SINGLE, "misc/null.wav", VOL_VEHICLEENGINE, ATTN_NORM);
if not (self.owner)
return;
setsize(proj, '0 0 -3', '0 0 -3');
proj.flags = FL_PROJECTILE;
- //sound (proj, CHAN_PAIN, "weapons/electro_fly.wav", VOL_BASE, ATTN_NORM);
- //sounds bad
-
CSQCProjectile(proj, TRUE, PROJECTILE_ELECTRO_BEAM, TRUE);
other = proj; MUTATOR_CALLHOOK(EditProjectile);