Poor InflictDamage performance on kills
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 17.4k
- Forks
- 3k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 14
Description
I noticed arbitrary lag spikes caused by projectiles.
On my notebook with i5-4210M (and presumably some throttling even in 'performance' mode) the Bullet effect (sometimes Missile, too, but less pronounced) occasionally eats up to 80 ms on RA's shellmap in performance mode (and much more, sometimes over 300(!)ms in balanced/power-saving mode).
And while far less of an issue there, even on my i5-2500 main rig the projectiles cause occasional 10-20ms spikes.
Their appearance seems to be quite random, so I wonder whether it's only some specific part of the code that causes this.
A while ago I tried to find the exact cause by disabling the ShouldExplode checks and some effects (contrail, trail) one by one, but none of those improved the situation significantly (if at all).
Those hiccups can be quite annoying on slower systems, so it would be nice if someone managed to track down and get rid of the cause.
Edit: It appears it's not the projectile itself, but the stuff happening on impact (warheads).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the lag spikes on RA's shellmap in performance and power-saving modes, comparing Bullet and Missile impacts. Profile the work performed on impact, especially warheads, since the report points there rather than to the projectile itself. Done means the cause is identified and the intermittent impact spikes are reduced or eliminated on slower systems.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- game-dev, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100