Exemplo n.º 1
0
        private static float SkillBuffModifier(Skill.Type type, float amount)
        {
            if (PlayerBuff.HasBuff <Productive>())
            {
                var statIncModifier = new StatIncreaseArgs(amount);
                PlayerBuff.GetBuff <Productive>()?.TakeEffect(statIncModifier);
                amount = statIncModifier.Amount;
            }

            return(amount);
        }
Exemplo n.º 2
0
    public virtual void Finish()
    {
        foreach (Skill.Type type in RequiredSkills.Keys)
        {
            Stats.AddXP(type, XPbonus);
        }
        WorkedToday = true;

        var salary = WagePerHour *
                     (float)System.TimeSpan.FromSeconds(JobManager.Instance.CurrentWorkingTime).TotalHours;

        if (PlayerBuff.HasBuff <Motivated>())
        {
            var statIncrease = new StatIncreaseArgs(salary);
            PlayerBuff.GetBuff <Motivated>()?.TakeEffect(statIncrease);
            salary = statIncrease.Amount;
        }

        Stats.AddMoney(salary);
    }
Exemplo n.º 3
0
        private static float StatBuffModifier(Status.Type type, float amount)
        {
            switch (type)
            {
            case Status.Type.Mood when amount > 0 && PlayerBuff.HasBuff <Freedom>():
                var statIncModifier = new StatIncreaseArgs(amount);
                PlayerBuff.GetBuff <Freedom>()?.TakeEffect(statIncModifier);
                amount = statIncModifier.Amount;
                break;

            case Status.Type.Health when PlayerBuff.HasBuff <Suppression>():
            {
                var statDecModifier = new StatDecreaseArgs(amount);
                PlayerBuff.GetBuff <Suppression>()?.TakeEffect(statDecModifier);
                amount = statDecModifier.Amount;
                break;
            }
            }

            return(amount);
        }
Exemplo n.º 4
0
 private void UpdateStat(StatIncreaseArgs args)
 {
     args.IncreaseValue(percentIncrease);
 }
Exemplo n.º 5
0
 private void UpdateStat(StatIncreaseArgs args)
 {
     args.IncreaseValue(percentIncrease);
     Notify.Show($"You received additional money for a great job!", Icon);
 }