Преглед на файлове

Reformat part 5 expression body on new line

Also, as usual, more little touches I've missed.
habeebweeb преди 2 години
родител
ревизия
48b19ef96a
променени са 57 файла, в които са добавени 306 реда и са изтрити 165 реда
  1. 2 2
      src/MeidoPhotoStudio.Converter/MultipleMaids/MMSceneConverter.cs
  2. 4 2
      src/MeidoPhotoStudio.Plugin/Constants.cs
  3. 3 3
      src/MeidoPhotoStudio.Plugin/DragPoint/CustomGizmo.cs
  4. 2 1
      src/MeidoPhotoStudio.Plugin/DragPoint/DragPointProp.cs
  5. 3 1
      src/MeidoPhotoStudio.Plugin/GUI/Controls/ComboBox.cs
  6. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Controls/KeyRebindButton.cs
  7. 9 4
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/AttachPropPane.cs
  8. 4 2
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/ModPropsPane.cs
  9. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/MyRoomPropsPane.cs
  10. 9 5
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/PropManagerPane.cs
  11. 12 6
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/PropsPane.cs
  12. 6 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/BackgroundSelectorPane.cs
  13. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/CameraPane.cs
  14. 8 4
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/DragPointPane.cs
  15. 4 2
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/EffectsPanes/EffectPane.cs
  16. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/EffectsPanes/EffectsPane.cs
  17. 33 15
      src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/LightsPane.cs
  18. 5 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/CallWindowPanes/MaidSelectorPane.cs
  19. 8 4
      src/MeidoPhotoStudio.Plugin/GUI/Panes/FaceWindowPanes/MaidFaceBlendPane.cs
  20. 4 2
      src/MeidoPhotoStudio.Plugin/GUI/Panes/FaceWindowPanes/MaidFaceSliderPane.cs
  21. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/FaceWindowPanes/SaveFacePane.cs
  22. 5 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/BG2WindowPane.cs
  23. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/BGWindowPane.cs
  24. 2 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/CallWindowPane.cs
  25. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/FaceWindowPane.cs
  26. 8 4
      src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/PoseWindowPane.cs
  27. 5 2
      src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/SettingsWindowPane.cs
  28. 12 4
      src/MeidoPhotoStudio.Plugin/GUI/Panes/OtherPanes/MaidSwitcherPane.cs
  29. 5 2
      src/MeidoPhotoStudio.Plugin/GUI/Panes/OtherPanes/TabsPane.cs
  30. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/CopyPosePane.cs
  31. 6 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/GravityControlPane.cs
  32. 15 8
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/HandPresetPane.cs
  33. 16 9
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidDressingPane.cs
  34. 8 4
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidFreeLookPane.cs
  35. 6 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidIKPane.cs
  36. 16 9
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidPoseSelectorPane.cs
  37. 10 5
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MpnAttachPropPane.cs
  38. 4 2
      src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/SaveHandPane.cs
  39. 6 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/SceneManagerPanes/SceneManagerDirectoryPane.cs
  40. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Panes/SceneManagerPanes/SceneManagerScenePane.cs
  41. 6 3
      src/MeidoPhotoStudio.Plugin/GUI/Panes/SceneManagerPanes/SceneManagerTitleBar.cs
  42. 1 1
      src/MeidoPhotoStudio.Plugin/GUI/Windows/BaseWindow.cs
  43. 7 4
      src/MeidoPhotoStudio.Plugin/GUI/Windows/MainWindow.cs
  44. 5 3
      src/MeidoPhotoStudio.Plugin/GUI/Windows/SceneModalWindow.cs
  45. 2 1
      src/MeidoPhotoStudio.Plugin/GUI/Windows/SceneWindow.cs
  46. 2 2
      src/MeidoPhotoStudio.Plugin/Managers/EffectManagers/BloomEffectManager.cs
  47. 2 2
      src/MeidoPhotoStudio.Plugin/Managers/LightManager.cs
  48. 3 3
      src/MeidoPhotoStudio.Plugin/Managers/MeidoManager.cs
  49. 3 3
      src/MeidoPhotoStudio.Plugin/Managers/PropManager.cs
  50. 2 2
      src/MeidoPhotoStudio.Plugin/Managers/SceneManager.cs
  51. 1 1
      src/MeidoPhotoStudio.Plugin/Meido/IK/DragPointPelvis.cs
  52. 2 1
      src/MeidoPhotoStudio.Plugin/Meido/IK/DragPointSpine.cs
  53. 3 1
      src/MeidoPhotoStudio.Plugin/Meido/Meido.cs
  54. 5 2
      src/MeidoPhotoStudio.Plugin/MeidoPhotoStudio.cs
  55. 1 1
      src/MeidoPhotoStudio.Plugin/Serialization/Serializers/ManagerSerializers/EffectManagerSerializer.cs
  56. 1 1
      src/MeidoPhotoStudio.Plugin/Serialization/Serializers/ManagerSerializers/PropManagerSerializer.cs
  57. 2 2
      src/MeidoPhotoStudio.Plugin/Serialization/Serializers/MeidoSerializer.cs

+ 2 - 2
src/MeidoPhotoStudio.Converter/MultipleMaids/MMSceneConverter.cs

@@ -134,7 +134,7 @@ public static class MMSceneConverter
             // MeidoSerializer -> Head version
             writer.WriteVersion(1);
 
-            var sixtyFourFlag = maidData.Length == 64;
+            var sixtyFourFlag = maidData.Length is 64;
 
             // eye direction
             // MM saves eye rotation directly which is garbage data for meido that don't use the same face model.
@@ -160,7 +160,7 @@ public static class MMSceneConverter
             else
             {
                 var freeLookData = maidData[64].Split(',');
-                var isFreeLook = int.Parse(freeLookData[0]) == 1;
+                var isFreeLook = int.Parse(freeLookData[0]) is 1;
 
                 writer.Write(isFreeLook);
 

+ 4 - 2
src/MeidoPhotoStudio.Plugin/Constants.cs

@@ -847,7 +847,8 @@ public static class Constants
         if (!MenuFilesReady)
         {
             if (!beginHandItemInit)
-                MenuFilesReadyChange += (s, a) => InitializeHandItems();
+                MenuFilesReadyChange += (s, a) =>
+                    InitializeHandItems();
 
             beginHandItemInit = true;
 
@@ -920,7 +921,8 @@ public static class Constants
         if (!MenuFilesReady)
         {
             if (!beginMpnAttachInit)
-                MenuFilesReadyChange += (s, a) => InitializeMpnAttachProps();
+                MenuFilesReadyChange += (s, a) =>
+                    InitializeMpnAttachProps();
 
             beginMpnAttachInit = true;
 

+ 3 - 3
src/MeidoPhotoStudio.Plugin/DragPoint/CustomGizmo.cs

@@ -50,9 +50,9 @@ public class CustomGizmo : GizmoRender
                 return;
 
             gizmoTypeOld = gizmoType;
-            eAxis = gizmoType == GizmoType.Move;
-            eScal = gizmoType == GizmoType.Scale;
-            eRotate = gizmoType == GizmoType.Rotate;
+            eAxis = gizmoType is GizmoType.Move;
+            eScal = gizmoType is GizmoType.Scale;
+            eRotate = gizmoType is GizmoType.Rotate;
         }
     }
 

+ 2 - 1
src/MeidoPhotoStudio.Plugin/DragPoint/DragPointProp.cs

@@ -100,7 +100,8 @@ public class PropInfo
     public string SubFilename { get; set; }
     public int MyRoomID { get; set; }
 
-    public PropInfo(PropType type) => Type = type;
+    public PropInfo(PropType type) =>
+        Type = type;
 
     public static PropInfo FromModItem(ModItem modItem) =>
         new(PropType.Mod)

+ 3 - 1
src/MeidoPhotoStudio.Plugin/GUI/Controls/ComboBox.cs

@@ -17,7 +17,9 @@ public class ComboBox : BaseControl
     public ComboBox(string[] itemList)
     {
         BaseDropDown = new("▾", itemList);
-        BaseDropDown.SelectionChange += (s, a) => textField.Value = BaseDropDown.SelectedItem;
+        BaseDropDown.SelectionChange += (s, a) =>
+            textField.Value = BaseDropDown.SelectedItem;
+
         Value = itemList[0];
     }
 

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Controls/KeyRebindButton.cs

@@ -23,7 +23,8 @@ public class KeyRebindButton : BaseControl
     public KeyRebindButton(KeyCode code)
     {
         button = new(code.ToString());
-        button.ControlEvent += (s, a) => StartListening();
+        button.ControlEvent += (s, a) =>
+            StartListening();
     }
 
     public void Draw(GUIStyle buttonStyle, params GUILayoutOption[] layoutOptions)

+ 9 - 4
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/AttachPropPane.cs

@@ -62,9 +62,11 @@ public class AttachPropPane : BasePane
 
         this.propManager = propManager;
         this.meidoManager = meidoManager;
+        this.meidoManager.EndCallMeidos += (s, a) =>
+            SetMeidoDropdown();
 
-        this.meidoManager.EndCallMeidos += (s, a) => SetMeidoDropdown();
-        this.propManager.PropSelectionChange += (s, a) => UpdateToggles();
+        this.propManager.PropSelectionChange += (s, a) =>
+            UpdateToggles();
 
         this.propManager.PropListChange += (s, a) =>
         {
@@ -73,7 +75,8 @@ public class AttachPropPane : BasePane
         };
 
         meidoDropdown = new(new[] { Translation.Get("systemMessage", "noMaids") });
-        meidoDropdown.SelectionChange += (s, a) => UpdateToggles();
+        meidoDropdown.SelectionChange += (s, a) =>
+            UpdateToggles();
 
         keepWorldPositionToggle = new(Translation.Get("attachPropPane", "keepWorldPosition"));
 
@@ -85,7 +88,9 @@ public class AttachPropPane : BasePane
             var point = attachPoint;
             var toggle = new Toggle(Translation.Get("attachPropPane", toggleTranslation[point]));
 
-            toggle.ControlEvent += (s, a) => OnToggleChange(point);
+            toggle.ControlEvent += (s, a) =>
+                OnToggleChange(point);
+
             toggles[point] = toggle;
         }
     }

+ 4 - 2
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/ModPropsPane.cs

@@ -61,10 +61,12 @@ public class ModPropsPane : BasePane
             return;
 
         modFilterToggle = new(Translation.Get("background2Window", "modsToggle"));
-        modFilterToggle.ControlEvent += (s, a) => ChangeFilter(FilterType.Mod);
+        modFilterToggle.ControlEvent += (s, a) =>
+            ChangeFilter(FilterType.Mod);
 
         baseFilterToggle = new(Translation.Get("background2Window", "baseToggle"));
-        baseFilterToggle.ControlEvent += (s, a) => ChangeFilter(FilterType.Base);
+        baseFilterToggle.ControlEvent += (s, a) =>
+            ChangeFilter(FilterType.Base);
     }
 
     public override void Draw()

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/MyRoomPropsPane.cs

@@ -20,7 +20,8 @@ public class MyRoomPropsPane : BasePane
         this.propManager = propManager;
 
         propCategoryDropdown = new(Translation.GetArray("doguCategories", Constants.MyRoomPropCategories));
-        propCategoryDropdown.SelectionChange += (s, a) => ChangePropCategory(SelectedCategory);
+        propCategoryDropdown.SelectionChange += (s, a) =>
+            ChangePropCategory(SelectedCategory);
 
         ChangePropCategory(SelectedCategory);
     }

+ 9 - 5
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/PropManagerPane.cs

@@ -48,10 +48,12 @@ public class PropManagerPane : BasePane
         };
 
         previousPropButton = new("<");
-        previousPropButton.ControlEvent += (s, a) => propDropdown.Step(-1);
+        previousPropButton.ControlEvent += (s, a) =>
+            propDropdown.Step(-1);
 
         nextPropButton = new(">");
-        nextPropButton.ControlEvent += (s, a) => propDropdown.Step(1);
+        nextPropButton.ControlEvent += (s, a) =>
+            propDropdown.Step(1);
 
         dragPointToggle = new(Translation.Get("propManagerPane", "dragPointToggle"));
         dragPointToggle.ControlEvent += (s, a) =>
@@ -74,17 +76,19 @@ public class PropManagerPane : BasePane
         shadowCastingToggle = new(Translation.Get("propManagerPane", "shadowCastingToggle"));
         shadowCastingToggle.ControlEvent += (s, a) =>
         {
-            if (updating || this.propManager.PropCount == 0)
+            if (updating || this.propManager.PropCount is 0)
                 return;
 
             this.propManager.CurrentProp.ShadowCasting = shadowCastingToggle.Value;
         };
 
         copyPropButton = new(Translation.Get("propManagerPane", "copyButton"));
-        copyPropButton.ControlEvent += (s, a) => this.propManager.CopyProp(CurrentDoguIndex);
+        copyPropButton.ControlEvent += (s, a) =>
+            this.propManager.CopyProp(CurrentDoguIndex);
 
         deletePropButton = new(Translation.Get("propManagerPane", "deleteButton"));
-        deletePropButton.ControlEvent += (s, a) => this.propManager.RemoveProp(CurrentDoguIndex);
+        deletePropButton.ControlEvent += (s, a) =>
+            this.propManager.RemoveProp(CurrentDoguIndex);
 
         propManagerHeader = Translation.Get("propManagerPane", "header");
     }

+ 12 - 6
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindow2Panes/PropsPane.cs

@@ -33,24 +33,30 @@ public class PropsPane : BasePane
             Constants.MenuFilesChange += InitializeHandItems;
 
         doguCategoryDropdown = new(Translation.GetArray("doguCategories", Constants.DoguCategories));
-        doguCategoryDropdown.SelectionChange += (s, a) => ChangeDoguCategory(SelectedCategory);
+        doguCategoryDropdown.SelectionChange += (s, a) =>
+            ChangeDoguCategory(SelectedCategory);
 
         doguDropdown = new(new[] { string.Empty });
 
         addDoguButton = new("+");
-        addDoguButton.ControlEvent += (s, a) => SpawnObject();
+        addDoguButton.ControlEvent += (s, a) =>
+            SpawnObject();
 
         nextDoguButton = new(">");
-        nextDoguButton.ControlEvent += (s, a) => doguDropdown.Step(1);
+        nextDoguButton.ControlEvent += (s, a) =>
+            doguDropdown.Step(1);
 
         prevDoguButton = new("<");
-        prevDoguButton.ControlEvent += (s, a) => doguDropdown.Step(-1);
+        prevDoguButton.ControlEvent += (s, a) =>
+            doguDropdown.Step(-1);
 
         nextDoguCategoryButton = new(">");
-        nextDoguCategoryButton.ControlEvent += (s, a) => doguCategoryDropdown.Step(1);
+        nextDoguCategoryButton.ControlEvent += (s, a) =>
+            doguCategoryDropdown.Step(1);
 
         prevDoguCategoryButton = new("<");
-        prevDoguCategoryButton.ControlEvent += (s, a) => doguCategoryDropdown.Step(-1);
+        prevDoguCategoryButton.ControlEvent += (s, a) =>
+            doguCategoryDropdown.Step(-1);
 
         ChangeDoguCategory(SelectedCategory);
     }

+ 6 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/BackgroundSelectorPane.cs

@@ -23,13 +23,16 @@ public class BackgroundSelectorPane : BasePane
             bgList.AddRange(Constants.MyRoomCustomBGList.Select(kvp => kvp.Value));
 
         bgDropdown = new(bgList.ToArray(), theaterIndex);
-        bgDropdown.SelectionChange += (s, a) => ChangeBackground();
+        bgDropdown.SelectionChange += (s, a) =>
+            ChangeBackground();
 
         prevBGButton = new("<");
-        prevBGButton.ControlEvent += (s, a) => bgDropdown.Step(-1);
+        prevBGButton.ControlEvent += (s, a) =>
+            bgDropdown.Step(-1);
 
         nextBGButton = new(">");
-        nextBGButton.ControlEvent += (s, a) => bgDropdown.Step(1);
+        nextBGButton.ControlEvent += (s, a) =>
+            bgDropdown.Step(1);
     }
 
     public override void Draw()

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/CameraPane.cs

@@ -15,7 +15,8 @@ public class CameraPane : BasePane
     public CameraPane(CameraManager cameraManager)
     {
         this.cameraManager = cameraManager;
-        this.cameraManager.CameraChange += (s, a) => UpdatePane();
+        this.cameraManager.CameraChange += (s, a) =>
+            UpdatePane();
 
         var camera = CameraUtility.MainCamera.camera;
         var eulerAngles = camera.transform.eulerAngles;

+ 8 - 4
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/DragPointPane.cs

@@ -18,16 +18,20 @@ public class DragPointPane : BasePane
         header = Translation.Get("movementCube", "header");
 
         propsCubeToggle = new(Translation.Get("movementCube", "props"), PropManager.CubeActive);
-        propsCubeToggle.ControlEvent += (s, a) => ChangeDragPointSetting(Setting.Prop, propsCubeToggle.Value);
+        propsCubeToggle.ControlEvent += (s, a) =>
+            ChangeDragPointSetting(Setting.Prop, propsCubeToggle.Value);
 
         smallCubeToggle = new(Translation.Get("movementCube", "small"));
-        smallCubeToggle.ControlEvent += (s, a) => ChangeDragPointSetting(Setting.Size, smallCubeToggle.Value);
+        smallCubeToggle.ControlEvent += (s, a) =>
+            ChangeDragPointSetting(Setting.Size, smallCubeToggle.Value);
 
         maidCubeToggle = new(Translation.Get("movementCube", "maid"), MeidoDragPointManager.CubeActive);
-        maidCubeToggle.ControlEvent += (s, a) => ChangeDragPointSetting(Setting.Maid, maidCubeToggle.Value);
+        maidCubeToggle.ControlEvent += (s, a) =>
+            ChangeDragPointSetting(Setting.Maid, maidCubeToggle.Value);
 
         bgCubeToggle = new(Translation.Get("movementCube", "bg"), EnvironmentManager.CubeActive);
-        bgCubeToggle.ControlEvent += (s, a) => ChangeDragPointSetting(Setting.Background, bgCubeToggle.Value);
+        bgCubeToggle.ControlEvent += (s, a) =>
+            ChangeDragPointSetting(Setting.Background, bgCubeToggle.Value);
     }
 
     public override void Draw()

+ 4 - 2
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/EffectsPanes/EffectPane.cs

@@ -30,10 +30,12 @@ public abstract class EffectPane<T> : BasePane where T : IEffectManager
         EffectManager = effectManager.Get<T>();
 
         resetEffectButton = new(Translation.Get("effectsPane", "reset"));
-        resetEffectButton.ControlEvent += (s, a) => ResetEffect();
+        resetEffectButton.ControlEvent += (s, a) =>
+            ResetEffect();
 
         effectToggle = new(Translation.Get("effectsPane", "onToggle"));
-        effectToggle.ControlEvent += (s, a) => Enabled = effectToggle.Value;
+        effectToggle.ControlEvent += (s, a) =>
+            Enabled = effectToggle.Value;
     }
 
     protected abstract void TranslatePane();

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/EffectsPanes/EffectsPane.cs

@@ -24,7 +24,8 @@ public class EffectsPane : BasePane
     public EffectsPane()
     {
         effectToggles = new(new[] { "dummy" /* thicc */ });
-        effectToggles.ControlEvent += (s, a) => SetEffectPane(effectList[effectToggles.SelectedItemIndex]);
+        effectToggles.ControlEvent += (s, a) =>
+            SetEffectPane(effectList[effectToggles.SelectedItemIndex]);
     }
 
     public override void UpdatePane() =>

+ 33 - 15
src/MeidoPhotoStudio.Plugin/GUI/Panes/BackgroundWindowPanes/LightsPane.cs

@@ -55,28 +55,41 @@ public class LightsPane : BasePane
     public LightsPane(LightManager lightManager)
     {
         this.lightManager = lightManager;
-        this.lightManager.Rotate += (s, a) => UpdateRotation();
-        this.lightManager.Scale += (s, a) => UpdateScale();
-        this.lightManager.Select += (s, a) => UpdateCurrentLight();
-        this.lightManager.ListModified += (s, a) => UpdateList();
+        this.lightManager.Rotate += (s, a) =>
+            UpdateRotation();
+
+        this.lightManager.Scale += (s, a) =>
+            UpdateScale();
+
+        this.lightManager.Select += (s, a) =>
+            UpdateCurrentLight();
+
+        this.lightManager.ListModified += (s, a) =>
+            UpdateList();
 
         lightTypeGrid = new(Translation.GetArray("lightType", lightTypes));
-        lightTypeGrid.ControlEvent += (s, a) => SetCurrentLightType();
+        lightTypeGrid.ControlEvent += (s, a) =>
+            SetCurrentLightType();
 
         lightDropdown = new(new[] { "Main" });
-        lightDropdown.SelectionChange += (s, a) => SetCurrentLight();
+        lightDropdown.SelectionChange += (s, a) =>
+            SetCurrentLight();
 
         addLightButton = new("+");
-        addLightButton.ControlEvent += (s, a) => lightManager.AddLight();
+        addLightButton.ControlEvent += (s, a) =>
+            lightManager.AddLight();
 
         deleteLightButton = new(Translation.Get("lightsPane", "delete"));
-        deleteLightButton.ControlEvent += (s, a) => lightManager.DeleteActiveLight();
+        deleteLightButton.ControlEvent += (s, a) =>
+            lightManager.DeleteActiveLight();
 
         disableToggle = new(Translation.Get("lightsPane", "disable"));
-        disableToggle.ControlEvent += (s, a) => lightManager.CurrentLight.IsDisabled = disableToggle.Value;
+        disableToggle.ControlEvent += (s, a) =>
+            lightManager.CurrentLight.IsDisabled = disableToggle.Value;
 
         clearLightsButton = new(Translation.Get("lightsPane", "clear"));
-        clearLightsButton.ControlEvent += (s, a) => ClearLights();
+        clearLightsButton.ControlEvent += (s, a) =>
+            ClearLights();
 
         var numberOfLightProps = Enum.GetNames(typeof(LightProp)).Length;
 
@@ -93,21 +106,26 @@ public class LightsPane : BasePane
             };
 
             if (lightProp <= LightProp.LightRotY)
-                slider.ControlEvent += (s, a) => SetLightRotation();
+                slider.ControlEvent += (s, a) =>
+                    SetLightRotation();
             else
-                slider.ControlEvent += (s, a) => SetLightProp(lightProp, slider.Value);
+                slider.ControlEvent += (s, a) =>
+                    SetLightProp(lightProp, slider.Value);
 
             lightSlider[lightProp] = slider;
         }
 
         colorToggle = new(Translation.Get("lightsPane", "colour"));
-        colorToggle.ControlEvent += (s, a) => SetColourMode();
+        colorToggle.ControlEvent += (s, a) =>
+            SetColourMode();
 
         resetPropsButton = new(Translation.Get("lightsPane", "resetProperties"));
-        resetPropsButton.ControlEvent += (s, a) => ResetLightProps();
+        resetPropsButton.ControlEvent += (s, a) =>
+            ResetLightProps();
 
         resetPositionButton = new(Translation.Get("lightsPane", "resetPosition"));
-        resetPositionButton.ControlEvent += (s, a) => lightManager.CurrentLight.ResetLightPosition();
+        resetPositionButton.ControlEvent += (s, a) =>
+            lightManager.CurrentLight.ResetLightPosition();
 
         lightHeader = Translation.Get("lightsPane", "header");
         resetLabel = Translation.Get("lightsPane", "resetLabel");

+ 5 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/CallWindowPanes/MaidSelectorPane.cs

@@ -18,15 +18,17 @@ public class MaidSelectorPane : BasePane
         this.meidoManager = meidoManager;
 
         clearMaidsButton = new(Translation.Get("maidCallWindow", "clearButton"));
-        clearMaidsButton.ControlEvent += (s, a) => this.meidoManager.ClearSelectList();
+        clearMaidsButton.ControlEvent += (s, a) =>
+            this.meidoManager.ClearSelectList();
 
         callMaidsButton = new(Translation.Get("maidCallWindow", "callButton"));
-        callMaidsButton.ControlEvent += (s, a) => this.meidoManager.CallMeidos();
+        callMaidsButton.ControlEvent += (s, a) =>
+            this.meidoManager.CallMeidos();
 
         activeMeidoListToggle = new(Translation.Get("maidCallWindow", "activeOnlyToggle"));
         this.meidoManager.BeginCallMeidos += (_, _) =>
         {
-            if (meidoManager.SelectedMeidoSet.Count == 0)
+            if (meidoManager.SelectedMeidoSet.Count is 0)
                 activeMeidoListToggle.Value = false;
         };
     }

+ 8 - 4
src/MeidoPhotoStudio.Plugin/GUI/Panes/FaceWindowPanes/MaidFaceBlendPane.cs

@@ -69,10 +69,12 @@ public class MaidFaceBlendPane : BasePane
         };
 
         prevCategoryButton = new("<");
-        prevCategoryButton.ControlEvent += (s, a) => faceBlendCategoryDropdown.Step(-1);
+        prevCategoryButton.ControlEvent += (s, a) =>
+            faceBlendCategoryDropdown.Step(-1);
 
         nextCategoryButton = new(">");
-        nextCategoryButton.ControlEvent += (s, a) => faceBlendCategoryDropdown.Step(1);
+        nextCategoryButton.ControlEvent += (s, a) =>
+            faceBlendCategoryDropdown.Step(1);
 
         faceBlendDropdown = new(UIFaceList());
         faceBlendDropdown.SelectionChange += (s, a) =>
@@ -84,10 +86,12 @@ public class MaidFaceBlendPane : BasePane
         };
 
         facePrevButton = new("<");
-        facePrevButton.ControlEvent += (s, a) => faceBlendDropdown.Step(-1);
+        facePrevButton.ControlEvent += (s, a) =>
+            faceBlendDropdown.Step(-1);
 
         faceNextButton = new(">");
-        faceNextButton.ControlEvent += (s, a) => faceBlendDropdown.Step(1);
+        faceNextButton.ControlEvent += (s, a) =>
+            faceBlendDropdown.Step(1);
 
         faceListEnabled = CurrentFaceList.Count > 0;
     }

+ 4 - 2
src/MeidoPhotoStudio.Plugin/GUI/Panes/FaceWindowPanes/MaidFaceSliderPane.cs

@@ -114,7 +114,8 @@ public class MaidFaceSliderPane : BasePane
             var slider = new Slider(uiName, 0f, SliderLimits[key]);
             var sliderKey = key;
 
-            slider.ControlEvent += (s, a) => SetFaceValue(sliderKey, slider.Value);
+            slider.ControlEvent += (s, a) =>
+                SetFaceValue(sliderKey, slider.Value);
 
             faceControls[key] = slider;
         }
@@ -125,7 +126,8 @@ public class MaidFaceSliderPane : BasePane
             var toggle = new Toggle(uiName);
             var sliderKey = key;
 
-            toggle.ControlEvent += (s, a) => SetFaceValue(sliderKey, toggle.Value);
+            toggle.ControlEvent += (s, a) =>
+                SetFaceValue(sliderKey, toggle.Value);
 
             faceControls[key] = toggle;
         }

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/FaceWindowPanes/SaveFacePane.cs

@@ -23,7 +23,8 @@ public class SaveFacePane : BasePane
         nameHeader = Translation.Get("faceSave", "nameHeader");
 
         saveFaceButton = new(Translation.Get("faceSave", "saveButton"));
-        saveFaceButton.ControlEvent += (s, a) => SaveFace();
+        saveFaceButton.ControlEvent += (s, a) =>
+            SaveFace();
 
         categoryComboBox = new(Constants.CustomFaceGroupList.ToArray());
 

+ 5 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/BG2WindowPane.cs

@@ -18,7 +18,8 @@ public class BG2WindowPane : BaseMainWindowPane
     {
         this.meidoManager = meidoManager;
         this.propManager = propManager;
-        this.propManager.FromPropSelect += (s, a) => propTabs.SelectedItemIndex = 0;
+        this.propManager.FromPropSelect += (s, a) =>
+            propTabs.SelectedItemIndex = 0;
 
         // should be added in this order
         AddPane(new PropsPane(propManager));
@@ -29,7 +30,8 @@ public class BG2WindowPane : BaseMainWindowPane
         propManagerPane = AddPane(new PropManagerPane(propManager));
 
         propTabs = new(Translation.GetArray("propsPaneTabs", tabNames));
-        propTabs.ControlEvent += (s, a) => currentPropsPane = Panes[propTabs.SelectedItemIndex];
+        propTabs.ControlEvent += (s, a) =>
+            currentPropsPane = Panes[propTabs.SelectedItemIndex];
 
         currentPropsPane = Panes[0];
     }
@@ -41,7 +43,7 @@ public class BG2WindowPane : BaseMainWindowPane
         MpsGui.WhiteLine();
         currentPropsPane.Draw();
 
-        if (propTabs.SelectedItemIndex != 0)
+        if (propTabs.SelectedItemIndex is not 0)
             return;
 
         propManagerPane.Draw();

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/BGWindowPane.cs

@@ -18,7 +18,8 @@ public class BGWindowPane : BaseMainWindowPane
     )
     {
         sceneManagerButton = new(Translation.Get("backgroundWindow", "manageScenesButton"));
-        sceneManagerButton.ControlEvent += (s, a) => sceneWindow.Visible = !sceneWindow.Visible;
+        sceneManagerButton.ControlEvent += (s, a) =>
+            sceneWindow.Visible = !sceneWindow.Visible;
 
         backgroundSelectorPane = AddPane(new BackgroundSelectorPane(environmentManager));
         cameraPane = AddPane(new CameraPane(cameraManager));

+ 2 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/CallWindowPane.cs

@@ -16,9 +16,8 @@ public class CallWindowPane : BaseMainWindowPane
         placementDropdown = new(Translation.GetArray("placementDropdown", MaidPlacementUtility.placementTypes));
 
         placementOKButton = new(Translation.Get("maidCallWindow", "okButton"));
-        placementOKButton.ControlEvent += (o, a) => this.meidoManager.PlaceMeidos(
-            MaidPlacementUtility.placementTypes[placementDropdown.SelectedItemIndex]
-        );
+        placementOKButton.ControlEvent += (o, a) =>
+            this.meidoManager.PlaceMeidos(MaidPlacementUtility.placementTypes[placementDropdown.SelectedItemIndex]);
 
         maidSelectorPane = AddPane(new MaidSelectorPane(this.meidoManager));
     }

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/FaceWindowPane.cs

@@ -22,7 +22,8 @@ public class FaceWindowPane : BaseMainWindowPane
         saveFacePane = AddPane(new SaveFacePane(this.meidoManager));
 
         saveFaceToggle = new(Translation.Get("maidFaceWindow", "savePaneToggle"));
-        saveFaceToggle.ControlEvent += (s, a) => saveFaceMode = !saveFaceMode;
+        saveFaceToggle.ControlEvent += (s, a) =>
+            saveFaceMode = !saveFaceMode;
     }
 
     public override void Draw()

+ 8 - 4
src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/PoseWindowPane.cs

@@ -38,10 +38,12 @@ public class PoseWindowPane : BaseMainWindowPane
         maidFaceLookPane.Enabled = false;
 
         freeLookToggle = new(Translation.Get("freeLookPane", "freeLookToggle"), false);
-        freeLookToggle.ControlEvent += (s, a) => SetMaidFreeLook();
+        freeLookToggle.ControlEvent += (s, a) =>
+            SetMaidFreeLook();
 
         savePoseToggle = new(Translation.Get("posePane", "saveToggle"));
-        savePoseToggle.ControlEvent += (s, a) => savePoseMode = !savePoseMode;
+        savePoseToggle.ControlEvent += (s, a) =>
+            savePoseMode = !savePoseMode;
 
         // TODO: Why are only some panes added to the pane list?
         mpnAttachPropPane = new(this.meidoManager);
@@ -52,13 +54,15 @@ public class PoseWindowPane : BaseMainWindowPane
         copyPosePane = AddPane(new CopyPosePane(this.meidoManager));
 
         saveHandToggle = new(Translation.Get("handPane", "saveToggle"));
-        saveHandToggle.ControlEvent += (s, a) => saveHandMode = !saveHandMode;
+        saveHandToggle.ControlEvent += (s, a) =>
+            saveHandMode = !saveHandMode;
 
         handPresetPane = AddPane(new HandPresetPane(meidoManager));
         saveHandPane = AddPane(new SaveHandPane(meidoManager));
 
         flipButton = new(Translation.Get("flipIK", "flipButton"));
-        flipButton.ControlEvent += (s, a) => this.meidoManager.ActiveMeido.IKManager.Flip();
+        flipButton.ControlEvent += (s, a) =>
+            this.meidoManager.ActiveMeido.IKManager.Flip();
 
         handPresetHeader = Translation.Get("handPane", "header");
         flipIKHeader = Translation.Get("flipIK", "header");

+ 5 - 2
src/MeidoPhotoStudio.Plugin/GUI/Panes/MainWindowPanes/SettingsWindowPane.cs

@@ -37,7 +37,9 @@ public class SettingsWindowPane : BaseMainWindowPane
             var action = (MpsKey)i;
             var button = new KeyRebindButton(KeyCode.None);
 
-            button.ControlEvent += (s, a) => InputManager.Rebind(action, button.KeyCode);
+            button.ControlEvent += (s, a) =>
+                InputManager.Rebind(action, button.KeyCode);
+
             rebindButtons[i] = button;
 
             actionLabels[i] = Translation.Get("controls", actionTranslationKeys[i]);
@@ -47,7 +49,8 @@ public class SettingsWindowPane : BaseMainWindowPane
             headers[headerTranslationKeys[i]] = Translation.Get("settingsHeaders", headerTranslationKeys[i]);
 
         reloadTranslationButton = new(Translation.Get("settingsLabels", "reloadTranslation"));
-        reloadTranslationButton.ControlEvent += (s, a) => Translation.ReinitializeTranslation();
+        reloadTranslationButton.ControlEvent += (s, a) =>
+            Translation.ReinitializeTranslation();
 
         reloadAllPresetsButton = new(Translation.Get("settingsLabels", "reloadAllPresets"));
         reloadAllPresetsButton.ControlEvent += (s, a) =>

+ 12 - 4
src/MeidoPhotoStudio.Plugin/GUI/Panes/OtherPanes/MaidSwitcherPane.cs

@@ -12,16 +12,24 @@ public class MaidSwitcherPane : BasePane
     public MaidSwitcherPane(MeidoManager meidoManager)
     {
         this.meidoManager = meidoManager;
-        this.meidoManager.UpdateMeido += (s, a) => UpdatePane();
+
+        this.meidoManager.UpdateMeido += (s, a) =>
+            UpdatePane();
 
         previousButton = new("<");
-        previousButton.ControlEvent += (s, a) => ChangeMaid(-1);
+
+        previousButton.ControlEvent += (s, a) =>
+            ChangeMaid(-1);
 
         nextButton = new(">");
-        nextButton.ControlEvent += (s, a) => ChangeMaid(1);
+
+        nextButton.ControlEvent += (s, a) =>
+            ChangeMaid(1);
 
         editToggle = new("Edit", true);
-        editToggle.ControlEvent += (s, a) => SetEditMaid();
+
+        editToggle.ControlEvent += (s, a) =>
+            SetEditMaid();
     }
 
     public override void Draw()

+ 5 - 2
src/MeidoPhotoStudio.Plugin/GUI/Panes/OtherPanes/TabsPane.cs

@@ -21,9 +21,12 @@ public class TabsPane : BasePane
 
     public TabsPane()
     {
-        Translation.ReloadTranslationEvent += (s, a) => ReloadTranslation();
+        Translation.ReloadTranslationEvent += (s, a) =>
+            ReloadTranslation();
+
         Tabs = new(Translation.GetArray("tabs", tabNames));
-        Tabs.ControlEvent += (s, a) => OnChangeTab();
+        Tabs.ControlEvent += (s, a) =>
+            OnChangeTab();
     }
 
     public override void Draw()

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/CopyPosePane.cs

@@ -27,7 +27,8 @@ public class CopyPosePane : BasePane
         meidoDropdown = new(new[] { Translation.Get("systemMessage", "noMaids") });
 
         copyButton = new(Translation.Get("copyPosePane", "copyButton"));
-        copyButton.ControlEvent += (s, a) => CopyPose();
+        copyButton.ControlEvent += (s, a) =>
+            CopyPose();
 
         copyIKHeader = Translation.Get("copyPosePane", "header");
     }

+ 6 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/GravityControlPane.cs

@@ -16,13 +16,16 @@ public class GravityControlPane : BasePane
         this.meidoManager = meidoManager;
 
         hairToggle = new(Translation.Get("gravityControlPane", "hairToggle"));
-        hairToggle.ControlEvent += (s, a) => ToggleGravity(hairToggle.Value, skirt: false);
+        hairToggle.ControlEvent += (s, a) =>
+            ToggleGravity(hairToggle.Value, skirt: false);
 
         skirtToggle = new(Translation.Get("gravityControlPane", "skirtToggle"));
-        skirtToggle.ControlEvent += (s, a) => ToggleGravity(skirtToggle.Value, skirt: true);
+        skirtToggle.ControlEvent += (s, a) =>
+            ToggleGravity(skirtToggle.Value, skirt: true);
 
         globalToggle = new(Translation.Get("gravityControlPane", "globalToggle"));
-        globalToggle.ControlEvent += (s, a) => SetGlobalGravity(globalToggle.Value);
+        globalToggle.ControlEvent += (s, a) =>
+            SetGlobalGravity(globalToggle.Value);
 
         header = Translation.Get("gravityControlPane", "gravityHeader");
     }

+ 15 - 8
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/HandPresetPane.cs

@@ -36,27 +36,34 @@ public class HandPresetPane : BasePane
         this.meidoManager = meidoManager;
 
         presetCategoryDropdown = new(Constants.CustomHandGroupList.ToArray());
-        presetCategoryDropdown.SelectionChange += (s, a) => ChangePresetCategory();
+        presetCategoryDropdown.SelectionChange += (s, a) =>
+            ChangePresetCategory();
 
         nextCategoryButton = new(">");
-        nextCategoryButton.ControlEvent += (s, a) => presetCategoryDropdown.Step(1);
+        nextCategoryButton.ControlEvent += (s, a) =>
+            presetCategoryDropdown.Step(1);
 
         previousCategoryButton = new("<");
-        previousCategoryButton.ControlEvent += (s, a) => presetCategoryDropdown.Step(-1);
+        previousCategoryButton.ControlEvent += (s, a) =>
+            presetCategoryDropdown.Step(-1);
 
         presetDropdown = new(UIPresetList());
 
         nextPresetButton = new(">");
-        nextPresetButton.ControlEvent += (s, a) => presetDropdown.Step(1);
+        nextPresetButton.ControlEvent += (s, a) =>
+            presetDropdown.Step(1);
 
         previousPresetButton = new("<");
-        previousPresetButton.ControlEvent += (s, a) => presetDropdown.Step(-1);
+        previousPresetButton.ControlEvent += (s, a) =>
+            presetDropdown.Step(-1);
 
         leftHandButton = new(Translation.Get("handPane", "leftHand"));
-        leftHandButton.ControlEvent += (s, a) => SetHandPreset(right: false);
+        leftHandButton.ControlEvent += (s, a) =>
+            SetHandPreset(right: false);
 
         rightHandButton = new(Translation.Get("handPane", "rightHand"));
-        rightHandButton.ControlEvent += (s, a) => SetHandPreset(right: true);
+        rightHandButton.ControlEvent += (s, a) =>
+            SetHandPreset(right: true);
 
         previousCategory = SelectedCategory;
         presetListEnabled = CurrentPresetList.Count > 0;
@@ -67,7 +74,7 @@ public class HandPresetPane : BasePane
         leftHandButton.Label = Translation.Get("handPane", "leftHand");
         rightHandButton.Label = Translation.Get("handPane", "rightHand");
 
-        if (CurrentPresetList.Count == 0)
+        if (CurrentPresetList.Count is 0)
             presetDropdown.SetDropdownItems(UIPresetList());
     }
 

+ 16 - 9
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidDressingPane.cs

@@ -58,25 +58,32 @@ public class MaidDressingPane : BasePane
         {
             var slotToggle = new Toggle(Translation.Get("clothing", slot.ToString()));
 
-            slotToggle.ControlEvent += (s, a) => ToggleClothing(slot, slotToggle.Value);
+            slotToggle.ControlEvent += (s, a) =>
+                ToggleClothing(slot, slotToggle.Value);
+
             clothingToggles.Add(slot, slotToggle);
             loadedSlots[slot] = true;
         }
 
         detailedClothingToggle = new(Translation.Get("clothing", "detail"));
-        detailedClothingToggle.ControlEvent += (s, a) => UpdateDetailedClothing();
+        detailedClothingToggle.ControlEvent += (s, a) =>
+            UpdateDetailedClothing();
 
         curlingFrontToggle = new(Translation.Get("clothing", "curlingFront"));
-        curlingFrontToggle.ControlEvent += (s, a) => ToggleCurling(Curl.Front, curlingFrontToggle.Value);
+        curlingFrontToggle.ControlEvent += (s, a) =>
+            ToggleCurling(Curl.Front, curlingFrontToggle.Value);
 
         curlingBackToggle = new(Translation.Get("clothing", "curlingBack"));
-        curlingBackToggle.ControlEvent += (s, a) => ToggleCurling(Curl.Back, curlingBackToggle.Value);
+        curlingBackToggle.ControlEvent += (s, a) =>
+            ToggleCurling(Curl.Back, curlingBackToggle.Value);
 
         pantsuShiftToggle = new(Translation.Get("clothing", "shiftPanties"));
-        pantsuShiftToggle.ControlEvent += (s, a) => ToggleCurling(Curl.Shift, pantsuShiftToggle.Value);
+        pantsuShiftToggle.ControlEvent += (s, a) =>
+            ToggleCurling(Curl.Shift, pantsuShiftToggle.Value);
 
         maskModeGrid = new(Translation.GetArray("clothing", maskLabels));
-        maskModeGrid.ControlEvent += (s, a) => SetMaskMode((Mask)maskModeGrid.SelectedItemIndex);
+        maskModeGrid.ControlEvent += (s, a) =>
+            SetMaskMode((Mask)maskModeGrid.SelectedItemIndex);
 
         UpdateDetailedClothing();
     }
@@ -96,7 +103,7 @@ public class MaidDressingPane : BasePane
             var toggleValue = false;
             var hasSlot = false;
 
-            if (clothingSlot == SlotID.wear)
+            if (clothingSlot is SlotID.wear)
             {
                 foreach (var wearSlot in WearSlots)
                 {
@@ -110,12 +117,12 @@ public class MaidDressingPane : BasePane
                         break;
                 }
             }
-            else if (clothingSlot == SlotID.megane)
+            else if (clothingSlot is SlotID.megane)
             {
                 toggleValue = body.GetMask(SlotID.megane) || body.GetMask(SlotID.accHead);
                 hasSlot = body.GetSlotLoaded(SlotID.megane) || body.GetSlotLoaded(SlotID.accHead);
             }
-            else if (!detailedClothing && clothingSlot == SlotID.headset)
+            else if (!detailedClothing && clothingSlot is SlotID.headset)
             {
                 foreach (var headwearSlot in HeadwearSlots)
                 {

+ 8 - 4
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidFreeLookPane.cs

@@ -17,16 +17,20 @@ public class MaidFaceLookPane : BasePane
         this.meidoManager = meidoManager;
 
         lookXSlider = new(Translation.Get("freeLookPane", "xSlider"), -0.6f, 0.6f);
-        lookXSlider.ControlEvent += (s, a) => SetMaidLook();
+        lookXSlider.ControlEvent += (s, a) =>
+            SetMaidLook();
 
         lookYSlider = new(Translation.Get("freeLookPane", "ySlider"), 0.5f, -0.55f);
-        lookYSlider.ControlEvent += (s, a) => SetMaidLook();
+        lookYSlider.ControlEvent += (s, a) =>
+            SetMaidLook();
 
         headToCamToggle = new(Translation.Get("freeLookPane", "headToCamToggle"));
-        headToCamToggle.ControlEvent += (s, a) => SetHeadToCam(headToCamToggle.Value, eye: false);
+        headToCamToggle.ControlEvent += (s, a) =>
+            SetHeadToCam(headToCamToggle.Value, eye: false);
 
         eyeToCamToggle = new(Translation.Get("freeLookPane", "eyeToCamToggle"));
-        eyeToCamToggle.ControlEvent += (s, a) => SetHeadToCam(eyeToCamToggle.Value, eye: true);
+        eyeToCamToggle.ControlEvent += (s, a) =>
+            SetHeadToCam(eyeToCamToggle.Value, eye: true);
 
         bindLabel = Translation.Get("freeLookPane", "bindLabel");
     }

+ 6 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidIKPane.cs

@@ -18,13 +18,16 @@ public class MaidIKPane : BasePane
         this.meidoManager = meidoManager;
 
         ikToggle = new(Translation.Get("maidPoseWindow", "ikToggle"), true);
-        ikToggle.ControlEvent += (s, a) => SetIK(IKToggle.IK, ikToggle.Value);
+        ikToggle.ControlEvent += (s, a) =>
+            SetIK(IKToggle.IK, ikToggle.Value);
 
         releaseIKToggle = new(Translation.Get("maidPoseWindow", "releaseToggle"));
-        releaseIKToggle.ControlEvent += (s, a) => SetIK(IKToggle.Release, releaseIKToggle.Value);
+        releaseIKToggle.ControlEvent += (s, a) =>
+            SetIK(IKToggle.Release, releaseIKToggle.Value);
 
         boneIKToggle = new(Translation.Get("maidPoseWindow", "boneToggle"));
-        boneIKToggle.ControlEvent += (s, a) => SetIK(IKToggle.Bone, boneIKToggle.Value);
+        boneIKToggle.ControlEvent += (s, a) =>
+            SetIK(IKToggle.Bone, boneIKToggle.Value);
     }
 
     public override void UpdatePane()

+ 16 - 9
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MaidPoseSelectorPane.cs

@@ -49,27 +49,34 @@ public class MaidPoseSelectorPane : BasePane
         this.meidoManager = meidoManager;
 
         poseModeGrid = new(Translation.GetArray("posePane", tabTranslations));
-        poseModeGrid.ControlEvent += (s, a) => SetPoseMode();
+        poseModeGrid.ControlEvent += (s, a) =>
+            SetPoseMode();
 
         poseGroupDropdown = new(Translation.GetArray("poseGroupDropdown", Constants.PoseGroupList));
-        poseGroupDropdown.SelectionChange += (s, a) => ChangePoseGroup();
+        poseGroupDropdown.SelectionChange += (s, a) =>
+            ChangePoseGroup();
 
         poseDropdown = new(UIPoseList());
-        poseDropdown.SelectionChange += (s, a) => ChangePose();
+        poseDropdown.SelectionChange += (s, a) =>
+            ChangePose();
 
         poseGroupLeftButton = new("<");
-        poseGroupLeftButton.ControlEvent += (s, a) => poseGroupDropdown.Step(-1);
+        poseGroupLeftButton.ControlEvent += (s, a) =>
+            poseGroupDropdown.Step(-1);
 
         poseGroupRightButton = new(">");
-        poseGroupRightButton.ControlEvent += (s, a) => poseGroupDropdown.Step(1);
+        poseGroupRightButton.ControlEvent += (s, a) =>
+            poseGroupDropdown.Step(1);
 
         poseLeftButton = new("<");
-        poseLeftButton.ControlEvent += (s, a) => poseDropdown.Step(-1);
+        poseLeftButton.ControlEvent += (s, a) =>
+            poseDropdown.Step(-1);
 
         poseRightButton = new(">");
-        poseRightButton.ControlEvent += (s, a) => poseDropdown.Step(1);
+        poseRightButton.ControlEvent += (s, a) =>
+            poseDropdown.Step(1);
 
-        customPoseMode = poseModeGrid.SelectedItemIndex == 1;
+        customPoseMode = poseModeGrid.SelectedItemIndex is 1;
         previousPoseGroup = SelectedPoseGroup;
         poseListEnabled = CurrentPoseList.Count > 0;
     }
@@ -237,7 +244,7 @@ public class MaidPoseSelectorPane : BasePane
     }
 
     private string[] UIPoseList() =>
-        CurrentPoseList.Count == 0
+        CurrentPoseList.Count is 0
             ? new[] { "No Poses" }
             : CurrentPoseList
                 .Select((pose, i) => $"{i + 1}:{(customPoseMode ? Path.GetFileNameWithoutExtension(pose) : pose)}")

+ 10 - 5
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/MpnAttachPropPane.cs

@@ -28,19 +28,24 @@ public class MpnAttachPropPane : BasePane
         SetDropdownList();
 
         previousPropButton = new("<");
-        previousPropButton.ControlEvent += (s, a) => mpnAttachDropdown.Step(-1);
+        previousPropButton.ControlEvent += (s, a) =>
+            mpnAttachDropdown.Step(-1);
 
         nextPropButton = new(">");
-        nextPropButton.ControlEvent += (s, a) => mpnAttachDropdown.Step(1);
+        nextPropButton.ControlEvent += (s, a) =>
+            mpnAttachDropdown.Step(1);
 
         attachPropButton = new(Translation.Get("attachMpnPropPane", "attachButton"));
-        attachPropButton.ControlEvent += (s, a) => AttachProp();
+        attachPropButton.ControlEvent += (s, a) =>
+            AttachProp();
 
         detachPropButton = new(Translation.Get("attachMpnPropPane", "detachButton"));
-        detachPropButton.ControlEvent += (s, a) => AttachProp(detach: true);
+        detachPropButton.ControlEvent += (s, a) =>
+            AttachProp(detach: true);
 
         detachAllButton = new(Translation.Get("attachMpnPropPane", "detachAllButton"));
-        detachAllButton.ControlEvent += (s, a) => DetachAll();
+        detachAllButton.ControlEvent += (s, a) =>
+            DetachAll();
 
         header = Translation.Get("attachMpnPropPane", "header");
     }

+ 4 - 2
src/MeidoPhotoStudio.Plugin/GUI/Panes/PoseWindowPanes/SaveHandPane.cs

@@ -25,10 +25,12 @@ public class SaveHandPane : BasePane
         nameHeader = Translation.Get("handPane", "nameHeader");
 
         saveLeftHandButton = new(Translation.Get("handPane", "saveLeftButton"));
-        saveLeftHandButton.ControlEvent += (s, a) => SaveHand(right: false);
+        saveLeftHandButton.ControlEvent += (s, a) =>
+            SaveHand(right: false);
 
         saveRightHandButton = new(Translation.Get("handPane", "saveRightButton"));
-        saveRightHandButton.ControlEvent += (s, a) => SaveHand(right: true);
+        saveRightHandButton.ControlEvent += (s, a) =>
+            SaveHand(right: true);
 
         categoryComboBox = new(Constants.CustomHandGroupList.ToArray());
 

+ 6 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/SceneManagerPanes/SceneManagerDirectoryPane.cs

@@ -23,10 +23,12 @@ public class SceneManagerDirectoryPane : BasePane
         this.sceneModalWindow = sceneModalWindow;
 
         createDirectoryButton = new(Translation.Get("sceneManager", "createDirectoryButton"));
-        createDirectoryButton.ControlEvent += (s, a) => createDirectoryMode = true;
+        createDirectoryButton.ControlEvent += (s, a) =>
+            createDirectoryMode = true;
 
         deleteDirectoryButton = new(Translation.Get("sceneManager", "deleteDirectoryButton"));
-        deleteDirectoryButton.ControlEvent += (s, a) => this.sceneModalWindow.ShowDirectoryDialogue();
+        deleteDirectoryButton.ControlEvent += (s, a) =>
+            this.sceneModalWindow.ShowDirectoryDialogue();
 
         directoryTextField = new();
         directoryTextField.ControlEvent += (s, a) =>
@@ -37,7 +39,8 @@ public class SceneManagerDirectoryPane : BasePane
         };
 
         cancelButton = new("X");
-        cancelButton.ControlEvent += (s, a) => createDirectoryMode = false;
+        cancelButton.ControlEvent += (s, a) =>
+            createDirectoryMode = false;
     }
 
     public override void Draw()

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Panes/SceneManagerPanes/SceneManagerScenePane.cs

@@ -16,7 +16,8 @@ public class SceneManagerScenePane : BasePane
         this.sceneModalWindow = sceneModalWindow;
 
         addSceneButton = new("+");
-        addSceneButton.ControlEvent += (s, a) => sceneManager.SaveScene(overwrite: false);
+        addSceneButton.ControlEvent += (s, a) =>
+            sceneManager.SaveScene(overwrite: false);
     }
 
     public override void Draw()

+ 6 - 3
src/MeidoPhotoStudio.Plugin/GUI/Panes/SceneManagerPanes/SceneManagerTitleBar.cs

@@ -21,10 +21,12 @@ public class SceneManagerTitleBarPane : BasePane
     {
         this.sceneManager = sceneManager;
         kankyoToggle = new(Translation.Get("sceneManager", "kankyoToggle"));
-        kankyoToggle.ControlEvent += (s, a) => sceneManager.ToggleKankyoMode();
+        kankyoToggle.ControlEvent += (s, a) =>
+            sceneManager.ToggleKankyoMode();
 
         refreshButton = new(Translation.Get("sceneManager", "refreshButton"));
-        refreshButton.ControlEvent += (s, a) => sceneManager.Refresh();
+        refreshButton.ControlEvent += (s, a) =>
+            sceneManager.Refresh();
 
         sortDropdown = new(Translation.GetArray("sceneManager", sortModes), (int)sceneManager.CurrentSortMode);
         sortDropdown.SelectionChange += (s, a) =>
@@ -45,7 +47,8 @@ public class SceneManagerTitleBarPane : BasePane
         };
 
         closeButton = new("X");
-        closeButton.ControlEvent += (s, a) => CloseChange?.Invoke(this, System.EventArgs.Empty);
+        closeButton.ControlEvent += (s, a) =>
+            CloseChange?.Invoke(this, System.EventArgs.Empty);
 
         sortLabel = Translation.Get("sceneManager", "sortLabel");
     }

+ 1 - 1
src/MeidoPhotoStudio.Plugin/GUI/Windows/BaseWindow.cs

@@ -84,7 +84,7 @@ public abstract class BaseWindow : BasePane
 
     private void HandleZoom()
     {
-        if (Input.mouseScrollDelta.y == 0f || !Visible)
+        if (Input.mouseScrollDelta.y is 0f || !Visible)
             return;
 
         var mousePos = new Vector2(Input.mousePosition.x, Screen.height - Input.mousePosition.y);

+ 7 - 4
src/MeidoPhotoStudio.Plugin/GUI/Windows/MainWindow.cs

@@ -47,16 +47,19 @@ public class MainWindow : BaseWindow
         this.meidoManager.UpdateMeido += UpdateMeido;
 
         this.propManager = propManager;
-        this.propManager.FromPropSelect += (s, a) => ChangeWindow(Constants.Window.BG2);
+        this.propManager.FromPropSelect += (s, a) =>
+            ChangeWindow(Constants.Window.BG2);
 
         this.lightManager = lightManager;
-        this.lightManager.Select += (s, a) => ChangeWindow(Constants.Window.BG);
+        this.lightManager.Select += (s, a) =>
+            ChangeWindow(Constants.Window.BG);
 
         windowPanes = new();
         WindowRect = new(Screen.width, Screen.height * 0.08f, 240f, Screen.height * 0.9f);
 
         tabsPane = new();
-        tabsPane.TabChange += (s, a) => ChangeTab();
+        tabsPane.TabChange += (s, a) =>
+            ChangeTab();
 
         settingsButtonLabel = Translation.Get("settingsLabels", "settingsButton");
         closeButtonLabel = Translation.Get("settingsLabels", "closeSettingsButton");
@@ -64,7 +67,7 @@ public class MainWindow : BaseWindow
         settingsButton = new(settingsButtonLabel);
         settingsButton.ControlEvent += (s, a) =>
         {
-            if (selectedWindow == Constants.Window.Settings)
+            if (selectedWindow is Constants.Window.Settings)
                 ChangeTab();
             else
             {

+ 5 - 3
src/MeidoPhotoStudio.Plugin/GUI/Windows/SceneModalWindow.cs

@@ -61,10 +61,12 @@ public class SceneModalWindow : BaseWindow
         windowRect.y = MiddlePosition.y;
 
         okButton = new(sceneLoadCommit);
-        okButton.ControlEvent += (s, a) => Commit();
+        okButton.ControlEvent += (s, a) =>
+            Commit();
 
         cancelButton = new("Cancel");
-        cancelButton.ControlEvent += (s, a) => Cancel();
+        cancelButton.ControlEvent += (s, a) =>
+            Cancel();
 
         deleteButton = new("Delete");
         deleteButton.ControlEvent += (s, a) =>
@@ -112,7 +114,7 @@ public class SceneModalWindow : BaseWindow
 
             var infoString = scene.Environment
                 ? infoKankyo
-                : string.Format(scene.NumberOfMaids == 1 ? infoMaidSingular : infoMaidPlural, scene.NumberOfMaids);
+                : string.Format(scene.NumberOfMaids is 1 ? infoMaidSingular : infoMaidPlural, scene.NumberOfMaids);
 
             var labelSize = labelStyle.CalcSize(new GUIContent(infoString));
 

+ 2 - 1
src/MeidoPhotoStudio.Plugin/GUI/Windows/SceneWindow.cs

@@ -40,7 +40,8 @@ public class SceneWindow : BaseWindow
         var sceneModalWindow = new SceneModalWindow(this.sceneManager);
 
         titleBar = AddPane(new SceneManagerTitleBarPane(sceneManager));
-        titleBar.CloseChange += (s, a) => Visible = false;
+        titleBar.CloseChange += (s, a) =>
+            Visible = false;
 
         directoryList = AddPane(new SceneManagerDirectoryPane(sceneManager, sceneModalWindow));
 

+ 2 - 2
src/MeidoPhotoStudio.Plugin/Managers/EffectManagers/BloomEffectManager.cs

@@ -110,7 +110,7 @@ public class BloomEffectManager : IEffectManager
             initialBlurIterations = blurIterations = Bloom.bloomBlurIterations;
             initialThresholdColour = bloomThresholdColour = Bloom.bloomThreshholdColor;
             initialHDRBloomMode = Bloom.hdr;
-            bloomHdr = Bloom.hdr == Bloom.HDRBloomMode.On;
+            bloomHdr = Bloom.hdr is Bloom.HDRBloomMode.On;
 
             backupBloomValue = GameMain.Instance.CMSystem.BloomValue;
         }
@@ -123,7 +123,7 @@ public class BloomEffectManager : IEffectManager
         BloomValue = initialIntensity;
         BlurIterations = initialBlurIterations;
         BloomThresholdColour = initialThresholdColour;
-        BloomHDR = initialHDRBloomMode == Bloom.HDRBloomMode.On;
+        BloomHDR = initialHDRBloomMode is Bloom.HDRBloomMode.On;
         BloomHDR = false;
         Active = false;
 

+ 2 - 2
src/MeidoPhotoStudio.Plugin/Managers/LightManager.cs

@@ -106,7 +106,7 @@ public class LightManager : IManager
 
     public void DeleteActiveLight()
     {
-        if (selectedLightIndex == 0)
+        if (selectedLightIndex is 0)
             return;
 
         DeleteLight(SelectedLightIndex);
@@ -114,7 +114,7 @@ public class LightManager : IManager
 
     public void DeleteLight(int lightIndex, bool noUpdate = false)
     {
-        if (lightIndex == 0)
+        if (lightIndex is 0)
             return;
 
         DestroyLight(lightList[lightIndex]);

+ 3 - 3
src/MeidoPhotoStudio.Plugin/Managers/MeidoManager.cs

@@ -253,7 +253,7 @@ public class MeidoManager : IManager
 
         UnloadMeidos();
 
-        if (SelectMeidoList.Count == 0)
+        if (SelectMeidoList.Count is 0)
         {
             OnEndCallMeidos(this, EventArgs.Empty);
 
@@ -263,7 +263,7 @@ public class MeidoManager : IManager
         void callMeidos() =>
             GameMain.Instance.StartCoroutine(LoadMeidos());
 
-        if (MeidoPhotoStudio.EditMode && !moreThanEditMaid && SelectMeidoList.Count == 1)
+        if (MeidoPhotoStudio.EditMode && !moreThanEditMaid && SelectMeidoList.Count is 1)
             callMeidos();
         else
             GameMain.Instance.MainCamera.FadeOut(0.01f, f_bSkipable: false, f_dg: callMeidos);
@@ -412,7 +412,7 @@ public class MeidoUpdateEventArgs : EventArgs
     public bool FromMeido { get; }
 
     public bool IsEmpty =>
-        this == Empty || SelectedMeido == -1 && !FromMeido && IsBody;
+        this == Empty || SelectedMeido is -1 && !FromMeido && IsBody;
 
     public MeidoUpdateEventArgs(int meidoIndex = -1, bool fromMaid = false, bool isBody = true)
     {

+ 3 - 3
src/MeidoPhotoStudio.Plugin/Managers/PropManager.cs

@@ -76,7 +76,7 @@ public class PropManager : IManager
         modItemsOnly.Value;
 
     public DragPointProp CurrentProp =>
-        PropCount == 0 ? null : propList[CurrentPropIndex];
+        PropCount is 0 ? null : propList[CurrentPropIndex];
 
     private readonly List<DragPointProp> propList = new();
     private readonly MeidoManager meidoManager;
@@ -88,7 +88,7 @@ public class PropManager : IManager
     private int currentPropIndex;
 
     public string[] PropNameList =>
-        propList.Count == 0
+        propList.Count is 0
             ? new[] { Translation.Get("systemMessage", "noProps") }
             : propList.Select(prop => prop.Name).ToArray();
 
@@ -100,7 +100,7 @@ public class PropManager : IManager
         get => currentPropIndex;
         set
         {
-            if (PropCount == 0)
+            if (PropCount is 0)
             {
                 currentPropIndex = 0;
 

+ 2 - 2
src/MeidoPhotoStudio.Plugin/Managers/SceneManager.cs

@@ -49,7 +49,7 @@ public class SceneManager : IManager
         KankyoMode ? Constants.kankyoPath : Constants.scenesPath;
 
     public string CurrentScenesDirectory =>
-        CurrentDirectoryIndex == 0 ? CurrentBasePath : Path.Combine(CurrentBasePath, CurrentDirectoryName);
+        CurrentDirectoryIndex is 0 ? CurrentBasePath : Path.Combine(CurrentBasePath, CurrentDirectoryName);
 
     public SortMode CurrentSortMode
     {
@@ -58,7 +58,7 @@ public class SceneManager : IManager
     }
 
     public MPSScene CurrentScene =>
-        SceneList.Count == 0 ? null : SceneList[CurrentSceneIndex];
+        SceneList.Count is 0 ? null : SceneList[CurrentSceneIndex];
 
     private int SortDirection =>
         SortDescending ? -1 : 1;

+ 1 - 1
src/MeidoPhotoStudio.Plugin/Meido/IK/DragPointPelvis.cs

@@ -10,7 +10,7 @@ public class DragPointPelvis : DragPointMeido
 
     protected override void ApplyDragType()
     {
-        if (CurrentDragType == DragType.Ignore)
+        if (CurrentDragType is DragType.Ignore)
             ApplyProperties();
         else if (IsBone)
             ApplyProperties(false, false, false);

+ 2 - 1
src/MeidoPhotoStudio.Plugin/Meido/IK/DragPointSpine.cs

@@ -16,7 +16,8 @@ public class DragPointSpine : DragPointMeido
         base.AddGizmo(scale, mode);
 
         if (isHead)
-            Gizmo.GizmoDrag += (s, a) => meido.HeadToCam = false;
+            Gizmo.GizmoDrag += (s, a) =>
+                meido.HeadToCam = false;
     }
 
     public override void Set(Transform myObject)

+ 3 - 1
src/MeidoPhotoStudio.Plugin/Meido/Meido.cs

@@ -206,8 +206,10 @@ public class Meido
     {
         StockNo = stockMaidIndex;
         Maid = GameMain.Instance.CharacterMgr.GetStockMaid(stockMaidIndex);
+
         IKManager = new(this);
-        IKManager.SelectMaid += (s, args) => OnUpdateMeido(args);
+        IKManager.SelectMaid += (s, args) =>
+            OnUpdateMeido(args);
     }
 
     public void Load(int slot)

+ 5 - 2
src/MeidoPhotoStudio.Plugin/MeidoPhotoStudio.cs

@@ -423,8 +423,11 @@ public class MeidoPhotoStudio : BaseUnityPlugin
         effectManager.AddManager<SepiaToneEffectManger>();
         effectManager.AddManager<BlurEffectManager>();
 
-        meidoManager.BeginCallMeidos += (s, a) => uiActive = false;
-        meidoManager.EndCallMeidos += (s, a) => uiActive = true;
+        meidoManager.BeginCallMeidos += (s, a) =>
+            uiActive = false;
+
+        meidoManager.EndCallMeidos += (s, a) =>
+            uiActive = true;
 
         var maidSwitcherPane = new MaidSwitcherPane(meidoManager);
 

+ 1 - 1
src/MeidoPhotoStudio.Plugin/Serialization/Serializers/ManagerSerializers/EffectManagerSerializer.cs

@@ -35,7 +35,7 @@ public class EffectManagerSerializer : Serializer<EffectManager>
 
         string header;
 
-        while ((header = reader.ReadString()) != EffectManager.footer)
+        while ((header = reader.ReadString()) is not EffectManager.footer)
         {
             var effectManager = headerToManager[header];
 

+ 1 - 1
src/MeidoPhotoStudio.Plugin/Serialization/Serializers/ManagerSerializers/PropManagerSerializer.cs

@@ -21,7 +21,7 @@ public class PropManagerSerializer : Serializer<PropManager>
 
         var transform = prop.MyObject;
 
-        if (attachPointInfo.AttachPoint != AttachPoint.None)
+        if (attachPointInfo.AttachPoint is not AttachPoint.None)
         {
             manager.AttachProp(prop, attachPointInfo.AttachPoint, attachPointInfo.MaidIndex);
             transform.localPosition = transformDto.LocalPosition;

+ 2 - 2
src/MeidoPhotoStudio.Plugin/Serialization/Serializers/MeidoSerializer.cs

@@ -87,12 +87,12 @@ public class MeidoSerializer : Serializer<Meido>
         {
             var value = true;
 
-            if (clothingSlot == TBody.SlotID.wear)
+            if (clothingSlot is TBody.SlotID.wear)
             {
                 if (MaidDressingPane.WearSlots.Any(slot => body.GetSlotLoaded(slot)))
                     value = MaidDressingPane.WearSlots.Any(slot => body.GetMask(slot));
             }
-            else if (clothingSlot == TBody.SlotID.megane)
+            else if (clothingSlot is TBody.SlotID.megane)
             {
                 var slots = new[] { TBody.SlotID.megane, TBody.SlotID.accHead };