This clears out about 56MB of unused audio files.
There were also some unused methods in the audio modules which
referenced a file, which has also been removed.
This adds the entity's velocity as an argument when mapping the
movement state to an SFX event, and prevents the run SFX from being
returned if the velocity is below a threshold.
This will prevent hearing the run sfx when stuck in a corner, or running
into a surface where the character is not actually moving their feet.
Implements a potential structure for splitting the SFX event mapping
into smaller individual files for maintainability.
- Remove inventory events for now: For a later commit.
- No longer panic when there is a failure parsing the sfx file: log the error and not play sfx.
- Updated title music with a version provided by aeronic which fades out
more gracefully
- Removed attack SFX as it was included in the movement processing, but
will return later as part of a similar chunk of code which processes
combat sfx independent of movement.
This was failing to trigger since we now have a MovementState::Fall, but
the sfx mapper was still trying to work this out itself based on
velocity. We no longer need to track velocity as a result and can use
the MovementState.
Also silenced warnings resulting from unused vars when running tests.
This is an event based approach to SFX sounds. There is a specific
character sound event mapper which determines sfx to play based on
character or NPC state, as well as emitting sfx events for
non-character-triggers such as levelling up.
This uses a more recent version of cpal (a dependency of rodio hence the
rodio change) which seems to have fixed a crash due to
'device not available: "Invalid argument"' coming from Alsa.
The change in cpal also made some functions now return `Result` instead
of a bare type which I dealt with by using `expect` to minimize how far
these changes fan out into the code but maybe this isn't ideal.
Fixing https://gitlab.com/veloren/veloren/issues/280 - Crash with ALSA