fixed attenuation bug