-
Notifications
You must be signed in to change notification settings - Fork 151
Expand file tree
/
Copy pathDirectory.Build.targets
More file actions
35 lines (31 loc) · 1.89 KB
/
Copy pathDirectory.Build.targets
File metadata and controls
35 lines (31 loc) · 1.89 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
<?xml version="1.0" encoding="utf-8"?>
<!--
Imported after every .csproj body, which is what makes it the place for items the projects and
their packages have already declared, and for anything keyed off a property a project sets.
Directory.Build.props is too early for both.
-->
<Project>
<ItemGroup>
<!-- JotunnLib's reference list (EpicLoot pulls the package) still carries assemblies that
Valheim's Unity version dropped. Nothing here uses them, and leaving them in warns
MSB3245 on every build. -->
<Reference Remove="UnityEngine.ProfilerModule" Condition="!Exists('$(GamePathManaged)UnityEngine.ProfilerModule.dll')" />
</ItemGroup>
<!-- ==================== publicized game assemblies ====================
Paths.props references the vanilla assemblies as the game ships them. Every mod here
except EquipmentAndQuickSlotsAPI patches or reads non-public Valheim members, so those
references have to be publicized first. Rather than depend on a publicized_assemblies
folder someone generated by hand at some point, BepInEx.AssemblyPublicizer.MSBuild
rewrites them into obj/ at build time - no writes to the game install, and a game update
is picked up on the next build.
Opt out per project with <PublicizeGameAssemblies>false</PublicizeGameAssemblies>; the
default is on because 11 of the 12 projects need it. The package requires an SDK-style
project, which is now true of all of them. -->
<ItemGroup Condition="'$(PublicizeGameAssemblies)' != 'false'">
<PackageReference Include="BepInEx.AssemblyPublicizer.MSBuild" Version="0.4.3" PrivateAssets="all" />
<Reference Update="assembly_valheim" Publicize="true" />
<Reference Update="assembly_utils" Publicize="true" />
<Reference Update="assembly_guiutils" Publicize="true" />
<Reference Update="Splatform" Publicize="true" />
</ItemGroup>
</Project>