Log in

View Full Version : Damage formulas, hit calculation



foxtacles
07-20-2013, 07:23 PM
Short story: we need server-side calculations of damage, hit detection.

Data we have:

- Used weapon, default damage output
- Position and angles of actors

We need:

- Formula / math to detect a hit (and corresponding body part)
- Formula to calculate damage, taking chances of critical hit / limb dismembering into account

Things to consider:

- Size of player (adult / child), size of creatures
- Individual weapon properties, individual creature properties
- Projectile properties (i.e. calculating the impact position of a Fat Man nuke)
- AOE damage
- and probably more

roby65
07-21-2013, 09:03 AM
This is a difficult task.
You also have to take account of creature type and current animation, and so we need to reverse creature meshes and animations.

Aeronix
08-22-2013, 08:26 AM
I'm no expert but for damage, you would have to use rays and categorize body model vertices.

Lobzz1k
08-24-2013, 07:21 AM
dmg=WeaponDamage-(WeaponDamage*DamageResistance\100)+/-20%

cOOLsp0T
11-01-2013, 07:40 PM
About the Damage Calculation, I guess the game uses the same S.P.E.C.I.A.L Game rules as Fallout 2 before.
I found the formular for Fallout 2 here: https://falloutmods.wikia.com/wiki/Fallout_engine_calculations

Koncord
07-10-2014, 10:40 AM
I researched damage formula for bullet:

pure_dmg = ((skill + 100) / 2)*(base_dmg / 100)
damage = (pure_dmg - (pure_dmg * DamageResist / 100)) * scale
damage_inhead = damage * 2
Scale is size of attacker.
P.S. This works well for bullet (pistols, miniguns, SMG, etc) and NPC (I think that is true for creatures).

UPDATE. This true for all weapons except melee and explosive weapons(grenades, missle launchers, Fat Man, all who created explosion).

Koncord
07-10-2014, 07:04 PM
HP = (endurance * 20) + 90 + (level * 10)

Don't forget perks.

Koncord
08-28-2014, 05:35 AM
I think that we should to detect hit with the client, it will facilitate the work. I already have some information how to do it.

foxtacles
08-28-2014, 04:31 PM
That would be nice. If we could detect hits/impacts and their locations in the client, we could pass that information to the server which could do damage calculation then.

Domlanza
09-14-2014, 08:31 PM
Is this project still in effect? and if so when the hell is it going to come out, i mean from what i can tell the project has been goin for a while

Domlanza
09-14-2014, 08:32 PM
Is this project still in effect? I mean its been going for a while, but if so when is it coming out

Volumed
09-14-2014, 10:33 PM
Is this project still in effect? I mean its been going for a while, but if so when is it coming out

Please don't double post and don't go off-topic.

Yes, the project is still in development it's already released there's a button in the narbar called "download" or if you mean something like a "stable" release read this: https://fuch.si/w8 ...

Koncord
09-14-2014, 11:32 PM
Currently the developers is too little free time. At least in my situation - studying at a college. Don't worry, vaultmp not abandoned =)

Koncord
01-18-2015, 10:41 AM
Correction of basic formula:

pure_dmg = ((skill + 100) / 2)*(base_dmg / 100)
damage = (pure_dmg - (pure_dmg * DamageResist / 100)) * scale * difficulty
damage_inhead = damage * 2
difficulty is from 0.5 to 2 in increments of 0.5
where 1 - normal