mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-11-16 17:51:27 +00:00
Merge remote-tracking branch 'refs/remotes/origin/master' into sal-misc
This commit is contained in:
commit
d7bb7734d3
1 changed files with 10 additions and 10 deletions
|
@ -1022,12 +1022,12 @@ void S_UpdateSounds(void)
|
||||||
if (splitscreen)
|
if (splitscreen)
|
||||||
{
|
{
|
||||||
const mobj_t *soundmobj = c->origin;
|
const mobj_t *soundmobj = c->origin;
|
||||||
fixed_t recdist;
|
fixed_t recdist = -1;
|
||||||
INT32 i, p = -1;
|
INT32 i, p = -1;
|
||||||
|
|
||||||
for (i = 0; i < 4; i++)
|
for (i = 0; i < 4; i++)
|
||||||
{
|
{
|
||||||
fixed_t thisdist;
|
fixed_t thisdist = -1;
|
||||||
|
|
||||||
if (i > splitscreen)
|
if (i > splitscreen)
|
||||||
break;
|
break;
|
||||||
|
@ -1043,7 +1043,7 @@ void S_UpdateSounds(void)
|
||||||
else
|
else
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (recdist == NULL || (thisdist != NULL && thisdist < recdist))
|
if (recdist == -1 || (thisdist != -1 && thisdist < recdist))
|
||||||
{
|
{
|
||||||
recdist = thisdist;
|
recdist = thisdist;
|
||||||
p = i;
|
p = i;
|
||||||
|
@ -1052,13 +1052,7 @@ void S_UpdateSounds(void)
|
||||||
|
|
||||||
if (p != -1)
|
if (p != -1)
|
||||||
{
|
{
|
||||||
if (p == 0)
|
if (p == 1)
|
||||||
{
|
|
||||||
// Player 1 gets the sound
|
|
||||||
audible = S_AdjustSoundParams(listenmobj, c->origin, &volume, &sep, &pitch,
|
|
||||||
c->sfxinfo);
|
|
||||||
}
|
|
||||||
else if (p == 1)
|
|
||||||
{
|
{
|
||||||
// Player 2 gets the sound
|
// Player 2 gets the sound
|
||||||
audible = S_AdjustSoundParams(listenmobj2, c->origin, &volume, &sep, &pitch,
|
audible = S_AdjustSoundParams(listenmobj2, c->origin, &volume, &sep, &pitch,
|
||||||
|
@ -1076,6 +1070,12 @@ void S_UpdateSounds(void)
|
||||||
audible = S_AdjustSoundParams(listenmobj4, c->origin, &volume, &sep, &pitch,
|
audible = S_AdjustSoundParams(listenmobj4, c->origin, &volume, &sep, &pitch,
|
||||||
c->sfxinfo);
|
c->sfxinfo);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Player 1 gets the sound
|
||||||
|
audible = S_AdjustSoundParams(listenmobj, c->origin, &volume, &sep, &pitch,
|
||||||
|
c->sfxinfo);
|
||||||
|
}
|
||||||
|
|
||||||
if (audible)
|
if (audible)
|
||||||
I_UpdateSoundParams(c->handle, volume, sep, pitch);
|
I_UpdateSoundParams(c->handle, volume, sep, pitch);
|
||||||
|
|
Loading…
Reference in a new issue