Page MenuHomeWildfire Games

Ballistics.
Needs ReviewPublic

Authored by Freagarach on Sep 6 2017, 8:03 PM.

Details

Reviewers
temple
Group Reviewers
Restricted Owners Package(Owns No Changed Paths)
Summary

This patch adds a factor that units can be given to aim less accurately on moving targets.
Ideally this would be on a [0, 1] scale I think, where 1 == perfect estimation?

Test Plan

See if you like this behavior or not.
Test that with a higher value a moving target is hit less often and that normal behaviour is maintained with no changes made to templates.

Event Timeline

temple created this revision.Sep 6 2017, 8:03 PM

Like in talking to walls.

elexis added a subscriber: elexis.Sep 7 2017, 12:51 AM

Got a link to a prior discussion?

fatherbushido requested changes to this revision.Oct 23 2017, 3:57 PM

I consider that as not wanted with our attack system.
So I put that at requested changes (but I don't expect changes).
(Even if in the rts of my dreams, the attack system would be different).
The main one which make that irrelevant is that we don't have point attack.

This revision now requires changes to proceed.Oct 23 2017, 3:57 PM
elexis added a comment.Dec 5 2017, 8:01 PM

(I'm not informed to see why it would be bad to have it, even if only for the mod support.)

temple added a comment.Dec 5 2017, 8:18 PM

The point might have been something like it's expensive when units miss their targets since then we have to search for nearby units to see if the projectile hit one of them. Adding this patch would mean that we're missing units a lot more. But he might have meant something else, I don't usually know what's going on inside his head. :)

elexis added a comment.Dec 5 2017, 8:46 PM
In D880#44328, @temple wrote:

Adding this patch would mean that we're missing units a lot more

Well, that's what the tech is designed to do (making the player pay for something instead of granting it from the beginning)
I don't like the argument, but: AoE2 has it too, so supporting it for mods if not having it ingame doesn't sound intrinsically bad.

If we had it in vanilla, what would be the effect on the game? people trying to dodge arrrows more I guess? Would it be bad or allow players to decide between tactics (dodging arrows) and strategy (researching the tech)?

temple added a comment.Dec 5 2017, 9:48 PM
In D880#44331, @elexis wrote:
In D880#44328, @temple wrote:

Adding this patch would mean that we're missing units a lot more

Well, that's what the tech is designed to do (making the player pay for something instead of granting it from the beginning)
I don't like the argument, but: AoE2 has it too, so supporting it for mods if not having it ingame doesn't sound intrinsically bad.
If we had it in vanilla, what would be the effect on the game? people trying to dodge arrrows more I guess? Would it be bad or allow players to decide between tactics (dodging arrows) and strategy (researching the tech)?

The biggest difference would be that you could run away from attacks, e.g. women will be able to run to safety, at least if the ranged units aren't too close. Of course you'd have to test a bit to see the exact effects, and maybe we'd want to adjust the walking speed or projectile speed to get it feeling right. It's actually a bit frustrating being on the attacking side in that situation, so that's why I'm not sure ballistics is a good addition.

With larger armies it might not have a huge effect because any missed shots can still hit other units. I think in AoE2 that's not the case (except for splash damage), so pros end up doing a move-stop-attack-move cycle and can avoid taking damage indefinitely if they time it right. https://www.youtube.com/watch?v=TgU_yaqDsiM

The current system has some problems because it only uses the previous turn for predicting where units will be, so if units dance in place the predictions can be wildly off and that's quite annoying (except when you're the one dancing). And I imagine it'll only get worse if we lower the turn length. Hmm, maybe we could take some kind of average between its current position and its predicted position? Maybe that would lower the effectiveness of dancing a bit.

(We should have an attack ground command for ranged units.)

ffffffff added a subscriber: ffffffff.

makes the game more diversitive

Freagarach added a subscriber: Freagarach.EditedAug 13 2019, 9:50 AM

Could we make it a factor instead? Like if it is 0.5 you've got a 50% chance of correctly estimating the position of a moving object and one can modify that number for different ballistics?
With that factor one can vary either the ETA or estimated velocity (or both)? (Normally distributed perhaps.)
Just throwing in some ideas ;)

This revision now requires review to proceed.Aug 13 2019, 9:50 AM

Proposed different approach:
https://code.wildfiregames.com/differential/diff/10072/
here an entity could have a BallisticsFactor. A factor of 0 means the entity can perfectly estimate the target movement (current behaviour and default). Higher values mean the target's estimated location is less accurately predicted. The exact value of 0.05 can be determined while testing. Also, higher target speeds means the target location is less accurately predicted.

Freagarach updated this revision to Diff 10072.Sat, Mar 28, 5:28 PM
Freagarach retitled this revision from Ballistics to Ballistics..
Freagarach edited the summary of this revision. (Show Details)
Freagarach edited the test plan for this revision. (Show Details)
Freagarach added a reviewer: Restricted Owners Package.
Freagarach set the repository for this revision to rP 0 A.D. Public Repository.

Different approach.

Freagarach commandeered this revision.Sat, Mar 28, 5:28 PM
Freagarach added a reviewer: temple.

Build failure - The Moirai have given mortals hearts that can endure.

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

Build failure - The Moirai have given mortals hearts that can endure.

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

Build failure - The Moirai have given mortals hearts that can endure.

Link to build: https://jenkins.wildfiregames.com/job/macos-differential/515/display/redirect