public static void ApplyForTargetIfAnew(DowsingMod mymod, Player player) { int buff_type = mymod.BuffType <PsychokineticChargeDebuff>(); int buff_idx = player.FindBuffIndex(buff_type); if (buff_idx == -1) { player.AddBuff(buff_type, mymod.Config.Data.PsychokineticChargeDurationForTargets); } }
public void VirtualTargetIsApproached(DowsingMod mymod, Player player) { this.IndicateVirtualTargetRange(player); this.VirtualTargetFakeouts--; int idx = player.FindBuffIndex(mymod.BuffType <PsychokineticChargeDebuff>()); if (idx >= 0) { player.buffTime[idx] += mymod.Config.Data.VirtualTargetPsychChargeAddedTime; } if (this.VirtualTargetFakeouts <= 0) { this.VirtualTargetArrival(mymod, player); } }