All babies don't sleep thru anything. It depends on what they are used to. If they are used to a quiet household where Mom is the only one around when they try to nap, then, yes, your generator could keep it from going to sleep, just like it would me. Most campgrounds we have been in have specific hours to run a generator. If your generator was loud even within the specified hours, I wouldn't want to listen to it for long periods of time. Was it possible for you to open windows and use a fan to be comfortable? I would shut off the generator to let baby sleep. I also don't want to listen to a cranky tired crying baby next door.