raylib»Forums
Benjamin Pedersen
46 posts
Mathematician
Sounds loaded after tenth sound crashes on play (raylib 3)

I use Raylib version 3.

Right now, I load 14 sounds in my game, but when playing sounds loaded after number 10, the game crashes. I have tried rearranging sounds and removing long sounds and it seems consistent. Some of the sounds are loaded into arrays.

Is ten the maximum number of loaded sounds? Is there something, I can do without upgrading to Raylib 4 (I am afraid of breaking changes)?

Mārtiņš Možeiko
2559 posts / 2 projects
Sounds loaded after tenth sound crashes on play (raylib 3)
Edited by Mārtiņš Možeiko on

When code crashes what is error message? Is it writing to invalid address, is it dereferencing null pointer, is it dividing by zero, etc..?? In which place it happens? What functions are on callstack? If you enable lower trace level (LOG_TRACE), does it produce extra error messages?

Benjamin Pedersen
46 posts
Mathematician
Sounds loaded after tenth sound crashes on play (raylib 3)

Thanks for replying.

I have tried to call SetTraceLogLevel() with different log levels. The logging printed to the console does not change. It only shows INFO level regardless. No logging message is printed after initialization.

I use tcc for compiling as it was the only thing that worked out of the box for me. I don't know how to get a stack trace on crash and I cannot get debugging to work on the output.

Mārtiņš Možeiko
2559 posts / 2 projects
Sounds loaded after tenth sound crashes on play (raylib 3)
Replying to Benjipede (#25566)

You should really try to get working compiler that is able to produce debug symbols and using a debugger that can run program and provide you call stack with resolved symbols when something crashes. Doing native code development without debugger/symbols is a very hard thing.