I bought a 2003 celica GT about 2 months ago with 170000 miles on it. today I drove 80 miles and went to start the car again after about 15 minutes... It misfired, both with black smoke shooting out from under the hood and flame from the exhaust and died immediately. The battery is pretty new and still works fine, and engine will turn over but won't run on its own. Upon inspection, the explosion left a big black mark on the hood right above where the alternator sits. The alternator itself looks clean and the coils are spotless, at least from a top down view. The spark plugs are brand new. Fuel injectors were replaced by previous owner about 6 months ago but was the only work he'd done not by a mechanic. Belts are in perfect condition with proper tension. No signs of any fluids not where they're supposed to be.
The car was a non-op in a garage for 2 years before I bought it, but was taken care of and started every once in a while. Normally, It does occasionally have to turn over a few times before starting. It has an extremely shakey idle when cold. Started it and drove it in 15 degree weather and it had a very violent and shakey/clangy warm up process. It also has small bulbs inside the headlights (not the actual headlights or blinker or high beams, I know... I know) that constantly flicker very dully. Besides that, no signs of electical problems.
Seems like a lot of random details, but after research it seems that all of these are signs of a faulty alternator. Is it possible for them to slowly give out and then explode one day? Wouldn't the car run off the battery for a few minutes?
Any help is greatly appreciated!