How to troubleshoot overheat/short of microcontroller?
Things that could go wrong:


PCB manufacturing error (especially with DIY technology): you should check the integrity of the traces before soldering the components, for example with a DMM in continuity checking mode (the one with the buzzer),
PCB soldering error: if it's not factory-soldered (wave or reflow), you should learn to properly solder by hand (using flux); you may check the integrity of the soldering joints (again, with a DMM in continuity checking mode), or you may simply reheat the suspicious points,
PCB design error: incorrect IC pinouts (human mistakes, bad data sheets, incompatible replacement products),
component orientation error: inserting a DIP IC with the opposite orientation is such a common error that it deserves a separate bullet point - for a 74xx-series IC this means a negative power supply - usually a very fast destruction...


These were the easier errors, though. The design errors are usually harder to find. Just a handful selection of common errors:


not considering the Absolute Maximum values in the data sheet for the pin voltages: for most of the CMOS IC pins, letting a pin above Vcc or below GND usually makes the intrinsic p-n junction forward-biased and that could cause large currents flowing - therefore connecting circuits with separately switched power supplies can be tricky,
not considering the Absolute Maximum values in the data sheet for the pin output current: driving an impedance too small, either because the pin is simply not strong enough for the task, or because a capacitive load is driven with a high frequency signal without a proper series resistor,
letting a MOSFET gate practically unconnected could let it wander into a half-way open position, causing a large dissipation within the MOSFET (this can be created by letting an MCU input unconnected, for example by connecting it only to another MCU output which happens to be in high-impedance state because the MCU's RESET pin is asserted or because the code is being debugged and stopped before configuring it correctly),
configuring multiple push-pull outputs "against" each other (connecting multiple outputs together without making sure the outputs are driven by the same signal, or making sure only one of them is enabled at a time),
improper strength for power MOSFET gate driving, considering the frequency and the load involved, leading to the MOSFET spending a large time in transitional region, and causing a large dissipation,
driving complementer transistor pairs (PNP &amp; NPN or P &amp; N MOSFET) without proper dead time (this results in both transistors forwarding at the same time, a "shoot-through" situation).


(The last two examples are not really applicable for MCUs but for MOSFETs but they are still worth mentioning here.)