////////////////

        internal static void ApplyPlayerJumpingBehaviors(Player player, float necrotisPercent)
        {
            var config = NecrotisConfig.Instance;

            if (config.Get <bool>(nameof(config.DebuffReducesJumpHeight)))
            {
                float effectPercent = 1f - necrotisPercent;

                NecrotisBehavior.ApplyPlayerJumpingReductionBehaviors(player, effectPercent);
            }
        }
        internal static void ApplyPlayerMovementBehaviors(Player player, float necrotisPercent, out float changeResultPercent)
        {
            var config = NecrotisConfig.Instance;

            if (!config.Get <bool>(nameof(config.DebuffReducesRunWalkSpeed)))
            {
                changeResultPercent = 1f;
                return;
            }

            float effectPercent = 1f - necrotisPercent;

            changeResultPercent = NecrotisBehavior.ApplyPlayerMovementReductionBehaviors(player, effectPercent);
        }
        public static void ApplyBehaviors(
            Player player,
            float necrotisPercent,
            out int lastMaxHpLost,
            out float movePercent)
        {
            NecrotisBehavior.ApplyPlayerMovementBehaviors(player, necrotisPercent, out movePercent);
            NecrotisBehavior.ApplyPlayerJumpingBehaviors(player, necrotisPercent);
            NecrotisBehavior.ApplyPlayerHealthBehaviors(player, necrotisPercent, out lastMaxHpLost);
            NecrotisBehavior.ApplyPlayerDebuffBehaviors(player, necrotisPercent);

            if (necrotisPercent >= 1f)
            {
                NecrotisBehavior.ApplyWorldBehaviors(player);
            }
        }
Ejemplo n.º 4
0
        ////////////////

        public static void UpdateViewVisibilityScale(ref float visibility, float necrotisPercent)
        {
            visibility *= NecrotisBehavior.CalculateViewVisibilityScale(necrotisPercent);
        }