Page MenuHomeWildfire Games

Use matching classes in damage bonus (from rP22769).
ClosedPublic

Authored by Freagarach on Sep 5 2019, 5:29 PM.

Details

Reviewers
bb
Group Reviewers
Restricted Owners Package(Owns No Changed Paths)
Commits
rP23431: Merge kushites champion infantry attack bonusses
Summary

This uses the functionality introduced in rP22769 in the only template that benefits for now.

Test Plan

Verify this is more correct than what it was because any unit who would have both classes would previously have had 1.3*1.3 times the bonus.

Diff Detail

Repository
rP 0 A.D. Public Repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Freagarach created this revision.Sep 5 2019, 5:29 PM
Vulcan added a comment.Sep 5 2019, 5:32 PM

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/79/display/redirect

Vulcan added a comment.Sep 5 2019, 5:33 PM

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/588/display/redirect

Stan awarded a token.Sep 5 2019, 6:14 PM
Freagarach retitled this revision from Use new damage bonus functionality (from rP22769). to Use matching classes in damage bonus (from rP22769)..Dec 19 2019, 8:50 PM
Freagarach edited the test plan for this revision. (Show Details)
Nescio added a subscriber: Nescio.Dec 19 2019, 9:00 PM

What's the difference?

Instead of two bonuses, it is now one, which has exactly the same in-game effect. (Unless one would have a unit with both the Champion and the Hero class, in that case the bonus against it will be only 1.3 while previously it would have been 1.3*1.3.)

If there is no difference, then why change? (I don't think there is any entity which has both the Champion and Hero class.)

bb accepted this revision.Jan 22 2020, 10:54 PM
bb added a subscriber: bb.

Looks correct and complete to me

(I don't think there is any entity which has both the Champion and Hero class.)

If someone wants to add a bonus to two classes, that, hypothetical, person shouldn't see this "wrong" example, rather see the correct one, even though in this case the effect is the same. Also who knows if there will be a unit "Champion+Hero" ;)
Lastly, it is less code after all...

This revision is now accepted and ready to land.Jan 22 2020, 10:54 PM
This revision was automatically updated to reflect the committed changes.