Hold cmd-R as soon as the startup chime bongs. Use included disk utility, terminal and Safari to figure out what's wrong and then fix it.
I already accessed recovery mode, but Disk Utility can't seem to find anything wrong with the hard drive.
I really don't know where to start looking, I check generic keywords like "mac shutting off at startup" and there seem to be a fair amount of people who got that problem, but there's little to no followup in most cases and where there is it pretty much always something about time machine, reinstalling ML or going to a Genius Bar.
If I reinstall Mountain Lion, is it going to wipe my applications and data? I have some important stuff in there... >_>
=====
Update: I didn't saw the "verify the hard drive's authorizations" button in Disk Utility. There were TONS of errors, but it didn't let me repair them. Checking the drive integrity once again after that finally displayed errors, that cannot be repaired either.
So I have to format this thing, or so Disk Utility says.
Is there anyway I can backup stuff I have on my Mac partition or am I screwed?