Fix math for transient damage.

Fix issue #118.