Stabing weapons training cut?

like the combat knife, it has the ‘stab’ flag but still trains cutting, even more confusion, the weapon kris trains both cutting and piercing

We could make an arcade game of all the times we’ve tried to Whack A Stab/Cut XP Bug. >_< Thanks for reporting, just the same.

Possible workaround: go into your @ menu, Tab to the skill list, highlight cutting weapons and hit spacebar to turn off XP/focus use there. Hopefully that should reroute the skill-dev to stabbing.

oh, an actual bug instead of being intentional?

why not just change all the “STAB” flag to “SPEAR” flag, seems to work for me with a quick test, code comment says they are interchangeable anyways

oh they are a bit different when getting stuck in enemies, nvm

It works like this:

Every knife-type weapon deals “equally random” amount of cutting and piercing. As in, if it deals 1d10 cutting, it also deals 1d10 piercing.
Only the higher of the two is actually dealt.
Only the actually dealt damage contributes to training.

Most survivors get cutting quicker, because there are more (good) weapons that do this AND because cutting damage has a lower penalty from low skills.
Therefore most survivors deal and train cutting when using knives early on.

As a result, most survivors train cutting only by using knives.

yeah this line in melee.cpp line 2126

if (p.weapon.has_flag(“SPEAR”) || (p.weapon.has_flag(“STAB”) && stab_dam > cut_dam))

pretty much proves this is intentional

Nah, this is a bug. Folks need to be able to train piercing.

Update: to that end, I reopened, tested, and merged your PR fixing the problem. Looks like you totally fixed the bug, and you’re just gonna have to live with that. :slight_smile:

are you absolutely sure it`s not intentional, i mean look at this code starting from line 367 in melee.cpp (condensed)

if (cut_dam > stab_dam)
d.add_damage(DT_CUT, cut_dam);
else
d.add_damage(DT_STAB, stab_dam);

I mean if you are sure i can clean out codes like this

[quote=“aierce, post:8, topic:8819”]are you absolutely sure it`s not intentional, i mean look at this code starting from line 367 in melee.cpp (condensed)

if (cut_dam > stab_dam)
d.add_damage(DT_CUT, cut_dam);
else
d.add_damage(DT_STAB, stab_dam);

I mean if you are sure i can clean out codes like this[/quote]

That makes sure folks don’t get screwed on damage coding. Different issue than code that ends up making other parts of the code practically useless, which is what you fixed.

Wait, so knives no longer cut or just no longer train cutting?

And if they no longer cut, is there any significant difference between knives and spears? Other than stuck chance, that is

[quote=“Coolthulhu, post:10, topic:8819”]Wait, so knives no longer cut or just no longer train cutting?

And if they no longer cut, is there any significant difference between knives and spears? Other than stuck chance, that is[/quote]

Knives that do cutting damage train cutting. Knives that do stab damage train piercing.

Should say on the item-examine what sort of damage they do.

How does skill factor into damage? If it studied ‘FM 23-25 Bayonet Murder: Best Practices’ and end up with 4 skill in piercing, 1 in everything else, will my combat knife deal mostly piercing or is it totally random still?

Should be piercing, but I saw the code you’re talking about. Since we theoretically check for “which way would do the most damage” and go with that, higher skill should make stabby weapons stab rather than cut, to the extent this change didn’t.

Update: gave myself a combat knife (bash 2, stab 18) and eventually 10 Cutting skill. Nominal bash XP and lots of piercing. Pretty sure damage type is the key factor here.