From 7c0a6375b117da01a4f1a4305b82aa4c3964f44f Mon Sep 17 00:00:00 2001 From: VaDiM Date: Sun, 24 Sep 2023 15:41:21 +0300 Subject: [PATCH] Update readme files --- AssetStudioCLI/ReadMe.md | 86 +++++++++++++++++++----- README.md | 139 +++++++++++++++------------------------ 2 files changed, 120 insertions(+), 105 deletions(-) diff --git a/AssetStudioCLI/ReadMe.md b/AssetStudioCLI/ReadMe.md index 1f27b91..4924620 100644 --- a/AssetStudioCLI/ReadMe.md +++ b/AssetStudioCLI/ReadMe.md @@ -1,34 +1,39 @@ -## AssetStudioModCLI -CLI version of AssetStudioMod. -- Supported asset types: `Texture2D`, `Sprite`, `TextAsset`, `MonoBehaviour`, `Font`, `Shader`, `MovieTexture`, `AudioClip`, `VideoClip`, `Mesh`. +## ArknightsStudioCLI +CLI version of ArknightsStudio. +- Supported asset types for export: `Texture2D`, `Sprite`, `AkPortraitSprite`, `TextAsset`, `MonoBehaviour`, `Font`, `Shader`, `MovieTexture`, `AudioClip`, `VideoClip`, `Mesh`. - *There are no plans to add support for `AnimationClip`, `Animator` for now.* ### Usage ``` -AssetStudioModCLI [-m, --mode ] +ArknightsStudioCLI [-m, --mode ] [-t, --asset-type ] [-g, --group-option ] [-o, --output ] [-h, --help] [--log-level ] [--log-output ] [--image-format ] [--audio-format ] - [--export-asset-list ] [--filter-by-name ] - [--filter-by-container ] [--filter-by-pathid ] - [--filter-by-text ] [--assembly-folder ] - [--unity-version ] [--not-restore-extension] + [--fbx-scale-factor ] [--fbx-bone-size ] + [--filter-by-name ] [--filter-by-container ] + [--filter-by-pathid ] [--filter-by-text ] + [--spritealpha-mode ] [--alphatex-resampler ] + [--shadow-gamma ] [--original-avg-names] + [--add-aliases] [--export-asset-list ] + [--assembly-folder ] [--unity-version ] + [--not-restore-extension] [--load-all] General Options: -m, --mode Specify working mode - + Export - Exports converted assets ExportRaw - Exports raw data Dump - Makes asset dumps Info - Loads file(s), shows the number of available for export assets and exits Live2D - Exports Live2D Cubism 3 models + SplitObjects - Exports split objects (fbx) Example: "-m info" -t, --asset-type Specify asset type(s) to export - + All - export all asset types, which are listed in the values *To specify multiple asset types, write them separated by ',' or ';' without spaces Examples: "-t sprite" or "-t tex2d,sprite,audio" or "-t tex2d;sprite;font" @@ -67,12 +72,16 @@ Convert Options: None - Do not convert audios and export them in their own format Example: "--audio-format wav" -Advanced Options: - --export-asset-list Specify the format in which you want to export asset list - - None - Do not export asset list - Example: "--export-asset-list xml" +FBX Options: + --fbx-scale-factor Specify the FBX Scale Factor + Specify the FBX Bone Size + Specify the name by which assets should be filtered *To specify multiple names write them separated by ',' or ';' without spaces Example: "--filter-by-name char" or "--filter-by-name char,bg" @@ -90,8 +99,49 @@ Advanced Options: *To specify multiple values write them separated by ',' or ';' without spaces Example: "--filter-by-text portrait" or "--filter-by-text portrait,art" + +Arknights Options: + --spritealpha-mode Specify the mode in which you want to export sprites with alpha texture + + None - Export sprites without alpha texture applied + InternalOnly - Export sprites with internal alpha texture applied (if exist) + SearchExternal - Export sprites with internal alpha texture applied, + and in case it doesn't exist, Studio will try to find an external alpha texture + Example: "--spritealpha-mode internalOnly" + + --alphatex-resampler Specify the alpha texture upscale algorithm for 2048x2048 sprites + + Mitchell - Mitchell Netravali algorithm. Yields good equilibrium between + sharpness and smoothness (produces less artifacts than bicubic in the current use case) + Spline - Similar to Mitchell Netravali but yielding smoother results + Welch - A high speed algorithm that delivers very sharpened results + Example: "--alphatex-resampler bicubic" + + --shadow-gamma Specify the gamma correction of semi-transparent shadow for 2048x2048 sprites + + <0 - Make the shadow darker + 0 - Do not change the brightness of the shadow + >0 - Make the shadow lighter + Example: "--shadow-gamma 0" + + --original-avg-names (Flag) If specified, names of avg character sprites will not be fixed + + --add-aliases (Flag) If specified, aliases will be added to avg character sprite names (if exist) + +Advanced Options: + --export-asset-list Specify the format in which you want to export asset list + + None - Do not export asset list + Example: "--export-asset-list xml" + --assembly-folder Specify the path to the assembly folder - --unity-version Specify Unity version. Example: "--unity-version 2017.4.39f1" - --not-restore-extension (Flag) If specified, AssetStudio will not try to use/restore original TextAsset + + --unity-version Specify Unity version + Example: "--unity-version 2017.4.39f1" + + --not-restore-extension (Flag) If specified, Studio will not try to use/restore original TextAsset extension name, and will just export all TextAssets with the ".txt" extension + + --load-all (Flag) If specified, Studio will load assets of all types + (Only for Dump, Info and ExportRaw modes) ``` diff --git a/README.md b/README.md index ccbad86..9c3a0b6 100644 --- a/README.md +++ b/README.md @@ -1,107 +1,80 @@ -# AssetStudioMod +# ArknightsStudio -[![Build status](https://ci.appveyor.com/api/projects/status/5qyai0hqs0ktyara/branch/AssetStudioMod?svg=true)](https://ci.appveyor.com/project/aelurum/assetstudiomod/branch/AssetStudioMod) +[![Build status](https://ci.appveyor.com/api/projects/status/857ucvvp0cykv1ni?svg=true)](https://ci.appveyor.com/project/aelurum/arknightsstudio) -**AssetStudioMod** - modified version of Perfare's [AssetStudio](https://github.com/Perfare/AssetStudio), mainly focused on UI optimization and some functionality enhancements. +**ArknightsStudio** is a modified version of AssetStudio designed for Arknights. Based on [AssetStudioMod](https://github.com/aelurum/AssetStudio). **Neither the repository, nor the tool, nor the author of the tool, nor the author of the modification is affiliated with, sponsored, or authorized by Unity Technologies or its affiliates.** -Since the original repo has been archived, it's worth saying that you shouldn't expect support for newer versions of Unity from this fork. -Unfortunately, I can't continue Perfare's work and keep AssetStudio up to date. - -## Game specific modifications - -- ArknightsStudio - soon™ - -## AssetStudio Features - -- Support version: - - 3.4 - 2022.1 -- Support asset types: - - **Texture2D** : convert to png, tga, jpeg, bmp, webp - - **Sprite** : crop Texture2D to png, tga, jpeg, bmp, webp - - **AudioClip** : mp3, ogg, wav, m4a, fsb. Support converting FSB file to WAV(PCM) - - **Font** : ttf, otf - - **Mesh** : obj - - **TextAsset** - - **Shader** (for Unity < 2021) - - **MovieTexture** - - **VideoClip** - - **MonoBehaviour** : json - - **Animator** : export to FBX file with bound AnimationClip - -## AssetStudioMod Features +## ArknightsStudio Features - CLI version (for Windows, Linux, Mac) - `Animator` and `AnimationClip` assets are not supported in the CLI version -- Support of sprites with alpha mask -- Support of image export in WebP format -- Support of Live2D Cubism 3 model export - - Ported from my fork of Perfare's [UnityLive2DExtractor](https://github.com/aelurum/UnityLive2DExtractor) - - Using the Live2D export in AssetStudio allows you to specify a Unity version and assembly folder if needed -- Detecting bundles with UnityCN encryption - - Detection only. If you want to open them, please use Razmoth's [Studio](https://github.com/RazTools/Studio) -- Some UI optimizations and bug fixes (See [CHANGELOG](https://github.com/aelurum/AssetStudio/blob/AssetStudioMod/CHANGELOG.md) for details) - +- Support of sprites with alpha texture +- Support of portrait sprites +- Correct support of avg character sprites +- Correct support of character art sprites ## Requirements -- AssetStudioMod.net472 +- ArknightsStudio-net472 - GUI/CLI - [.NET Framework 4.7.2](https://dotnet.microsoft.com/download/dotnet-framework/net472) -- AssetStudioMod.net6 +- ArknightsStudio-net6 - GUI/CLI (Windows) - [.NET Desktop Runtime 6.0](https://dotnet.microsoft.com/download/dotnet/6.0) - CLI (Linux/Mac) - [.NET Runtime 6.0](https://dotnet.microsoft.com/download/dotnet/6.0) -- AssetStudioMod.net7 +- ArknightsStudio-net7 - GUI/CLI (Windows) - [.NET Desktop Runtime 7.0](https://dotnet.microsoft.com/download/dotnet/7.0) - CLI (Linux/Mac) - [.NET Runtime 7.0](https://dotnet.microsoft.com/download/dotnet/7.0) ## CLI Usage -You can read CLI readme [here](https://github.com/aelurum/AssetStudio/blob/AssetStudioMod/AssetStudioCLI/ReadMe.md). +You can read CLI readme [here](https://github.com/aelurum/AssetStudio/blob/ArknightsStudio/AssetStudioCLI/ReadMe.md). ### Run -- Command-line: `AssetStudioModCLI ` -- Command-line for Portable versions (.NET 6+): `dotnet AssetStudioModCLI.dll ` +- Command-line: `ArknightsStudioCLI ` +- Command-line for Portable versions (.NET 6+): `dotnet ArknightsStudioCLI.dll ` ### Basic Samples - Show a list with a number of assets of each type available for export ``` -AssetStudioModCLI -m info +ArknightsStudioCLI -m info ``` - Export assets of all supported for export types ``` -AssetStudioModCLI +ArknightsStudioCLI ``` - Export assets of specific types ``` -AssetStudioModCLI -t tex2d +ArknightsStudioCLI -t sprite ``` ``` -AssetStudioModCLI -t tex2d,sprite,audio +ArknightsStudioCLI -t tex2d,sprite,audio +``` +- Export portrait sprites +``` +ArknightsStudioCLI -t akPortrait ``` - Export assets grouped by type ``` -AssetStudioModCLI -g type +ArknightsStudioCLI -g type ``` - Export assets to a specified output folder ``` -AssetStudioModCLI -o +ArknightsStudioCLI -o ``` - Dump assets to a specified output folder ``` -AssetStudioModCLI -m dump -o +ArknightsStudioCLI -m dump -o ``` -- Export Live2D Cubism models +- Export assets and create a log file ``` -AssetStudioModCLI -m live2d +ArknightsStudioCLI --log-output both ``` -> When running in live2d mode you can only specify `-o`, `--log-level`, `--log-output`, `--export-asset-list`, `--unity-version` and `--assembly-folder` options. -Any other options will be ignored. - Export all FBX objects (similar to "Export all objects (split)" option in the GUI) ``` -AssetStudioModCLI -m splitObjects +ArknightsStudioCLI -m splitObjects ``` > When running in splitObjects mode you can only specify `-o`, `--log-level`, `--log-output`, `--export-asset-list`, `--image-format`, `--filter-by-name` and `--unity-version` options. Any other options will be ignored. @@ -109,50 +82,50 @@ Any other options will be ignored. ### Advanced Samples - Export image assets converted to webp format to a specified output folder ``` -AssetStudioModCLI -o -t sprite,tex2d --image-format webp +ArknightsStudioCLI -o -t sprite,akPortrait,tex2d --image-format webp ``` -- Show the number of audio assets that have "voice" in their names +- Export avg character sprites with aliases in their names ``` -AssetStudioModCLI -m info -t audio --filter-by-name voice +ArknightsStudioCLI -t sprite --add-aliases ``` -- Export audio assets that have "voice" in their names +- Export character art sprites without brightness change of semi-transparent shadow for 2048x2048 images ``` -AssetStudioModCLI -t audio --filter-by-name voice +ArknightsStudioCLI -t sprite --shadow-gamma 0 ``` -- Export audio assets that have "music" or "voice" in their names +- Show the number of audio assets that have "voice" in their containers ``` -AssetStudioModCLI -t audio --filter-by-name music,voice +ArknightsStudioCLI -m info -t audio --filter-by-container voice +``` +- Export audio assets that have "voice" in their containers +``` +ArknightsStudioCLI -t audio --filter-by-container voice +``` +- Export audio assets that have "music" or "voice" in their containers +``` +ArknightsStudioCLI -t audio --filter-by-container music,voice ``` ``` -AssetStudioModCLI -t audio --filter-by-name music --filter-by-name voice +ArknightsStudioCLI -t audio --filter-by-container music --filter-by-container voice ``` - Export audio assets that have "char" in their names **or** containers ``` -AssetStudioModCLI -t audio --filter-by-text char +ArknightsStudioCLI -t audio --filter-by-text char ``` -- Export audio assets that have "voice" in their names **and** "char" in their containers +- Export audio assets that have "loop" in their names **and** "music" in their containers ``` -AssetStudioModCLI -t audio --filter-by-name voice --filter-by-container char +ArknightsStudioCLI -t audio --filter-by-name loop --filter-by-container music ``` - Export FBX objects that have "model" or "scene" in their names and set the scale factor to 10 ``` -AssetStudioModCLI -m splitObjects --filter-by-name model,scene --fbx-scale-factor 10 -``` -- Export MonoBehaviour assets that require an assembly folder to read and create a log file -``` -AssetStudioModCLI -t monobehaviour --assembly-folder --log-output both -``` -- Export assets that require to specify a Unity version -``` -AssetStudioModCLI --unity-version 2017.4.39f1 +ArknightsStudioCLI -m splitObjects --filter-by-name model,scene --fbx-scale-factor 10 ``` - Load assets of all types and show them (similar to "Display all assets" option in the GUI) ``` -AssetStudioModCLI -m info --load-all +ArknightsStudioCLI -m info --load-all ``` - Load assets of all types and dump Material assets ``` -AssetStudioModCLI -m dump -t material --load-all +ArknightsStudioCLI -m dump -t material --load-all ``` ## GUI Usage @@ -161,13 +134,13 @@ AssetStudioModCLI -m dump -t material --load-all Use **File->Load file** or **File->Load folder**. -When AssetStudio loads AssetBundles, it decompresses and reads it directly in memory, which may cause a large amount of memory to be used. You can use **File->Extract file** or **File->Extract folder** to extract AssetBundles to another folder, and then read. +When ArknightsStudio loads AssetBundles, it decompresses and reads it directly in memory, which may cause a large amount of memory to be used. You can use **File->Extract file** or **File->Extract folder** to extract AssetBundles to another folder, and then read. ### Extract/Decompress AssetBundles Use **File->Extract file** or **File->Extract folder**. -### Export Assets, Live2D models +### Export Assets Use **Export** menu. @@ -183,14 +156,6 @@ Select model from "Scene Hierarchy" then select the AnimationClip from "Asset Li Export Animator will export bound AnimationClip or use **Ctrl** to select Animator and AnimationClip from "Asset List", using **Export->Export Animator with selected AnimationClip** to export. -### Export MonoBehaviour - -When you select an asset of the MonoBehaviour type for the first time, AssetStudio will ask you the directory where the assembly is located, please select the directory where the assembly is located, such as the `Managed` folder. - -#### For Il2Cpp - -First, use [Il2CppDumper](https://github.com/Perfare/Il2CppDumper) to generate dummy dll, then when using AssetStudio to select the assembly directory, select the dummy dll folder. - ## Build * Visual Studio 2022 or newer