wowlab_engine_content/hooks/affliction_warlock/
config.rs1use wowlab_engine_ports::HandlerParams;
2
3use crate::generated::specs::affliction_warlock::TALENT;
4
5#[derive(Clone, Copy, Debug, Default)]
6#[expect(
7 clippy::struct_excessive_bools,
8 reason = "these flags represent independent Affliction talent selections"
9)]
10pub(super) struct AfflictionConfig {
11 pub(super) demoniacs_fervor: bool,
12 pub(super) manifested_avarice: bool,
13 pub(super) soul_anathema: bool,
14 pub(super) shadow_of_nathreza_rank: u8,
15 pub(super) shadow_of_death: bool,
16}
17
18#[derive(Clone, Copy, Debug, Default)]
19pub(super) struct AfflictionRuntime {
20 pub(super) manifested_avarice_attempts: u32,
21 pub(super) dark_harvest_ticks: u8,
22}
23
24pub(super) fn affliction_config(params: &HandlerParams<'_>) -> AfflictionConfig {
25 let shadow_of_nathreza_rank = params.talent_ranks(TALENT::SHADOW_OF_NATHREZA);
26
27 AfflictionConfig {
28 demoniacs_fervor: params.talent_picked(TALENT::DEMONIACS_FERVOR),
29 manifested_avarice: params.talent_picked(TALENT::MANIFESTED_AVARICE),
30 soul_anathema: params.talent_picked(TALENT::SOUL_ANATHEMA),
31 shadow_of_nathreza_rank,
32 shadow_of_death: params.talent_picked(TALENT::SHADOW_OF_DEATH),
33 }
34}