Bullet Damage Calculation
Fragment of a discussion from Talk:SuperRamFire
Jump to navigation
Jump to search
4 * BULLET_POWER is quite reasonable. Bullets hits are rare. A bot usually spends more energy firing to the enemy then by hits taken. Thus there is an extra reward/punishment multiplier when a bot get hit. If we remove this term from the equation than bullets with BULLET_POWER <= 1 would do no damage at all. Which would be strange.
The real question why there is 2 * max(0, BULLET_POWER - 1) term. It gives an extra bonus to a high energy bullet. I guess it is the original authors way to reward slow moving (high energy) bullets which have less chance to hit a target. Why the reward is not continuous function of the BULLET_POWER is beyond me.