wowlab_engine_content/hooks/items/
heart_of_ancient_hunger.rs1use wowlab_engine_combat::{AuraOps as _, HookCtx, ProcOps as _};
2
3use crate::{
4 generated::items::heart_of_ancient_hunger::{AURA_BINDING, RPPM_BINDING},
5 hooks::items::{bound_aura, bound_rppm},
6};
7
8pub(crate) fn on_player_cast(ctx: &mut HookCtx<'_>) {
9 if !bound_rppm(ctx, RPPM_BINDING).is_some_and(|rppm| ctx.roll_rppm(rppm)) {
10 return;
11 }
12
13 if let Some(aura) = bound_aura(ctx, AURA_BINDING::HUNGER) {
14 ctx.apply_aura(aura);
15 }
16}