Maybe. Or maybe he'd have come to his senses... gotten on some meds that helped, or gotten some counseling, or just dealt with his demons. Or maybe, before then, he'd have gotten in trouble with the law and lost the ability to legally purchase firearms. Or maybe he'd have cracked in some other way and killed himself rather than a bunch of kids. That's a long time.
That's far from clear. For example, in the Sandy Hook attack, the school had security protocols that locked the doors after morning arrivals. Adam Lanza showed up and shot through the glass panel next to the locked front entrance doors and let himself in. 28 people wound up dead.
If you want to know what could make a difference, just look at a similar elementary school attack carried out the very same morning as Sandy Hook, in another country. The door to that school wasn't locked. But it's hard to get your hands on guns in that country, so the attacker went with a knife, instead. He tried to kill as many little kids as he could, but wound up being subdued before he'd managed to cause any lethal wounds. All those kids survived the attack.