Skip to content

fix: don't spatialize local sounds - #447

Open
WofWca wants to merge 1 commit into
ec-:mainfrom
WofWca:fix-local-sound-listener-change
Open

WofWca wants to merge 1 commit into
ec-:mainfrom
WofWca:fix-local-sound-listener-change

Conversation

@WofWca

@WofWca WofWca commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

The comment on trap_S_StartLocalSound
https://github.com/ioquake/ioq3/blob/07b9c1bd83f7d81f3215fddba5fff2edec570912/code/cgame/cg_local.h#L1561-L1562
says:

// a local sound is always played full volume

but this only holds if the listener entity number never changes,
so let's fix it.

I discovered this issue while working on my
KillCam mod,
where we switch the camera between entities quite often.

The comment on `trap_S_StartLocalSound`
https://github.com/ioquake/ioq3/blob/07b9c1bd83f7d81f3215fddba5fff2edec570912/code/cgame/cg_local.h#L1561-L1562
says:
> // a local sound is always played full volume

but this only holds if the listener entity number never changes,
so let's fix it.

I discovered this issue while working on my
[KillCam mod](https://github.com/WofWca/quake3-killcam-mod),
where we switch the camera between entities quite often.
@WofWca
WofWca force-pushed the fix-local-sound-listener-change branch from 8316d78 to 54a0cb7 Compare October 14, 2026 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant