Hello ouzcoskun,
Welcome to Apple Support Communities!
If we understand your post correctly, when you connect your Mac with an ATX power supply it quickly goes to sleep mode and the CPU is getting hot and the monitor doesn't work. We'd like to help!
Let's try an SMC reset.
How to reset the SMC of your Mac
You may also want to try an NVRAM reset.
Reset NVRAM or PRAM on your Mac
We also recommend starting in safe mode. Sometimes just starting in this mode and then restarting can resolve issues like this: How to use safe mode on your Mac
You can also create another user on your Mac and test to see if you experience the same issue.
Set up users, guests, and groups on Mac
You may want to also run Disk Utility which will check for and fix errors related to the formatting and directory structure of a Mac storage device.
Repair a storage device in Disk Utility on Mac
Let us know if you have any questions.
Thank you for using Apple Support Communities.
Take care!