Browse Source

Remove dependency on IsExternalInit

Only got it to add support for records but records need more than
IsExternalInit for a while now.
habeebweeb 2 years ago
parent
commit
323694334c

+ 0 - 1
MeidoPhotoStudio.Plugin.sln

@@ -19,7 +19,6 @@ Global
 		{19D28B0C-3537-4FEE-B7B3-1ABF70B16D5E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{19D28B0C-3537-4FEE-B7B3-1ABF70B16D5E}.Debug|Any CPU.Build.0 = Debug|Any CPU
 		{19D28B0C-3537-4FEE-B7B3-1ABF70B16D5E}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{19D28B0C-3537-4FEE-B7B3-1ABF70B16D5E}.Release|Any CPU.Build.0 = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE

+ 4 - 4
src/MeidoPhotoStudio.Plugin/DragPoint/DragPointProp.cs

@@ -88,10 +88,10 @@ namespace MeidoPhotoStudio.Plugin
         public enum PropType { Mod, MyRoom, Bg, Odogu }
 
         public PropType Type { get; }
-        public string IconFile { get; init; }
-        public string Filename { get; init; }
-        public string SubFilename { get; init; }
-        public int MyRoomID { get; init; }
+        public string IconFile { get; set; }
+        public string Filename { get; set; }
+        public string SubFilename { get; set; }
+        public int MyRoomID { get; set; }
 
         public PropInfo(PropType type) => Type = type;
 

+ 18 - 28
src/MeidoPhotoStudio.Plugin/MeidoPhotoStudio.Plugin.csproj

@@ -1,38 +1,28 @@
 <Project Sdk="Microsoft.Net.Sdk">
     <PropertyGroup>
         <TargetFramework>net35</TargetFramework>
-        <AssemblyVersion>0.0</AssemblyVersion>
-        <FileVersion>0.0.0</FileVersion>
-        <GenerateAssemblyInfo>true</GenerateAssemblyInfo>
-        <FrameworkPathOverride Condition="'$(TargetFramework)' == 'net35'">$(MSBuildProgramFiles32)\Reference Assemblies\Microsoft\Framework\.NETFramework\v3.5\Profile\Client</FrameworkPathOverride>
         <LangVersion>9</LangVersion>
+        <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
+        <Configurations>Debug;Release</Configurations>
+        <Platforms>AnyCPU</Platforms>
     </PropertyGroup>
+
+    <PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
+        <DefineConstants>DEBUG;TRACE</DefineConstants>
+    </PropertyGroup>
+
     <ItemGroup>
-        <Reference Include="Assembly-CSharp">
-            <HintPath>..\..\lib\Assembly-CSharp.dll</HintPath>
-        </Reference>
-        <Reference Include="Assembly-CSharp-firstpass">
-            <HintPath>..\..\lib\Assembly-CSharp-firstpass.dll</HintPath>
-        </Reference>
-        <Reference Include="Assembly-UnityScript-firstpass">
-            <HintPath>..\..\lib\Assembly-UnityScript-firstpass.dll</HintPath>
-        </Reference>
-        <Reference Include="UnityEngine">
-            <HintPath>..\..\lib\UnityEngine.dll</HintPath>
-        </Reference>
-        <Reference Include="Newtonsoft.Json">
-            <HintPath>..\..\lib\Newtonsoft.Json.dll</HintPath>
-        </Reference>
-        <Reference Include="Ionic.Zlib">
-            <HintPath>..\..\lib\Ionic.Zlib.dll</HintPath>
-        </Reference>
-        <Reference Include="BepInEx">
-            <HintPath>..\..\lib\BepInEx.dll</HintPath>
-        </Reference>
-        <Reference Include="0Harmony">
-            <HintPath>..\..\lib\0Harmony.dll</HintPath>
-        </Reference>
+        <Reference Include="..\..\lib\Assembly-CSharp.dll" />
+        <Reference Include="..\..\lib\Assembly-CSharp-firstpass.dll" />
+        <Reference Include="..\..\lib\Assembly-UnityScript-firstpass.dll" />
+        <Reference Include="..\..\lib\UnityEngine.dll" />
+        <Reference Include="..\..\lib\UnityEngine.UI.dll" />
+        <Reference Include="..\..\lib\Newtonsoft.Json.dll" />
+        <Reference Include="..\..\lib\Ionic.Zlib.dll" />
+        <Reference Include="..\..\lib\BepInEx.dll" />
+        <Reference Include="..\..\lib\0Harmony.dll" />
     </ItemGroup>
+
     <ItemGroup>
         <Content Include="Config\**">
             <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>

+ 4 - 4
src/MeidoPhotoStudio.Plugin/Serialization/SceneMetadata.cs

@@ -4,10 +4,10 @@ namespace MeidoPhotoStudio.Plugin
 {
     public class SceneMetadata
     {
-        public short Version { get; init; }
-        public bool Environment { get; init; }
-        public int MaidCount { get; init; }
-        public bool MMConverted { get; init; }
+        public short Version { get; set; }
+        public bool Environment { get; set; }
+        public int MaidCount { get; set; }
+        public bool MMConverted { get; set; }
 
         public void WriteMetadata(BinaryWriter writer)
         {

+ 4 - 4
src/MeidoPhotoStudio.Plugin/Serialization/SimpleSerializers/DragPointPropDTOSerializer.cs

@@ -41,10 +41,10 @@ namespace MeidoPhotoStudio.Plugin
 
     public class DragPointPropDTO
     {
-        public TransformDTO TransformDTO { get; init; }
-        public AttachPointInfo AttachPointInfo { get; init; }
-        public PropInfo PropInfo { get; init; }
-        public bool ShadowCasting { get; init; }
+        public TransformDTO TransformDTO { get; set; }
+        public AttachPointInfo AttachPointInfo { get; set; }
+        public PropInfo PropInfo { get; set; }
+        public bool ShadowCasting { get; set; }
 
         public DragPointPropDTO() { }
 

+ 5 - 5
src/MeidoPhotoStudio.Plugin/Serialization/SimpleSerializers/TransformDTOSerializer.cs

@@ -35,11 +35,11 @@ namespace MeidoPhotoStudio.Plugin
 
     public class TransformDTO
     {
-        public Vector3 Position { get; init; }
-        public Vector3 LocalPosition { get; init; }
-        public Quaternion Rotation { get; init; } = Quaternion.identity;
-        public Quaternion LocalRotation { get; init; } = Quaternion.identity;
-        public Vector3 LocalScale { get; init; } = Vector3.one;
+        public Vector3 Position { get; set; }
+        public Vector3 LocalPosition { get; set; }
+        public Quaternion Rotation { get; set; } = Quaternion.identity;
+        public Quaternion LocalRotation { get; set; } = Quaternion.identity;
+        public Vector3 LocalScale { get; set; } = Vector3.one;
 
         public TransformDTO() { }