Why does the game close itself in OneShot?

Quick answer: It is on purpose. OneShot closes at some story moments. Just reopen it to carry on.
Show walkthrough (quest spoilers)
On purpose
The game ends its own window to make a point in the story. It is not a crash. Your progress is saved.
Reopen it
Start the game again to continue. Wait if the game asks you to. Do not delete your files.
More
See the Fourth wall walkthrough.
