One of the great things about linux is that you rarely ned to reboot it. If you are able to get to a shell through ctrl-alt-f2, then you can use that to kill the game, leaving everything else fine. Here are some possibilities:
I'll assume the game is named gamez for the purpose of this example.
When it crashes, again do ctrl+alt+f2, and then do this:
That will give you a list of processes associated with the game. Once you have those numbers, you just kill the processes. As another example, here is a list of processes my machine runs evolution, so if I wanted to kill it, I'd get this list:
Code:
jim@jimsworktop:~$ ps aux|grep evolution
jim 4945 0.1 42.9 327112 110220 ? Sl Sep15 1:28 evolution --component=mail
jim 4951 0.0 0.6 72492 1752 ? Sl Sep15 0:00 /usr/lib/evolution/evolution-data-server-1.6 --oaf-activate-iid=OAFIID:GNOME_Evolution_DataServer_InterfaceCheck --oaf-ior-fd=24
jim 4954 0.0 0.8 34144 2188 ? Sl Sep15 0:00 /usr/lib/evolution/2.6/evolution-exchange-storage --oaf-activate-iid=OAFIID:GNOME_Evolution_Exchange_Component_Factory:2.6 --oaf-ior-fd=26
jim 4970 0.0 0.9 65644 2372 ? Sl Sep15 0:00 /usr/lib/evolution/2.6/evolution-alarm-notify --oaf-activate-iid=OAFIID:GNOME_Evolution_Calendar_AlarmNotify_Factory:2.6 --oaf-ior-fd=28
jim 9787 0.0 0.2 2976 660 pts/3 D+ 13:33 0:00 grep evolution
Then if I wanted to kill evolution, I'd issue the command
Code:
kill -15 4945 4951 4954 4970
Then again do the ps aux|grep gamez. If it killed the game, the only answer will be the grep process. If it still lists actual processes, do the kill again, this time with -9 instead of -15 on any processes still running.
Once all that is done, the game should be dead. At that point, you can hit ctrl+alt+f7 to return to the X windows session. Should you return to X and it is still screwed up, then the problem is within X as opposed to the game. You can repeat the same process to close down X windows and restart it, or just sign in and type "startx" without quotes to begin a new X session. Avoid rebooting in general, it servers little purpose on a linux box.
Peace,
JimBass