An overcharge, as with a bad regulator can cause that. So can high heat, like when it's 100 degrees. As temps increase, the charging voltage needs to decrease. If the batteries are charged without temperature compensation, and most rarely are, they can receive way too many volts resulting in an overcharge. This can happen with a perfectly functioning regulator. The internal temperature of the batteries are higher than ambient anyway because of the heat generated in the chemical process of charging them. If it's 100 degrees, the batteries can reach 120 or more while charging. High temps mean quicker charging, more available amps, and shortened battery life. Cooler temps is the opposite.
When batteries are overcharged, the will short internally and.the internal voltage rises above 14 until it fries itself, then the voltage drops to under 12 after a while because it can no longer hold a charge. They swell because of the rapid sulphation.