stuntrally / stuntrally3

3D racing game with own Track Editor. The main repository with Stunt Rally 3 sources and data. Continuation of Stunt Rally 2.x using Ogre-Next 3.0.
https://stuntrally.tuxfamily.org/
GNU General Public License v3.0
113 stars 7 forks source link

Segmentation fault on startup #4

Closed lrustand closed 1 year ago

lrustand commented 1 year ago

I was able to build it after a lot of trouble, but when starting the game it segfaults in the initial loading screen when loading terrain. The segfault happens on line 543 in src/Terra/Hlms/OgreHlmsTerra.cpp:

constBufferSlot += mAtmosphere->bindConstBuffers( commandBuffer, constBufferSlot );

Core file was too big to upload on github so uploaded it here: https://0x0.st/HKGj.zip

The MyGUI log also shows a missing texture called SX.jpg as the last line of the log.

MyGUI.log Ogre.log

cryham commented 1 year ago

Okay great that you've built it. Do you have set in Ogre/ogre-next/build/CMakeCache.txt these components:

OGRE_BUILD_COMPONENT_ATMOSPHERE:BOOL=ON
...
OGRE_BUILD_COMPONENT_PLANAR_REFLECTIONS:BOOL=ON

Looks like I didn't add this to guide. If not then set both to ON, and it needs to go the long way: rebuild Ogre, then MyGui and lastly SR3. But if you already had ON in both, we have a different issue, not sure yet what.

I have SX here /Media/cars/_previews/SX.jpg, but it's likely not an issue because it also complained about background2.png and didn't fail.

lrustand commented 1 year ago

Ok, great. I had already set the planar reflections to be able to build, but it did not work anyway so I actually had to remove the block of code that used it from SR. I did not rebuild MyGUI after enabling planar reflections so that might be the reason it didn't work the first time.

I will try again with your above instructions.

I also have the file Media/cars/_previews/SX.jpg, so not sure why it didn't find it.

lrustand commented 1 year ago

Thanks, now it worked!

But I was just booted into a test map and am unable to access the menu. When pressing escape the game exits. I realize the game is still in development, but the readme said that it was playable in single player modes. Is this how it is supposed to be at the moment or am I experiencing a bug?

lrustand commented 1 year ago

Ok, never mind. The menu is on tab...

cryham commented 1 year ago

Cool. I'm glad it works.