Author Topic: System-Freeze when exiting game (osx)  (Read 2141 times)

Offline Conir

  • Newbie Mark II
  • *
  • Posts: 18
System-Freeze when exiting game (osx)
« on: October 16, 2013, 09:30:09 pm »
Hey,

i have an quite annoying problem when exiting the game, my mac just freezes and doesnt respond to any input. i have to manuall reboot the system. this happens when i try to quit from the games main-menu and also with the option "quit to operating system" from the pause-menu. any idea what the problem might be?

some info:
- playing via steam
- all expansions installed
- fullscreen mode
- anything else relevant?

my specs:
2,7 GHz Intel Core i7
8 GB 1333 MHz DDR3
Intel HD Graphics 3000 512 MB
Mac OS X Lion 10.7.5


Game runs fine and everything works flawless - exept when exiting :(

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: System-Freeze when exiting game (osx)
« Reply #1 on: October 18, 2013, 07:23:50 am »
Hmmm... this is a new one on me. There really isn't much of anything going on in our code when the game exits, unfortunately. We literally call one line of code in the unity engine, telling to to exit, and boom it does it.

It may be that something in how it is shutting down in an orderly fashion just isn't working right. So you could do a hard kill from the OS, is the only thing I can think of. Cmd+Q, or cmd+tab back to the desktop and kill it in the dock.  Or you could quickly switch to windowed mode and then kill it, and surely that would not lock anything.

All of those are just workarounds, I realize, but I really can't think of anything else. This is a new one to me after three years of the game being on OSX, and so it seems like some other software or driver on your specific system might be conflicting with the unity 3d engine. I'm just not sure what that would be.

Hope that helps!
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Charlie

  • Newbie
  • *
  • Posts: 1
Re: System-Freeze when exiting game (osx)
« Reply #2 on: October 25, 2013, 05:17:29 am »
I've been having the same issue on OSX, so it's not just the OP. Will try the workaround though!

Offline Sounds

  • Full Member Mark II
  • ***
  • Posts: 193
Re: System-Freeze when exiting game (osx)
« Reply #3 on: November 27, 2013, 10:59:36 am »
I've been having the same issue on OSX, so it's not just the OP. Will try the workaround though!
Same here. This used to happen very infrequently, so I put it down to having too many other apps running.

However lately it happens quite regularly, in fact I just saved the game and hit quit a moment ago and it  would not quit. Cmd tab, Cmd q, etc failed to work too, so I had to again reboot the machine. Is there any way to help debug this issue?

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: System-Freeze when exiting game (osx)
« Reply #4 on: November 27, 2013, 11:22:51 am »
Unfortunately not particularly -- if the frequency of this is increasing, that says to me that something is changing in the OS, since nothing has changed in AI War for a while, you know?  And in general all we do is tell the Unity 3D engine "shut down the game now" (literally Application.Quit() is the entirety of the code) and then unity takes it from there.  So even if it is unity, it's not really in our power to do anything about it, since it happens outside our code.  Unfortunately that means that it's pretty much down to switching out and force-killing it, or something along those lines, to avoid it if it's happening a bunch. :/
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Sounds

  • Full Member Mark II
  • ***
  • Posts: 193
Re: System-Freeze when exiting game (osx)
« Reply #5 on: December 01, 2013, 09:54:21 pm »
Unfortunately not particularly -- if the frequency of this is increasing, that says to me that something is changing in the OS, since nothing has changed in AI War for a while, you know?  And in general all we do is tell the Unity 3D engine "shut down the game now" (literally Application.Quit() is the entirety of the code) and then unity takes it from there.  So even if it is unity, it's not really in our power to do anything about it, since it happens outside our code.  Unfortunately that means that it's pretty much down to switching out and force-killing it, or something along those lines, to avoid it if it's happening a bunch. :/

I was hoping you might have an answer, so I could trap the error. I kept thinking it might be local to my box rather than the game itself. I ended up doing a complete rebuild on the weekend (for other reasons) and I did a fresh install of AI War. Sure enough it still occurs. :(

Seeing how you call Application.Quit() I suspected that it also might be an external problem, so I ran a couple of tests and discovered that this only occurs when you run it through steam and also save / load a game. My suspicion now is that it steam might be the culprit and related to some form of sync / update issue - but thats just a guess.

Do you call steam functionality on a separate thread within AI war to do any form of sync/update?
« Last Edit: December 01, 2013, 09:56:35 pm by Sounds »

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: System-Freeze when exiting game (osx)
« Reply #6 on: December 03, 2013, 07:14:41 am »
All of our calls to steam are on the main thread, but a lot of them are callbacks and who knows what steam does during that period. Meanwhile steam is also somehow injecting itself into the game's running process, and takes up around 20ish thread handles (which in OSX a lot of those can just be open files, it's a strange way of tracking threads as an os).

From the sounds of this, then, it sounds like something that happens with steam for now, and which I'm betting affects some other unity games also, and which thus will likely get attention and be patched by valve.

Recent versions or steam have a few issues on some machines with unity games and the steam os, and valve is aware of this. I have a sneaky suspicion that the shutdown issue you're having (which I can't duplicate, naturally) is in the same vein as the startup issues that a few people see on lots of unity games with the steam overlay active.

Well... That's some information, at the very least. Sorry I can't do more!
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

 

SMF spam blocked by CleanTalk