mirror of
https://github.com/AssetRipper/Tpk.git
synced 2026-11-13 20:05:48 -10:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b899a92602 | ||
|
|
c07faa29d5 | ||
|
|
066c28f93e | ||
|
|
a9014885b5 | ||
|
|
1e52aabbba | ||
|
|
5fa4cb3aec | ||
|
|
742bfd10c7 | ||
|
|
85a195481f | ||
|
|
0848676272 | ||
|
|
ef5f006d86 | ||
|
|
63ae06b81c | ||
|
|
0346ab5638 | ||
|
|
7b0d976098 | ||
|
|
78795b0f3b | ||
|
|
631e16635c | ||
|
|
7c12284938 | ||
|
|
3a92e1500d | ||
|
|
da9deb5c43 | ||
|
|
03866b2bd6 | ||
|
|
d3d2280b17 | ||
|
|
43c367d0aa | ||
|
|
04979752a5 | ||
|
|
5954d55e23 | ||
|
|
2eaaef50da | ||
|
|
488e212e16 | ||
|
|
24da9dda10 | ||
|
|
46e3867d3c | ||
|
|
6bdc11a7cb | ||
|
|
e7c20cfdd1 | ||
|
|
7eef5f06d1 | ||
|
|
8c6d9c46be |
No files matched your search
@@ -1,63 +0,0 @@
|
||||
###############################################################################
|
||||
# Set default behavior to automatically normalize line endings.
|
||||
###############################################################################
|
||||
* text=auto
|
||||
|
||||
###############################################################################
|
||||
# Set default behavior for command prompt diff.
|
||||
#
|
||||
# This is need for earlier builds of msysgit that does not have it on by
|
||||
# default for csharp files.
|
||||
# Note: This is only used by command line
|
||||
###############################################################################
|
||||
#*.cs diff=csharp
|
||||
|
||||
###############################################################################
|
||||
# Set the merge driver for project and solution files
|
||||
#
|
||||
# Merging from the command prompt will add diff markers to the files if there
|
||||
# are conflicts (Merging from VS is not affected by the settings below, in VS
|
||||
# the diff markers are never inserted). Diff markers may cause the following
|
||||
# file extensions to fail to load in VS. An alternative would be to treat
|
||||
# these files as binary and thus will always conflict and require user
|
||||
# intervention with every merge. To do so, just uncomment the entries below
|
||||
###############################################################################
|
||||
#*.sln merge=binary
|
||||
#*.csproj merge=binary
|
||||
#*.vbproj merge=binary
|
||||
#*.vcxproj merge=binary
|
||||
#*.vcproj merge=binary
|
||||
#*.dbproj merge=binary
|
||||
#*.fsproj merge=binary
|
||||
#*.lsproj merge=binary
|
||||
#*.wixproj merge=binary
|
||||
#*.modelproj merge=binary
|
||||
#*.sqlproj merge=binary
|
||||
#*.wwaproj merge=binary
|
||||
|
||||
###############################################################################
|
||||
# behavior for image files
|
||||
#
|
||||
# image files are treated as binary by default.
|
||||
###############################################################################
|
||||
#*.jpg binary
|
||||
#*.png binary
|
||||
#*.gif binary
|
||||
|
||||
###############################################################################
|
||||
# diff behavior for common document formats
|
||||
#
|
||||
# Convert binary document formats to text before diffing them. This feature
|
||||
# is only available from the command line. Turn it on by uncommenting the
|
||||
# entries below.
|
||||
###############################################################################
|
||||
#*.doc diff=astextplain
|
||||
#*.DOC diff=astextplain
|
||||
#*.docx diff=astextplain
|
||||
#*.DOCX diff=astextplain
|
||||
#*.dot diff=astextplain
|
||||
#*.DOT diff=astextplain
|
||||
#*.pdf diff=astextplain
|
||||
#*.PDF diff=astextplain
|
||||
#*.rtf diff=astextplain
|
||||
#*.RTF diff=astextplain
|
||||
@@ -27,45 +27,45 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Tpk Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v6
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v4
|
||||
uses: actions/setup-dotnet@v5
|
||||
with:
|
||||
dotnet-version: 6.0.x
|
||||
dotnet-version: 10.0.x
|
||||
- name: Build
|
||||
run: dotnet build /p:Configuration=Release
|
||||
working-directory: ./Tpk.ConsoleApp/
|
||||
- name: Checkout DocumentationDumps Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
repository: 'AssetRipper/DocumentationDumps'
|
||||
path: DocumentationDumps
|
||||
- name: Make files executable
|
||||
shell: bash
|
||||
run: chmod +x ./Tpk.ConsoleApp/bin/Release/net6.0/AssetRipper.Tpk.ConsoleApp
|
||||
run: chmod +x ./Tpk.ConsoleApp/bin/Release/net10.0/AssetRipper.Tpk.ConsoleApp
|
||||
- name: Make tpk file
|
||||
shell: bash
|
||||
run: ./Tpk.ConsoleApp/bin/Release/net6.0/AssetRipper.Tpk.ConsoleApp --engine-assets ./DocumentationDumps/EngineAssets
|
||||
run: ./Tpk.ConsoleApp/bin/Release/net10.0/AssetRipper.Tpk.ConsoleApp --engine-assets ./DocumentationDumps/EngineAssets
|
||||
- name: Upload Uncompressed file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: uncompressed_file
|
||||
path: ./uncompressed.tpk
|
||||
if-no-files-found: error
|
||||
- name: Upload Lz4 file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: lz4_file
|
||||
path: ./lz4.tpk
|
||||
if-no-files-found: error
|
||||
- name: Upload Lzma file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: lzma_file
|
||||
path: ./lzma.tpk
|
||||
if-no-files-found: error
|
||||
- name: Upload Brotli file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: brotli_file
|
||||
path: ./brotli.tpk
|
||||
|
||||
@@ -12,11 +12,11 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v6
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v4
|
||||
uses: actions/setup-dotnet@v5
|
||||
with:
|
||||
dotnet-version: 6.0.x
|
||||
dotnet-version: 10.0.x
|
||||
- name: Restore dependencies
|
||||
run: dotnet restore
|
||||
- name: Build
|
||||
|
||||
@@ -27,47 +27,48 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Tpk Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v6
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v4
|
||||
uses: actions/setup-dotnet@v5
|
||||
with:
|
||||
dotnet-version: 6.0.x
|
||||
dotnet-version: 10.0.x
|
||||
- name: Build
|
||||
run: dotnet build /p:Configuration=Release
|
||||
working-directory: ./Tpk.ConsoleApp/
|
||||
- name: Checkout TypeTreeDumps Repository
|
||||
uses: actions/checkout@v4
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
repository: 'AssetRipper/TypeTreeDumps'
|
||||
sparse-checkout: 'InfoJson'
|
||||
path: TypeTreeDumps
|
||||
- name: Make files executable
|
||||
shell: bash
|
||||
run: chmod +x ./Tpk.ConsoleApp/bin/Release/net6.0/AssetRipper.Tpk.ConsoleApp
|
||||
run: chmod +x ./Tpk.ConsoleApp/bin/Release/net10.0/AssetRipper.Tpk.ConsoleApp
|
||||
- name: Make tpk file
|
||||
shell: bash
|
||||
run: ./Tpk.ConsoleApp/bin/Release/net6.0/AssetRipper.Tpk.ConsoleApp --type-tree ./TypeTreeDumps/InfoJson
|
||||
run: ./Tpk.ConsoleApp/bin/Release/net10.0/AssetRipper.Tpk.ConsoleApp --type-tree ./TypeTreeDumps/InfoJson
|
||||
- name: Upload Uncompressed file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: uncompressed_file
|
||||
path: ./uncompressed.tpk
|
||||
if-no-files-found: error
|
||||
- name: Upload Lz4 file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: lz4_file
|
||||
path: ./lz4.tpk
|
||||
if-no-files-found: error
|
||||
- name: Upload Lzma file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: lzma_file
|
||||
path: ./lzma.tpk
|
||||
if-no-files-found: error
|
||||
- name: Upload Brotli file
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
name: brotli_file
|
||||
path: ./brotli.tpk
|
||||
if-no-files-found: error
|
||||
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
<Project>
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net10.0</TargetFramework>
|
||||
<LangVersion>latest</LangVersion>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<IsAotCompatible>true</IsAotCompatible>
|
||||
<CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
|
||||
|
||||
<Authors>ds5678</Authors>
|
||||
<Company>AssetRipper</Company>
|
||||
<VersionPrefix>1.2.0</VersionPrefix>
|
||||
<RepositoryUrl>https://github.com/AssetRipper/Tpk</RepositoryUrl>
|
||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||
<RepositoryType>git</RepositoryType>
|
||||
<PackageProjectUrl>$(RepositoryUrl)</PackageProjectUrl>
|
||||
<Copyright>Copyright (c) ds5678</Copyright>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -4,6 +4,8 @@ A tool for compressing [type tree dumps](https://github.com/AssetRipper/TypeTree
|
||||
|
||||
## Type Tree Tpk
|
||||
|
||||
> Warning: [AssetsTools.NET](https://github.com/nesrak1/AssetsTools.NET) does not support Brotli compression.
|
||||
|
||||
| Compression | Link |
|
||||
| ----------- | ---- |
|
||||
| [Brotli](https://nightly.link/AssetRipper/Tpk/workflows/type_tree_tpk/master/brotli_file) | https://nightly.link/AssetRipper/Tpk/workflows/type_tree_tpk/master/brotli_file.zip |
|
||||
@@ -13,6 +15,8 @@ A tool for compressing [type tree dumps](https://github.com/AssetRipper/TypeTree
|
||||
|
||||
## Engine Assets Tpk
|
||||
|
||||
> This is an internal file for AssetRipper and might not have much other use.
|
||||
|
||||
| Compression | Link |
|
||||
| ----------- | ---- |
|
||||
| [Brotli](https://nightly.link/AssetRipper/Tpk/workflows/engine_assets_tpk/master/brotli_file) | https://nightly.link/AssetRipper/Tpk/workflows/engine_assets_tpk/master/brotli_file.zip |
|
||||
|
||||
@@ -2,20 +2,17 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<RootNamespace>AssetRipper.Tpk.ConsoleApp</RootNamespace>
|
||||
<AssemblyName>AssetRipper.Tpk.ConsoleApp</AssemblyName>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="SharpZipLib" Version="1.4.2" />
|
||||
<PackageReference Include="SharpCompress" Version="0.47.3" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Tpk.TypeTrees.Json\Tpk.TypeTrees.Json.csproj" />
|
||||
<ProjectReference Include="..\Tpk\Tpk.csproj" />
|
||||
<ProjectReference Include="..\Tpk.TypeTrees.Json\Tpk.TypeTrees.Json.csproj" />
|
||||
<ProjectReference Include="..\Tpk\Tpk.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
@@ -1,7 +1,9 @@
|
||||
using System.Collections.Generic;
|
||||
using AssetRipper.Primitives;
|
||||
using AssetRipper.Tpk.TypeTrees.Json;
|
||||
using AssetRipper.Primitives;
|
||||
using ICSharpCode.SharpZipLib.Zip;
|
||||
using SharpCompress.Archives;
|
||||
using SharpCompress.Archives.Zip;
|
||||
using SharpCompress.Writers.Zip;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace AssetRipper.Tpk.ConsoleApp
|
||||
{
|
||||
@@ -17,17 +19,16 @@ namespace AssetRipper.Tpk.ConsoleApp
|
||||
List<UnityInfo> list = new();
|
||||
|
||||
using FileStream fileStream = File.OpenRead(zipFilePath);
|
||||
using ZipInputStream zipInputStream = new ZipInputStream(fileStream);
|
||||
ZipEntry entry;
|
||||
while ((entry = zipInputStream.GetNextEntry()) is not null)
|
||||
using IWritableArchive<ZipWriterOptions> archive = ZipArchive.OpenArchive(fileStream);
|
||||
foreach (var entry in archive.Entries)
|
||||
{
|
||||
if(entry.IsFile && entry.Name.EndsWith(".json", StringComparison.Ordinal))
|
||||
if (!entry.IsDirectory && (entry.Key ?? "").EndsWith(".json", StringComparison.Ordinal))
|
||||
{
|
||||
using MemoryStream unzippedFileStream = new MemoryStream();
|
||||
zipInputStream.CopyTo(unzippedFileStream);
|
||||
entry.WriteTo(unzippedFileStream);
|
||||
unzippedFileStream.Position = 0;
|
||||
UnityInfo? info = UnityInfo.FromStream(unzippedFileStream);
|
||||
if(info is not null)
|
||||
if (info is not null)
|
||||
{
|
||||
list.Add(info);
|
||||
}
|
||||
|
||||
@@ -1,23 +1,20 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<RootNamespace>AssetRipper.Tpk.Tests</RootNamespace>
|
||||
<AssemblyName>AssetRipper.Tpk.Tests</AssemblyName>
|
||||
<IsPackable>false</IsPackable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
|
||||
<PackageReference Include="NUnit" Version="4.2.2" />
|
||||
<PackageReference Include="NUnit.Analyzers" Version="4.6.0">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.3.0" />
|
||||
<PackageReference Include="NUnit" Version="4.5.1" />
|
||||
<PackageReference Include="NUnit.Analyzers" Version="4.12.0">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0" />
|
||||
<PackageReference Include="coverlet.collector" Version="6.0.2">
|
||||
<PackageReference Include="NUnit3TestAdapter" Version="6.2.0" />
|
||||
<PackageReference Include="coverlet.collector" Version="8.0.1">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
|
||||
@@ -1,23 +1,20 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<RootNamespace>AssetRipper.Tpk.TypeTrees.Json.Tests</RootNamespace>
|
||||
<AssemblyName>AssetRipper.Tpk.TypeTrees.Json.Tests</AssemblyName>
|
||||
<IsPackable>false</IsPackable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
|
||||
<PackageReference Include="NUnit" Version="4.2.2" />
|
||||
<PackageReference Include="NUnit.Analyzers" Version="4.6.0">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.3.0" />
|
||||
<PackageReference Include="NUnit" Version="4.5.1" />
|
||||
<PackageReference Include="NUnit.Analyzers" Version="4.12.0">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0" />
|
||||
<PackageReference Include="coverlet.collector" Version="6.0.2">
|
||||
<PackageReference Include="NUnit3TestAdapter" Version="6.2.0" />
|
||||
<PackageReference Include="coverlet.collector" Version="8.0.1">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
|
||||
@@ -1,36 +1,22 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<LangVersion>latest</LangVersion>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<IsTrimmable>true</IsTrimmable>
|
||||
<RootNamespace>AssetRipper.Tpk.TypeTrees.Json</RootNamespace>
|
||||
<AssemblyName>AssetRipper.Tpk.TypeTrees.Json</AssemblyName>
|
||||
|
||||
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
|
||||
<Authors>ds5678</Authors>
|
||||
<Company>AssetRipper</Company>
|
||||
<Version>1.1.0</Version>
|
||||
<AssemblyVersion>$(Version)</AssemblyVersion>
|
||||
|
||||
<PackageId>AssetRipper.Tpk.TypeTrees.Json</PackageId>
|
||||
<PackageTags>C#</PackageTags>
|
||||
<RepositoryUrl>https://github.com/AssetRipper/Tpk</RepositoryUrl>
|
||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||
<RepositoryType>git</RepositoryType>
|
||||
<PackageProjectUrl>$(RepositoryUrl)</PackageProjectUrl>
|
||||
<Copyright>Copyright (c) 2025 ds5678</Copyright>
|
||||
<Description>Library for type tree serialization.</Description>
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<NoWarn>1591</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AssetRipper.HashAlgorithms" Version="1.0.0" />
|
||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0">
|
||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="10.0.201">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
|
||||
@@ -43,7 +43,7 @@ namespace AssetRipper.Tpk.TypeTrees.Json
|
||||
/// <summary>
|
||||
/// The count of all classes that descend from this class<br/>
|
||||
/// It includes this class, so the count is always positive<br/>
|
||||
/// However, some older unity versions don't generate this, so sometimes we have to set it in SharedState initialization
|
||||
/// However, some older unity versions don't generate this, so sometimes it needs to be set manually.
|
||||
/// </summary>
|
||||
public uint DescendantCount { get; set; }
|
||||
/// <summary>
|
||||
|
||||
@@ -9,9 +9,6 @@ namespace AssetRipper.Tpk.TypeTrees.Json
|
||||
{
|
||||
public sealed class UnityNode
|
||||
{
|
||||
/// <summary>
|
||||
/// The unique type name used in the <see cref = "SharedState"/> dictionaries
|
||||
/// </summary>
|
||||
public string TypeName { get => typeName; set => typeName = value ?? ""; }
|
||||
/// <summary>
|
||||
/// The original type name as obtained from the json file
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.0.32112.339
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{B80E65C0-145A-4034-9EC8-E2D03ECAE732}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
.gitignore = .gitignore
|
||||
License.md = License.md
|
||||
README.md = README.md
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{33E54A6F-8689-4D4A-AA4F-CB68BDEE8FF4}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.github\workflows\engine_assets_tpk.yml = .github\workflows\engine_assets_tpk.yml
|
||||
.github\workflows\test.yml = .github\workflows\test.yml
|
||||
.github\workflows\type_tree_tpk.yml = .github\workflows\type_tree_tpk.yml
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Tpk", "Tpk\Tpk.csproj", "{E209C981-9B4C-4F85-94D1-BE3BE279FFE9}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Tpk.ConsoleApp", "Tpk.ConsoleApp\Tpk.ConsoleApp.csproj", "{C72B5264-B6E5-4182-A0D1-D0D95D310C26}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Tpk.Tests", "Tpk.Tests\Tpk.Tests.csproj", "{35439820-AA58-4808-9CB0-C749A72E6E84}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Tpk.TypeTrees.Json", "Tpk.TypeTrees.Json\Tpk.TypeTrees.Json.csproj", "{7EE04F87-29D5-40C1-A844-E69E22A0EC2F}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Tpk.TypeTrees.Json.Tests", "Tpk.TypeTrees.Json.Tests\Tpk.TypeTrees.Json.Tests.csproj", "{4D312207-79EB-4289-A855-9517AD25AD88}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{E209C981-9B4C-4F85-94D1-BE3BE279FFE9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{E209C981-9B4C-4F85-94D1-BE3BE279FFE9}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{E209C981-9B4C-4F85-94D1-BE3BE279FFE9}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{E209C981-9B4C-4F85-94D1-BE3BE279FFE9}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{C72B5264-B6E5-4182-A0D1-D0D95D310C26}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{C72B5264-B6E5-4182-A0D1-D0D95D310C26}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{C72B5264-B6E5-4182-A0D1-D0D95D310C26}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{C72B5264-B6E5-4182-A0D1-D0D95D310C26}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{35439820-AA58-4808-9CB0-C749A72E6E84}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{35439820-AA58-4808-9CB0-C749A72E6E84}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{35439820-AA58-4808-9CB0-C749A72E6E84}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{35439820-AA58-4808-9CB0-C749A72E6E84}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{7EE04F87-29D5-40C1-A844-E69E22A0EC2F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{7EE04F87-29D5-40C1-A844-E69E22A0EC2F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{7EE04F87-29D5-40C1-A844-E69E22A0EC2F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{7EE04F87-29D5-40C1-A844-E69E22A0EC2F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{4D312207-79EB-4289-A855-9517AD25AD88}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{4D312207-79EB-4289-A855-9517AD25AD88}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{4D312207-79EB-4289-A855-9517AD25AD88}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{4D312207-79EB-4289-A855-9517AD25AD88}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(NestedProjects) = preSolution
|
||||
{33E54A6F-8689-4D4A-AA4F-CB68BDEE8FF4} = {B80E65C0-145A-4034-9EC8-E2D03ECAE732}
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {B4F6071A-E37E-4782-9BDD-92C8A73D4820}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
@@ -0,0 +1,19 @@
|
||||
<Solution>
|
||||
<Folder Name="/Solution Items/">
|
||||
<File Path=".editorconfig" />
|
||||
<File Path=".gitignore" />
|
||||
<File Path="Directory.Build.props" />
|
||||
<File Path="License.md" />
|
||||
<File Path="README.md" />
|
||||
</Folder>
|
||||
<Folder Name="/Solution Items/workflows/">
|
||||
<File Path=".github/workflows/engine_assets_tpk.yml" />
|
||||
<File Path=".github/workflows/test.yml" />
|
||||
<File Path=".github/workflows/type_tree_tpk.yml" />
|
||||
</Folder>
|
||||
<Project Path="Tpk.ConsoleApp/Tpk.ConsoleApp.csproj" />
|
||||
<Project Path="Tpk.Tests/Tpk.Tests.csproj" />
|
||||
<Project Path="Tpk.TypeTrees.Json.Tests/Tpk.TypeTrees.Json.Tests.csproj" />
|
||||
<Project Path="Tpk.TypeTrees.Json/Tpk.TypeTrees.Json.csproj" />
|
||||
<Project Path="Tpk/Tpk.csproj" />
|
||||
</Solution>
|
||||
@@ -9,7 +9,7 @@ namespace AssetRipper.Tpk.Compression
|
||||
LzmaEncoderProperties properties = new LzmaEncoderProperties(false, 1 << 25, 256);
|
||||
using MemoryStream inputStream = new MemoryStream(uncompressedBytes);
|
||||
using MemoryStream outputStream = new MemoryStream();
|
||||
using LzmaStream lzmaStream = new LzmaStream(properties, false, outputStream);
|
||||
using LzmaStream lzmaStream = LzmaStream.Create(properties, false, outputStream);
|
||||
outputStream.Write(lzmaStream.Properties);
|
||||
inputStream.CopyTo(lzmaStream);
|
||||
lzmaStream.Close();
|
||||
@@ -25,7 +25,7 @@ namespace AssetRipper.Tpk.Compression
|
||||
using MemoryStream inputStream = new MemoryStream(compressedBytes);
|
||||
inputStream.Position = 5;
|
||||
using MemoryStream outputStream = new MemoryStream();
|
||||
using LzmaStream lzmaStream = new LzmaStream(properties, inputStream, compressedBytes.Length - 5, decompressedSize);
|
||||
using LzmaStream lzmaStream = LzmaStream.Create(properties, inputStream, compressedBytes.Length - 5, decompressedSize);
|
||||
lzmaStream.CopyTo(outputStream);
|
||||
return outputStream.ToArray();
|
||||
}
|
||||
@@ -38,7 +38,7 @@ namespace AssetRipper.Tpk.Compression
|
||||
byte[] properties = new Span<byte>(compressedBytes, 0, 5).ToArray();
|
||||
MemoryStream inputStream = new MemoryStream(compressedBytes);
|
||||
inputStream.Position = 5;
|
||||
return new LzmaStream(properties, inputStream, compressedBytes.Length - 5, decompressedSize);
|
||||
return LzmaStream.Create(properties, inputStream, compressedBytes.Length - 5, decompressedSize);
|
||||
}
|
||||
}
|
||||
}
|
||||
+5
-19
@@ -1,41 +1,27 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<LangVersion>latest</LangVersion>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<IsTrimmable>true</IsTrimmable>
|
||||
<RootNamespace>AssetRipper.Tpk</RootNamespace>
|
||||
<AssemblyName>AssetRipper.Tpk</AssemblyName>
|
||||
|
||||
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
|
||||
<Authors>ds5678</Authors>
|
||||
<Company>AssetRipper</Company>
|
||||
<Version>1.1.0</Version>
|
||||
<AssemblyVersion>$(Version)</AssemblyVersion>
|
||||
|
||||
<PackageId>AssetRipper.Tpk</PackageId>
|
||||
<PackageTags>C#</PackageTags>
|
||||
<RepositoryUrl>https://github.com/AssetRipper/Tpk</RepositoryUrl>
|
||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||
<RepositoryType>git</RepositoryType>
|
||||
<PackageProjectUrl>$(RepositoryUrl)</PackageProjectUrl>
|
||||
<Copyright>Copyright (c) 2025 ds5678</Copyright>
|
||||
<Description>Library for storing asset information.</Description>
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<NoWarn>1591</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AssetRipper.Primitives" Version="3.1.3" />
|
||||
<PackageReference Include="AssetRipper.Primitives" Version="3.2.0" />
|
||||
<PackageReference Include="K4os.Compression.LZ4" Version="1.3.8" />
|
||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0">
|
||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="10.0.201">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="SharpCompress" Version="0.38.0" />
|
||||
<PackageReference Include="SharpCompress" Version="0.47.3" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
Reference in new issue
Block a user