< Summary

Class:DCL.SettingsCommon.SettingsControllers.SpecificControllers.MaxHQAvatarsControlController
Assembly:SettingsControllers
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/Settings/SettingsControllers/SpecificControllers/MaxHQAvatarsControlController.cs
Covered lines:8
Uncovered lines:0
Coverable lines:8
Total lines:25
Line coverage:100% (8 of 8)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
Initialize()0%110100%
GetStoredValue()0%110100%
UpdateSetting(...)0%110100%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/Settings/SettingsControllers/SpecificControllers/MaxHQAvatarsControlController.cs

#LineLine coverage
 1using DCL;
 2using DCL.SettingsCommon.SettingsControllers.BaseControllers;
 3using UnityEngine;
 4
 5namespace DCL.SettingsCommon.SettingsControllers.SpecificControllers
 6{
 7    [CreateAssetMenu(menuName = "Settings/Controllers/Controls/Max HQ Avatars", fileName = "MaxHQAvatarsControlControlle
 8    public class MaxHQAvatarsControlController : SliderSettingsControlController
 9    {
 10        public override void Initialize()
 11        {
 112            base.Initialize();
 113            DataStore.i.avatarsLOD.maxAvatars.Set(currentQualitySetting.maxHQAvatars);
 114        }
 15
 116        public override object GetStoredValue() { return currentQualitySetting.maxHQAvatars; }
 17
 18        public override void UpdateSetting(object newValue)
 19        {
 120            int valueAsInt = (int)(float)newValue;
 121            currentQualitySetting.maxHQAvatars = valueAsInt;
 122            DataStore.i.avatarsLOD.maxAvatars.Set(valueAsInt);
 123        }
 24    }
 25}