-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDirectory.Build.props
More file actions
91 lines (84 loc) · 4.23 KB
/
Copy pathDirectory.Build.props
File metadata and controls
91 lines (84 loc) · 4.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<Project>
<PropertyGroup>
<dllDir Condition="'$(dllDir)' == ''">$(MSBuildThisFileDirectory)..\dll</dllDir>
<LangVersion>latest</LangVersion>
<TargetFramework>net46</TargetFramework>
<EnableDefaultCompileItems>false</EnableDefaultCompileItems>
<ImplicitUsings>disable</ImplicitUsings>
<Nullable>disable</Nullable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies.net46" Version="1.0.3">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
</ItemGroup>
<!--
Every localized Cosmo mod embeds the shared string-localization runtime.
This keeps its UI translations working even when Steam has not installed
the standalone Mod Localization System dependency. The standalone mod owns
only the global JSON interception patches needed by data-only content mods.
-->
<ItemGroup Condition="Exists('$(MSBuildProjectDirectory)\assets\Localization') Or Exists('$(MSBuildProjectDirectory)\assets\Localizations')">
<Compile
Include="$(MSBuildThisFileDirectory)mods\Mod Localization System\src\ModLocalization.cs"
Link="src\ModLocalization.cs"
Condition="'$(MSBuildProjectName)' != 'Mod Localization System'" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp" Private="false">
<HintPath>$(dllDir)\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp-firstpass" Private="false">
<HintPath>$(dllDir)\Assembly-CSharp-firstpass.dll</HintPath>
</Reference>
<Reference Include="0Harmony" Private="false">
<HintPath>$(dllDir)\0Harmony.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.CoreModule" Private="false">
<HintPath>$(dllDir)\UnityEngine.CoreModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UIModule" Private="false">
<HintPath>$(dllDir)\UnityEngine.UIModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI" Private="false">
<HintPath>$(dllDir)\UnityEngine.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.TextRenderingModule" Private="false">
<HintPath>$(dllDir)\UnityEngine.TextRenderingModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.JSONSerializeModule" Private="false">
<HintPath>$(dllDir)\UnityEngine.JSONSerializeModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.InputLegacyModule" Private="false">
<HintPath>$(dllDir)\UnityEngine.InputLegacyModule.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro" Private="false">
<HintPath>$(dllDir)\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.ImageConversionModule" Private="false">
<HintPath>$(dllDir)\UnityEngine.ImageConversionModule.dll</HintPath>
</Reference>
</ItemGroup>
<!-- ModOutputDir is supplied explicitly by the packaging/deployment script. -->
<Target Name="CleanModOutputDir" BeforeTargets="Clean" Condition="'$(ModName)' != '' and '$(ModOutputDir)' != '' and Exists('$(ModOutputDir)\$(ModName)')">
<RemoveDir Directories="$(ModOutputDir)\$(ModName)" />
</Target>
<Target Name="CopyModArtifacts" AfterTargets="Build" Condition="'$(ModName)' != '' and '$(ModOutputDir)' != ''">
<!--
Recreate the per-mod package on every packaging pass, not only on Clean.
This prevents deleted/renamed assets (especially localization strings) from
surviving an incremental Build as stale deployable files.
-->
<RemoveDir Directories="$(ModOutputDir)\$(ModName)" Condition="Exists('$(ModOutputDir)\$(ModName)')" />
<MakeDir Directories="$(ModOutputDir)\$(ModName)" />
<Copy SourceFiles="$(TargetPath)" DestinationFiles="$(ModOutputDir)\$(ModName)\$(AssemblyName).dll" />
<Copy
SourceFiles="$(TargetDir)$(AssemblyName).pdb"
DestinationFiles="$(ModOutputDir)\$(ModName)\$(AssemblyName).pdb"
Condition="Exists('$(TargetDir)$(AssemblyName).pdb')" />
<Exec
Command='xcopy /Y /E /I "$(MSBuildProjectDirectory)\assets" "$(ModOutputDir)\$(ModName)"'
Condition="Exists('$(MSBuildProjectDirectory)\assets')" />
</Target>
</Project>