Skip to content

Monsters with a weapon always deal full damage (#990) - #1021

Open
kroplabeskidu wants to merge 1 commit into
Try:masterfrom
kroplabeskidu:fix-990
Open

kroplabeskidu wants to merge 1 commit into
Try:masterfrom
kroplabeskidu:fix-990

Conversation

@kroplabeskidu

Copy link
Copy Markdown

Skeletons have a weapon equipped, so tal is 1H/2H, the isMonster() && tal==TALENT_UNKNOWN check is skipped and they roll against hitchance[tal], which is 0 for monsters. Every hit becomes (vd-1)/10.

In vanilla oCNpc::OnDamage_Hit skips the hitchance roll completely if the attacker IsMonster(), weapon or not. IsMonster() there is not human, not orc and not dragon/fire golem/ice golem, so goblins and skeletons count.

Tested with SKELETON (str 100, ItMw_2H_Sword_M_01 = 50) vs a fresh hero (40 hp, no armor): 14 per hit before, 150 after, one hit like in vanilla.

Fixes #990

Vanilla skips the hitchance roll for any attacker that IsMonster(),
equipped weapon doesn't matter. Skeletons were rolling against
hitchance[1H]=0 and doing (dmg-1)/10.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Skeletons and goblins do too little damage

1 participant