public override bool HandleEvent(AwardingXPEvent E) { var SeededRandom = ParentObject.GetSeededRandom("Animancy"); int SavantChance = SeededRandom.Next(1, 100); var AnimaMultiplier = ParentObject.GetSeededRandom("Animancy"); int currentXPAward = E.Amount; if (SavantChance <= 10 + this.Level - 1) { // AddPlayerMessage("Unedited XP Award : " + E.Amount); // AddPlayerMessage("Previous EXP : " + ParentObject.Statistics["XP"].Value); ProccedAnimaBonus = true; FactorIncreaseHolder = AnimaMultiplier.Next(2, 7); E.Amount = currentXPAward * FactorIncreaseHolder; // AddPlayerMessage("Edited XP Award : " + E.Amount); if (this.Level >= 10 && Stat.Random(1, 100) <= 10) { int BaseBonusExpAward = currentXPAward * FactorIncreaseHolder; E.Amount = BaseBonusExpAward; VividChoices.GetRandomElement(); } } return(base.HandleEvent(E)); }
public override bool HandleEvent(AwardingXPEvent E) { try { int CurrentGlimmer = ParentObject.GetPsychicGlimmer(); ParentObject.SetIntProperty("GlimmerModifier", CurrentGlimmer / 2); ParentObject.SetIntProperty("Glimmer", CurrentGlimmer / 2); } catch { } return(base.HandleEvent(E)); }