Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Dario

Damage Dealt To An Enemy

This topic is 5837 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, im making an rpg and am having problems coming up with a good method of calculating a damage dealt to an enemy or hero depending on the attack power and defense. For example, lets say that the heroes attack power is 28 and the enemies defense is 16, how would i determine the damage that is dealt to the enemy?

Share this post


Link to post
Share on other sites
Advertisement
A simple way would be to just subtract defense from attack power to determine damage. But that would make targets with a higher defense than the attack power impossible to hurt. It seems that some damage should be done, and slowly reduce until the defense is say double the attack power, then none would be taken.

You need to choose a formula that allows you to scale attack powers and defenses accordingly. For instance, with the example above, a 56 attack creature has the potential to do double the damage of a 28 attack creature (if the target has 0 defense).

Hmm, interesting number game...

Share this post


Link to post
Share on other sites
The idea of subtracting the enemies defense from the heroes attack is pretty good, except for the fact that an enemy with high defense would be vulnerable to attacks. If i could think of some way where the defense would be a little less effective than that, than it would really help. One idea i had is the following.

multiply the heroes attack power, to make the defense of the enemy less effective.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!