forked from WoWAnalyzer/WoWAnalyzer
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request WoWAnalyzer#6586 from Krealle/dragonflight
[Evoker] Improved accuracy of EssenceTracker module
- Loading branch information
Showing
20 changed files
with
416 additions
and
117 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 0 additions & 17 deletions
17
src/analysis/retail/evoker/devastation/modules/guide/EssenceGraph/EssenceGraphSection.tsx
This file was deleted.
Oops, something went wrong.
73 changes: 73 additions & 0 deletions
73
src/analysis/retail/evoker/devastation/modules/guide/EssenceGraphSection.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
import CombatLogParser from '../../CombatLogParser'; | ||
import { GuideProps, Section } from 'interface/guide'; | ||
import { QualitativePerformance } from 'parser/ui/QualitativePerformance'; | ||
import PerformancePercentage from './PerformancePercentage'; | ||
import { ResourceLink, SpellLink, Tooltip } from 'interface'; | ||
import RESOURCE_TYPES from 'game/RESOURCE_TYPES'; | ||
import { TIERS } from 'game/TIERS'; | ||
import { InformationIcon } from 'interface/icons'; | ||
import SPELLS from 'common/SPELLS/evoker'; | ||
|
||
export function EssenceGraphSection({ modules, events, info }: GuideProps<typeof CombatLogParser>) { | ||
const hasT31 = info.combatant.has4PieceByTier(TIERS.T31); | ||
const percentAtCap = modules.essenceTracker.percentAtCap; | ||
const essenceWasted = modules.essenceTracker.wasted; | ||
|
||
const perfectTimeAtEssenceCap = 0.1 + (hasT31 ? 0.05 : 0); | ||
const goodTimeAtEssenceCap = 0.15 + (hasT31 ? 0.05 : 0); | ||
const okTimeAtEssenceCap = 0.2 + (hasT31 ? 0.05 : 0); | ||
|
||
const percentAtCapPerformance = | ||
percentAtCap <= perfectTimeAtEssenceCap | ||
? QualitativePerformance.Perfect | ||
: percentAtCap <= goodTimeAtEssenceCap | ||
? QualitativePerformance.Good | ||
: percentAtCap <= okTimeAtEssenceCap | ||
? QualitativePerformance.Ok | ||
: QualitativePerformance.Fail; | ||
|
||
return ( | ||
<Section title="Essence Graph"> | ||
<p> | ||
Your primary resource is <ResourceLink id={RESOURCE_TYPES.ESSENCE.id} />. You should avoid | ||
overcapping <ResourceLink id={RESOURCE_TYPES.ESSENCE.id} /> - lost{' '} | ||
<ResourceLink id={RESOURCE_TYPES.ESSENCE.id} /> generation is lost DPS. Sometimes it will be | ||
impossible to avoid overcapping <ResourceLink id={RESOURCE_TYPES.ESSENCE.id} /> - due to | ||
handling mechanics, high rolling <SpellLink spell={SPELLS.ESSENCE_BURST_DEV_BUFF} /> procs | ||
or during intermission phases. | ||
</p> | ||
<p> | ||
The chart below shows your <ResourceLink id={RESOURCE_TYPES.ESSENCE.id} /> over the course | ||
of the encounter. You wasted{' '} | ||
<PerformancePercentage | ||
performance={percentAtCapPerformance} | ||
perfectPercentage={perfectTimeAtEssenceCap} | ||
goodPercentage={goodTimeAtEssenceCap} | ||
okPercentage={okTimeAtEssenceCap} | ||
percentage={percentAtCap} | ||
flatAmount={essenceWasted} | ||
/>{' '} | ||
of your <ResourceLink id={RESOURCE_TYPES.ESSENCE.id} />. | ||
{hasT31 && ( | ||
<> | ||
{' '} | ||
<Tooltip | ||
content={ | ||
<div> | ||
Since you have T31 4pc an extra 5% grace period is added, as it is expected that | ||
more <ResourceLink id={RESOURCE_TYPES.ESSENCE.id} /> will go to waste, due to the | ||
extra amount of <SpellLink spell={SPELLS.ESSENCE_BURST_DEV_BUFF} /> generated. | ||
</div> | ||
} | ||
> | ||
<div style={{ display: 'inline' }}> | ||
<InformationIcon style={{ fontSize: '1.4em' }} /> | ||
</div> | ||
</Tooltip> | ||
</> | ||
)} | ||
</p> | ||
{modules.essenceGraph.plot} | ||
</Section> | ||
); | ||
} |
45 changes: 45 additions & 0 deletions
45
src/analysis/retail/evoker/devastation/modules/guide/PerformancePercentage.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
import { PerformanceMark } from 'interface/guide'; | ||
import { QualitativePerformance } from 'parser/ui/QualitativePerformance'; | ||
import { formatNumber, formatPercentage } from 'common/format'; | ||
import PerformanceStrongWithTooltip from 'interface/PerformanceStrongWithTooltip'; | ||
|
||
interface Props { | ||
performance: QualitativePerformance; | ||
perfectPercentage: number; | ||
goodPercentage: number; | ||
okPercentage: number; | ||
percentage: number; | ||
flatAmount: number; | ||
} | ||
const PerformancePercentage = ({ | ||
performance, | ||
perfectPercentage, | ||
goodPercentage, | ||
okPercentage, | ||
percentage, | ||
flatAmount, | ||
}: Props) => { | ||
const perfectSign = perfectPercentage > 0 ? '<=' : '='; | ||
|
||
return ( | ||
<PerformanceStrongWithTooltip | ||
performance={performance} | ||
tooltip={ | ||
<> | ||
<PerformanceMark perf={QualitativePerformance.Perfect} /> Perfect usage {perfectSign}{' '} | ||
{formatPercentage(perfectPercentage, 0)}% | ||
<br /> | ||
<PerformanceMark perf={QualitativePerformance.Good} /> Good usage <={' '} | ||
{formatPercentage(goodPercentage, 0)}% | ||
<br /> | ||
<PerformanceMark perf={QualitativePerformance.Ok} /> OK usage <={' '} | ||
{formatPercentage(okPercentage, 0)}% | ||
</> | ||
} | ||
> | ||
{formatNumber(flatAmount)} ({formatPercentage(percentage)}%) | ||
</PerformanceStrongWithTooltip> | ||
); | ||
}; | ||
|
||
export default PerformancePercentage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.