-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
segmentation fault on startup #22
Comments
It could be that the config file has corrupted, which would cause a crash. The config file can be found in: ~/.local/share/blobwarsAttrition/config.json That should be valid JSON. Try renaming it and restarting the game (which will effectively reset your configuration). If that works, it means your config was busted. Attach the file in a comment and I'll take a look (or you could see if you could fix it manually). If that doesn't work, try running through gdb. This should show you a stacktrace of where the crash occurs. gdb blobwarsAttrition |
yes, that file was empty - 0 bytes long. having deleted the empty file blobwarsAttrition starts. beachFront1.json boss1.json game.json and greenlands5.json are all 0 bytes |
You shouldn't have any zero length files in there, at all. Sounds like the game isn't saving correctly for some reason. You could delete them, yes. But it will put the game into an inconsistent state where you'll find you end up with more keys than you should do; it will basically make your playthrough too easy. Did you compile the game yourself? Or are you using the version from itch.io? Edit: a bit more info - those files are used to store the level state, for the purpose of creating a persistent game world. Deleting them will basically reset the level as if it's being visited for the first time. |
ok, so it looks like it is safe to delete. my son is playing it and he quit out of a few levels (esc) because he got stuck (he needs more patience :-) ). I compiled it myself, using the source+data from itch.io Slackware build script for blobwarsAttritionWritten by Tim Dickson dickson.tim@googlemail.com(C) 2019changelogPRGNAM=blobwarsAttrition if [ -z "$ARCH" ]; then CWD=$(pwd) if [ "$ARCH" = "i586" ]; then set -e make CFLAGS="$SLKCFLAGS" DATA_DIR="/usr/share/games/$PRGNAM" find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cd $PKG |
(appologies for the weird formatting github put on my pasted text) |
I'm not having any luck duplicating this error. Something you could try: backup or delete the ~/.local/share/blobwarsAttrition directory and start a new game using: blobwarsAttrition -debug When playing, you'll see debug stuff on screen, but you can also press 0 on the keyboard to automatically complete a mission. Do this on a few stages and then check to see that the save files are being created properly. If they're all still 0 in size then we'll need to do more digging. The saving is done by first creating temporary files and then renaming them, in order to try and keep things in sync. This is done here: https://github.com/stephenjsweeney/blobwarsAttrition/blob/master/src/hub/postMission.c#L91 The main level saving is done here: https://github.com/stephenjsweeney/blobwarsAttrition/blob/master/src/world/worldSaver.c#L30 Perhaps more debug and error checking will be needed? |
it seems to be saving ok. I tried completing a level in debug mode as well as "0" completing, and tried quitting the program (x) in corner, also tried kill -9 gamepid but no zero-length files. I'll have to see if my son can remember what he did when it "went wrong". |
apparently it happened after he died on grasslands5, or whengrasslands5 was completed. Unfortunately it's not much to go on. I'll close this, and if it re-occurs open a fresh issue hopefully with more info. |
running from a kterminal gives the following output.
neil@timhome:~$ blobwarsAttrition
INFO: Locale is en_US
INFO: Language is en
INFO: Numeric is C
INFO: atof(2.75) is 2.750000
INFO: User home = /home/neil
Segmentation fault
it was working, (but not fullscreen and full resolution of 1920x1080).
I changed the screen resolution and selected fullscreen and restarted, but it didn't restart, it gave the above output.
(running 64bit linux (slackware 14.2) (with paid-for data) Any suggestions to debug?
glxgears -info shows running gl version 3.0 Mesa 11.2.2
SDL2 2.0.9 SDL2_image 2.0.4 SDL2_mixer 2.0.4 and SDL2_ttf 2.0.14
The text was updated successfully, but these errors were encountered: