This fixes #814 : loading a PRJ2 was discarding any texture sound ID above 15.
This PR "raises the limit", and also de-hardcodes it by referring to the enum's length instead.
However I'm not sure if it's ok to de-hardcode: I don't know anything about chunks, so I'm not sure why this check was added in the beginning, maybe there's something I'm not seeing.
Just in case de-hardcoding is a bad idea, I first commited the "limit raise" from 15 to 22, then I commited the de-harcoding (so you can still cherry-pick the 1st one).
This fixes #814 : loading a PRJ2 was discarding any texture sound ID above 15.
This PR "raises the limit", and also de-hardcodes it by referring to the enum's length instead. However I'm not sure if it's ok to de-hardcode: I don't know anything about chunks, so I'm not sure why this check was added in the beginning, maybe there's something I'm not seeing.
Just in case de-hardcoding is a bad idea, I first commited the "limit raise" from 15 to 22, then I commited the de-harcoding (so you can still cherry-pick the 1st one).