Skip to content

Sound pool should not starve when weapons are fired very rapidly #1523

@Rainyan

Description

@Rainyan

Build Info

be010d2

Description

When very many people are shooting automatic weapons at the same time, we currently sometimes run out of space in the pool for sound allocations. This seems to occur because we don't correctly specify the sound channel for gunfire.

I suspect this bug may also be responsible for the sporadic reports of some specific sound in the map not playing out, where we couldn't figure out a way to reproduce the issue.

To Reproduce

Make a server full of bots, and have them engage in a big gunfight simultaneously:

developer 2; // needed to see the error debug output
neo_bot_quota 32;
map ntre_oilstain_ctg;

Join spectator yourself, and observe the bots while keeping an eye on the console output.

Expected behavior

No errors are printed in the console regarding sound pool starvation.

Actual behavior

Console prints errors:

Could not AllocSound() for InsertSound() (Game DLL)
Free Sound List is full!

Operating System

  • Windows
  • Linux

Version/Distro

11

Additional context and Screenshots

Metadata

Metadata

Assignees

Labels

Bug ReportBug Reports made through the "Report Issue" interface in GitHub.

Type

Projects

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions