Skip to content

Commit

Permalink
Added remote model loading support
Browse files Browse the repository at this point in the history
  • Loading branch information
luvoid committed Sep 16, 2023
1 parent c1bbc55 commit 2c6814e
Show file tree
Hide file tree
Showing 17 changed files with 837 additions and 270 deletions.
19 changes: 15 additions & 4 deletions COM3D2.LiveLink.sln
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LiveLink.Tests", "LiveLink.
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LiveLink.CLI", "LiveLink.CLI\LiveLink.CLI.csproj", "{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CM3D2.Serialization", "..\CM3D2.Serialization\CM3D2.Serialization\CM3D2.Serialization.csproj", "{59786FC6-0C86-495E-AB89-7CFABCC966E6}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CM3D2.Serialization", "..\CM3D2.Serialization\CM3D2.Serialization\CM3D2.Serialization.csproj", "{59786FC6-0C86-495E-AB89-7CFABCC966E6}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CM3D2.Serialization.Tests", "..\CM3D2.Serialization\CM3D2.Serialization.Tests\CM3D2.Serialization.Tests.csproj", "{3A4C2284-D50C-4F0F-A6E3-9303B423595D}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CM3D2.Serialization.Tests", "..\CM3D2.Serialization\CM3D2.Serialization.Tests\CM3D2.Serialization.Tests.csproj", "{3A4C2284-D50C-4F0F-A6E3-9303B423595D}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{B0235D70-D8D6-4AF7-8D1F-25DD22CC681C}"
ProjectSection(SolutionItems) = preProject
Expand All @@ -25,34 +25,45 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug_UnityEditor|Any CPU = Debug_UnityEditor|Any CPU
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{7AB5BFFA-621F-48E4-AAED-943B97A1B7EC}.Debug_UnityEditor|Any CPU.ActiveCfg = Debug_UnityEditor|Any CPU
{7AB5BFFA-621F-48E4-AAED-943B97A1B7EC}.Debug_UnityEditor|Any CPU.Build.0 = Debug_UnityEditor|Any CPU
{7AB5BFFA-621F-48E4-AAED-943B97A1B7EC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7AB5BFFA-621F-48E4-AAED-943B97A1B7EC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7AB5BFFA-621F-48E4-AAED-943B97A1B7EC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7AB5BFFA-621F-48E4-AAED-943B97A1B7EC}.Release|Any CPU.Build.0 = Release|Any CPU
{4AE5C9FA-7423-4494-A656-EA80884F4EBC}.Debug_UnityEditor|Any CPU.ActiveCfg = Debug_UnityEditor|Any CPU
{4AE5C9FA-7423-4494-A656-EA80884F4EBC}.Debug_UnityEditor|Any CPU.Build.0 = Debug_UnityEditor|Any CPU
{4AE5C9FA-7423-4494-A656-EA80884F4EBC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{4AE5C9FA-7423-4494-A656-EA80884F4EBC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4AE5C9FA-7423-4494-A656-EA80884F4EBC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4AE5C9FA-7423-4494-A656-EA80884F4EBC}.Release|Any CPU.Build.0 = Release|Any CPU
{36D8B7A9-EE1A-4219-B768-D3EE0599054D}.Debug_UnityEditor|Any CPU.ActiveCfg = Debug_UnityEditor|Any CPU
{36D8B7A9-EE1A-4219-B768-D3EE0599054D}.Debug_UnityEditor|Any CPU.Build.0 = Debug_UnityEditor|Any CPU
{36D8B7A9-EE1A-4219-B768-D3EE0599054D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{36D8B7A9-EE1A-4219-B768-D3EE0599054D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{36D8B7A9-EE1A-4219-B768-D3EE0599054D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{36D8B7A9-EE1A-4219-B768-D3EE0599054D}.Release|Any CPU.Build.0 = Release|Any CPU
{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}.Debug_UnityEditor|Any CPU.ActiveCfg = Debug_UnityEditor|Any CPU
{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}.Debug_UnityEditor|Any CPU.Build.0 = Debug_UnityEditor|Any CPU
{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3FD79CB2-1469-44A5-A156-C27A2A8C8E1A}.Release|Any CPU.Build.0 = Release|Any CPU
{59786FC6-0C86-495E-AB89-7CFABCC966E6}.Debug_UnityEditor|Any CPU.ActiveCfg = Debug_UnityEditor|Any CPU
{59786FC6-0C86-495E-AB89-7CFABCC966E6}.Debug_UnityEditor|Any CPU.Build.0 = Debug_UnityEditor|Any CPU
{59786FC6-0C86-495E-AB89-7CFABCC966E6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{59786FC6-0C86-495E-AB89-7CFABCC966E6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{59786FC6-0C86-495E-AB89-7CFABCC966E6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{59786FC6-0C86-495E-AB89-7CFABCC966E6}.Release|Any CPU.Build.0 = Release|Any CPU
{3A4C2284-D50C-4F0F-A6E3-9303B423595D}.Debug_UnityEditor|Any CPU.ActiveCfg = Debug_UnityEditor|Any CPU
{3A4C2284-D50C-4F0F-A6E3-9303B423595D}.Debug_UnityEditor|Any CPU.Build.0 = Debug_UnityEditor|Any CPU
{3A4C2284-D50C-4F0F-A6E3-9303B423595D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3A4C2284-D50C-4F0F-A6E3-9303B423595D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3A4C2284-D50C-4F0F-A6E3-9303B423595D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3A4C2284-D50C-4F0F-A6E3-9303B423595D}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
9 changes: 9 additions & 0 deletions LiveLink.CLI/LiveLink.CLI.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,15 @@
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_UnityEditor|AnyCPU'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\Debug_UnityEditor\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<LangVersion>7.3</LangVersion>
<ErrorReport>prompt</ErrorReport>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
Expand Down
2 changes: 1 addition & 1 deletion LiveLink.Plugin/InternalSingleton.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace COM3D2.LiveLink.Plugin
internal abstract class InternalSingleton<T> : MonoSingleton<T>
where T : InternalSingleton<T>
{
protected static T Instance;
internal protected static T Instance;
public sealed override void OnInitialize()
{
Instance = this as T;
Expand Down
84 changes: 35 additions & 49 deletions LiveLink.Plugin/LiveLink.Plugin.csproj
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x64</Platform>
Expand All @@ -13,29 +12,34 @@
<RootNamespace>COM3D2.LiveLink.Plugin</RootNamespace>
<AssemblyName>COM3D2.LiveLink.Plugin</AssemblyName>
<LangVersion>latest</LangVersion>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFramework>net35</TargetFramework>
<COM3D2InstallPath>C:\DJN\KISS\COM3D2</COM3D2InstallPath>
<OutputPath>bin\$(Configuration)\$(Platform)</OutputPath>
<StartProgram>$(COM3D2InstallPath)\COM3D2x64.exe</StartProgram>
<Configurations>Debug;Release;Debug_UnityEditor</Configurations>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<OutputPath>bin\Debug\AnyCPU\</OutputPath>
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)'=='Debug_UnityEditor'">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<DefineConstants>DEBUG;TRACE</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Debug_UnityEditor' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<DefineConstants>DEBUG;TRACE;UNITY_EDITOR</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
<DebugType>none</DebugType>
<Optimize>true</Optimize>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup>
<RestoreSources>$(RestoreSources);https://nuget.bepinex.dev/v3/index.json</RestoreSources>
Expand All @@ -44,33 +48,17 @@
<PackageReference Include="BepInEx.Analyzers" Version="1.0.8" targetFramework="net35" developmentDependency="true">
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="BepInEx.BaseLib" Version="5.4.19" targetFramework="net35" />
<PackageReference Include="BepInEx.BaseLib" Version="5.4.21" targetFramework="net35" />
<PackageReference Include="BepInEx.Core" Version="5.4.19" targetFramework="net35" />
<PackageReference Include="COM3D2.GameLibs" Version="2.24.0-r.0" />
<PackageReference Include="HarmonyX" Version="2.7.0" targetFramework="net35" />
<PackageReference Include="LuVoid.CM3D2.UGUI" Version="0.1.4-alpha.1" />
<PackageReference Include="Mono.Cecil" Version="0.10.4" targetFramework="net35" />
<PackageReference Include="MonoMod.RuntimeDetour" Version="21.12.13.1" targetFramework="net35" />
<PackageReference Include="MonoMod.Utils" Version="21.12.13.1" targetFramework="net35" />
</ItemGroup>
<ItemGroup>
<Reference Include="COM3D2.API, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL" />
<Reference Include="System">
<Private>False</Private>
</Reference>
<Reference Include="System.Core">
<Private>False</Private>
</Reference>
<Reference Include="System.Xml.Linq">
<Private>False</Private>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<Private>False</Private>
</Reference>
<Reference Include="System.Data">
<Private>False</Private>
</Reference>
<Reference Include="System.Xml">
<Private>False</Private>
</Reference>
<Reference Include="Assembly-CSharp">
<HintPath>$(COM3D2InstallPath)\COM3D2x64_Data\Managed\Assembly-CSharp.dll</HintPath>
<Private>False</Private>
Expand All @@ -95,22 +83,6 @@
<ReferencePath>$(ReferencePath);$(COM3D2InstallPath)\Sybaris</ReferencePath>
<ReferencePath>$(ReferencePath);$(COM3D2InstallPath)\Sybaris\UnityInjector</ReferencePath>
</PropertyGroup>
<ItemGroup>
<Compile Include="CodeMatcherExtensions.cs" />
<Compile Include="ImportCMExtensions.cs" />
<Compile Include="LiveLinkModelViewer.cs" />
<Compile Include="SystemDialogExtensions.cs" />
<Compile Include="Tests\PluginTests.cs" />
<Compile Include="LiveLinkAnimator.cs" />
<Compile Include="LiveLinkPluginConfig.cs" />
<Compile Include="InternalSingleton.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="LiveLinkPlugin.cs" />
<Compile Include="Tests\PluginTestHelper.cs" />
<Compile Include="Tests\PluginTestLogListener.cs" />
<Compile Include="Tests\SafeExitHelper.cs" />
<Compile Include="Tests\TestRecieveMessageHelper.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\CM3D2.Serialization\CM3D2.Serialization\CM3D2.Serialization.csproj">
<Project>{59786FC6-0C86-495E-AB89-7CFABCC966E6}</Project>
Expand All @@ -125,14 +97,28 @@
<Name>LiveLink</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>
<PostBuildEvent Condition=" '$(Configuration)' != 'Debug_UnityEditor' ">
for /f "usebackq delims=|" %25%25f in (`dir /b *.dll`) do "$(ProjectDir)\pdb2mdb.exe" "%25%25f" 1&gt;nul
rd "$(COM3D2InstallPath)\BepinEx\plugins\vsout_$(ProjectName)"
mklink /J "$(COM3D2InstallPath)\BepinEx\plugins\vsout_$(ProjectName)" .
</PostBuildEvent>
</PostBuildEvent>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
<Deterministic>False</Deterministic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_UnityEditor|AnyCPU'">
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
<Deterministic>False</Deterministic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
<Deterministic>False</Deterministic>
</PropertyGroup>
<Target Name="CreateMonoDebugSymbols" AfterTargets="build" Condition="'$(Configuration)' == 'Debug_UnityEditor'">
<Exec Command="for /f &quot;usebackq delims=|&quot; %25%25f in (`dir /b *.dll`) do &quot;$(ProjectDir)lib\pdb2mdb.exe&quot; %25%25f" WorkingDirectory="$(OutputPath)" />
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
Expand Down
30 changes: 0 additions & 30 deletions LiveLink.Plugin/LiveLinkAnimator.cs

This file was deleted.

Loading

0 comments on commit 2c6814e

Please sign in to comment.