Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

weapons: add tests to confirm melee weapon value and adjust some weapons (part 2) #41089

Merged
merged 5 commits into from
Jun 7, 2020

Conversation

mlangsdorf
Copy link
Contributor

@mlangsdorf mlangsdorf commented Jun 5, 2020

Summary

SUMMARY: Balance "weapons: add tests to confirm melee weapon value and adjust some weapons (part 2)"

Purpose of change

As part of the great melee weapon rebalance (#39644 et al), @Brian-Otten unfortunately forgot to adjust a couple of weapons' accuracy values. Also, although effective DPS tests were added around this time, no tests were added to make sure that melee weapon's have appropriate value and to
detect future changes that would change the value of melee weapons.

Rectify these issues by adding an additional set of tests that calculate the weapon value of various weapons against a fairly beefy reference avatar (all stats 10, all skills 4). Then rebalance some weapons.

This is part 2, which follows #41079 and covers two handed flails, fist weapons, axes, hammers, and clubs but not flails because there are no significant one-handed flails in the game right now.

Describe the solution

The tests just check if a given weapon has a given weapon_value, +/- 0.75.

Some weapons had their to-hit, mass, volume, and/or damages updated to bring them in line with expected values for similar weapons. Most noticeably, two-handed flails got a large reduction in volume and mass and a boost to damage to make them somewhat worthwhile as weapons.

Added a function to clear out known martial arts so that the testing avatar wouldn't randomly know some martial arts and throw test values out of wack.

@mlangsdorf mlangsdorf added Code: Tests Measurement, self-control, statistics, balancing. Melee Melee weapons, tactics, techniques, reach attack labels Jun 5, 2020
@mlangsdorf mlangsdorf force-pushed the melee_validation_2 branch from 9bc1b2e to 28552cf Compare June 5, 2020 19:27
@mlangsdorf mlangsdorf marked this pull request as ready for review June 5, 2020 19:29
@mlangsdorf mlangsdorf force-pushed the melee_validation_2 branch 2 times, most recently from 34a173b to e0b49d3 Compare June 5, 2020 23:34
add a function that removes all martial arts styles, and add it to
the clear_character() helper function in tests/ so that the weapon
DPS tests will be more consistent.
add tests for effective value for two-handed flails.  Reduce the volume
for two-handed flails so that it's possible for them to have reasonable
effective DPS values without needing unreasonable damage values, though
they still hit extremely hard.
add tests for effective value for unarmed weapons.  Add STAB to a
few weapons that should have it and slightly adjust some values so
that all the basic punch weapons are relatively close to each
other.
add tests for effective DPS/value for one handed axes.  Bring the crash
axe values in line with the hatchet.  Bring the primitive axe values in
line with the primitive adze.  Rename and slightly nerf the hand axes.
Slightly improve the stats on the pickaxe - it's still a terrible weapon,
but at least now it's as dangerous as a hatchet if you managed to connect.

Incidentally, noticed the new hook pike and nerf it's accuracy to be in
line with other pikes.
add tests for effective DPS/value for one handed bludgeons.  Reduce the
bashing damage on bats to bring them under maces; bring bokken, shillelagh,
and baseball bat base damage closer together.  Increase the weight of
two by swords and nail swords to tone them down a little.

Weapon value is mace > loaded stick > bats, batons, shillelaghs, and
bokkens > tonfas > crowbars > shovels and improvised clubs >
various tools > the humble rock.
@mlangsdorf mlangsdorf force-pushed the melee_validation_2 branch from e0b49d3 to d2c7044 Compare June 7, 2020 11:30
@mlangsdorf
Copy link
Contributor Author

NPC behavior tree unit tests are failing, not these tests any longer.

@jbytheway
Copy link
Contributor

Actually it's the "Check distribution of attacks to body parts for larger attacker." test that's causing the failure. That might be related to these changes, but I doubt it.

@kevingranade
Copy link
Member

That one is very occasionally flaky since it's RNG-driven, nothing to do with this change.

@kevingranade kevingranade merged commit d2b512e into CleverRaven:master Jun 7, 2020
@mlangsdorf mlangsdorf deleted the melee_validation_2 branch June 8, 2020 01:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code: Tests Measurement, self-control, statistics, balancing. Melee Melee weapons, tactics, techniques, reach attack
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants