New texture choices for HC and SVS - enimaroah-cubic/Sb3UGS GitHub Wiki

As long as there is no sideloader, we are modding hard and create AssetBundles (AB) with the contents and the list entry. The contents in this example is a texture, and the list entry is used from the game to integrate every content; not only new ABs.

Let's begin with the contents - a texture for the iris of the eye. Drag 'n drop mt_eye_00.unity3d into Sb3UGS and double click a texture. Should look like this: image

Click "Export". There is no dialog with the destination. You find the texture exported in the game folder. If you can't find it, see the Script window with the export statement.

Editing in Gimp

image

  1. Scale upwards, so that the ellipse becomes a circle
  2. Rotate the circle. Gimp extends the resolution!
  3. Crop to the former upscaled resolution in step #1
  4. Scale downwards to original resolution

image

Drag 'n drop your edited texture into Sb3UGS: image

Click "Replace" in the Texture editor. Don't worry, as long as you don't save the original AB like this you won't lose the original. We get even more destructive now, and delete all other textures in the file. Click on the first texture, shift-Click on another to select a range of textures. Use Ctrl-Click to select the next start of a range of textures. Shift-Click to the end of the second range.

image

Then Shift-Del all selected textures at once.

image

And "Save As ..." the file with a new name.

image

In this example I had saved the file as mt_eye_00_645.unity3d which we will now reference in the list entry.

Open 000_00.unity3d and double click mt_eye[000_00] TextAsset. The list entry for texture cf_eye_06 looks like this:

image

We simply overwrite columns Name, MainAB with the new contents file, and EyeTex only if you had renamed the texture. If you did make sure that your texture attributes were like the original before. The ID for a new choice must be UNIQUE for the whole game. If you use an existing ID by accident the original entry is no longer visible in the selection in game. You would use an existing ID to override an original.

For finding ID conflicts you can use this batchfile
@echo off & setlocal ENABLEEXTENSIONS & setlocal ENABLEDELAYEDEXPANSION
REM Installation:
REM 1. Put this file into the game's abdata\list\characustom folder
REM 2a. Either create a shortcut in the game's Tools folder to SB3UtilityScript.exe,
REM 2b. or correct the assignment of SB3UGS in line 16 so that it references the path and filename to SB3UtilityScript.exe.
REM Execution:
REM Open a command prompt. Drop this file into the command prompt and hit Enter.

cd /D "%~dp0"
if %CD:~-12% NEQ \characustom (
  echo Wrong folder. The script is meant to be used in the game's abdata\list\characustom folder
  goto :EOF
)

REM reference to the scripting version of Sb3UGS, e.i. via link
set SB3UGS=..\..\..\Tools\SB3UtilityScript.lnk
if not exist %SB3UGS% (
  echo SB3UtilityScript not found. Edit the script line 16 so that behind the
  echo equal sign is the path to SB3UtilityScript.exe or a shortcut to it.
  goto :EOF
)

set SCRIPT=reportIDconflicts.script
echo LoadPlugin(PluginDirectory+"UnityPlugin.dll")>%SCRIPT%
set varIdx=0
set unity3Deditors=
for %%i in (???_??*.unity3d) do (
  echo unityParser!varIdx! = OpenUnity3d^(path="%%i"^)>>%SCRIPT%
  echo unityEditor!varIdx! = Unity3dEditor^(parser=unityParser!varIdx!^)>>%SCRIPT%
  echo unityEditor!varIdx!.GetAssetNames^(filter=True^)>>%SCRIPT%
  if !varIdx! EQU 0 (
  	set unity3Deditors=unityEditor!varIdx!
  ) else (
  	set unity3Deditors=!unity3Deditors!, unityEditor!varIdx!
  )
  set /a varIdx=!varIdx! + 1
)
set categoryNames=ao_arm, ao_body, ao_face, ao_hair, ao_hand, ao_head, ao_leg, ao_neck, ao_waist, bo_body, bo_hair_b, bo_hair_f, bo_hair_o, bo_hair_s, bo_head, bo_nail, bo_nail_leg, bodypaint_layout, cha_eyeset, cha_sample_f, cha_sample_m, co_bot, co_bra, co_gloves, co_panst, co_shoes, co_shorts, co_socks, co_top, facepaint_layout, mole_layout, mt_body_detail, mt_body_paint, mt_cheek, mt_eye, mt_eye_gradation, mt_eye_hi_up, mt_eye_white, mt_eyebrow, mt_eyelid, mt_eyeline_down, mt_eyeline_up, mt_eyepipil, mt_eyeshadow, mt_face_detail, mt_face_paint, mt_hairgloss, mt_lip, mt_lipline, mt_mole, mt_nose, mt_pattern, mt_ramp, mt_sunburn, preset_eyepipil
set categoryNames=!categoryNames!, ao_kokan, mt_nip, mt_underhair
FOR %%i in (!categoryNames!) do (
  echo ReportIDConflicts^(categoryName="%%i", unity3dEditors={!unity3Deditors!}^)>>%SCRIPT%
)
%SB3UGS% "%CD%\%SCRIPT%"

Click the first line, shift-click the end of a range. Then press Del to delete the range. This control allows only one range. Then delete all other TextAssets in the file and like with the contents AB use "Save As ..." with a name following this pattern {three digits}_{two digits}_{your choice}.unity3d:

image

image

Support for DigitalCraft

Mods made like above are not loaded in DC until their list and contents files are put into an AssetBundleManifest. ABM files are inside the game's abdata folder. A script for the creation of such an ABM for all missing mods is here.

image

A different texture for clothes?

Same thing. This example shows one for the bra category. The texture is handled in the same way as above. Only the list TextAsset and entry are different. So we put co_bra[000_02] TextAsset from 000_00.unity3d into our own list file as above with the edited content. A unique ID, display name and the AB with the texture are different. The texture got the same name in the new file for the new choice.

image

image

Clothes with Transparency

Most clothes are opaque and in order to make them transparent you can use lif_main_cloth_alpha shader. This shader might not be present in the current file and needs to be copied over. (See Some use cases#editing-monobehaviours how to copy assets). But if the material's shader would be switched then the original clothes would no longer be the same. For this reason the whole Animator needs to be copied to make it independent and then the material's shader can be changed. (See the First Steps for copying the Animator and saving later into a new file). Open a clothes Animator which has that shader (heroine's e.i. It has transparent sleeves). The CustomRenderQueue is 3000 in this example with the tundere top: image

⚠️ **GitHub.com Fallback** ⚠️