Advertisement

Fighting system in RPG type game

Started by January 02, 2006 07:35 AM
3 comments, last by LuckyOne 19 years, 1 month ago
My current hit calculation is pretty simple, hit power is calculated in this way hitpower = random(weapon_min_hit_power + Char_STRENGTH, weapon_max_hit_power + Char_LUCK) Maximum allowed Luck & Strength is 10. And health is reduced like this: Health -= hitpower-random(Char_DEX + ARMOR ,hitpower) Any better solutions?
Your formulas correspond to the following health decrease expectation:

1/4 WEPatk + 1/4 STRatk + 1/4 LUKatk - 1/2 DEXdef - 1/2 ARMdef

(with WEP being the average hit power of a weapon).

Assuming that STR and DEX are intended to have equal ranges, then defending is twice as easy as attacking (because the impact of DEX is twice as large as that of STR). Similarly, ARM is twice as important as WEP, so the armor values will tend
to cost twice as much as weapons.

To determine whether this is adapted to the rest of the game, I'd also need formulas for health increase, and how the player can choose to increase his different stats (health, STR, DEX, LUK)...



Advertisement
Health is increased by using Herbs or medkits. Their price is unknown by this time. Formula is as simple as Health += medkit_points.

So, the problem lies int this line:
Health -= hitpower-random(Char_DEX + ARMOR ,hitpower)

i want to keep MAX random value to hitpower because i want that there is chance that no damage is caused. Any good solution for MIN value then?
Divide the minimum value by 2.
I thought that too, ok thanks in advance!

This topic is closed to new replies.

Advertisement