Skip to content

Use a special version of W_GetNumForName for S_GetMusicLumpNum

Music lumps should not crash the game when they aren't found by the game, since its normal behavior for missing music files to just cause a console error, but continue execution. On rare occasions, W_GetNumForName can fail to find a music lump, in which case it causes a crash. By creating a special version of the W_GetNumForName function for music, we should avoid music related crashes and allow S_LoadMusic to properly handle LUMPERRORS in all cases.

The branch name DOES say "prevent shop bug", but in reality I found 2 different issues happening around this time, so this only fixes one of the two crashes.

Merge request reports

Loading