The Apocalypse Timeline

The Apocalypse how it came to be
The Apocalypse wasn't going to happen because Dr.Hood's Giant Zombification Beans was foiled by Stanley McDonald but when Stanley went back in time to stop his evil doppelgänger the time machine malfunctioned and took him back to July 11th, 2020 and scared his past self away prevented his past self from killing Big Slither causing a huge domino effect in Stanley's timeline. First Big Slither was able to start a huge bean trade addicting the entirety of That One Berg. Then the moon blew up from Stanley's time machine radiation and since Stanley McDonald wasn't able to stop Dr.Hood, his Giant Zombification Beans were able to turn the populous into Giant Bean Zombies. Then as the world devolved into chaos world wide forest fires broke out as the Apocalypse began.

How the Apocalypse came to be but didn't 10 minutes later
When Stanley returned to the present day after going back to defeat his doppelgänger failed he saw That One Berg in ruins and the surrounding forests on fire with Giant Bean Zombies mindlessly wandering the country side. Stanley met up with Pierre McDonald one of the last survivors and found Dr.Hood and forced him to fix the time machine. Once the time machine was fixed Stanley went back to July 11th, 2020 just before his 10 minute younger self was going to scare his past self and preventing him from killing Big Slither. As his 10 minute younger self appeared he pulled him aside and let his past self kill Big Slither fixing the timeline and killed his 10 minute younger self just for safe measure.