Пример #1
0
    public override void OnConsumed(Artifact artifactConsumed)
    {
        // TODO: rework this to be less cringe
        // Check if Golden Bow is equipped, to prevent re-gaining double ammunition (essentially farming it, which is toxic)
        var goldenBow = User.Instance.CurrentHero.EquippedArtifacts.FirstOrDefault(x => x.Name == "Golden Bow");

        if (goldenBow is not null)
        {
            return;
        }

        var randomizedNumber = RandomnessHelper.Rng.Next(1, 10001);

        if (randomizedNumber <= ChanceToRecoverAmmunitionOnConsume * 10000)
        {
            artifactConsumed.AddItem(1);
        }
    }
Пример #2
0
 public override void OnConsumed(Artifact artifactConsumed)
 {
     artifactConsumed.AddItem(1);
 }