The NVN driver's constant segments have the same layout in every game, so the nvn_* profile keys are gone. Combined textures are at c2 0x20 + 8 r (a slot past 31 shares the image table; Hades II binds 34), images at 0x120, separate textures at 0x168 (now always the host's slots 128 + n, as Monster Hunter Rise had them), samplers at 0x568, and the storage buffer tables at c0 0x110 / 0x310 / 0x510. dmsh_build.py decodes with that layout, the replay fills both texture tables, and the translator numbers slots the same way (rebuilt; its SPIR-V and reflection are byte-identical on 1,491 sample shaders, lock updated). The shader_* switches and graphics are gone too; the build reads them from the files (profile_guess.py shader_sources): - Vulkan when main imports Vulkan and not NVN; its capture when the RomFS has no SPIR-V. - A GLSLC capture when main holds GLSL sources and imports glslcCompile. - An Oodle decode for Unreal paks, and the tool-mode decoder for Trinity packs. - GLSLC outputs from every main. - A cover pairing for each single-stage vertex shader (GLSLC, Unreal). build_ipa.sh takes GFXAPI from the NSP script. Also removed: the last D2R pieces (the embedded-shader path in dmsh_build.py, dmsh_facts.py --freeze / --check, maxwell_refs.py, ref/hle_hid_d2r.c). Chain: every profile's dmsh_chain.h is regenerated. The c1_full lists are carried over: the change touches no c1 read, and the rebuilt Octopath Traveler 0, Hades II, Unicorn Overlord and Rhythm Heaven Groove gave the same lists, identical tables and the same reflection apart from separate texture slots + 128. Still to do: - Run the chain procedure for the other NVN profiles. - Engage's and Three Houses' shader tables need a new split: Engage gains Unity's 11 GLSLC shaders in main, and Three Houses' 17 BNSH vertex shaders lose their cover pairs. - Ace Attorney's new tables are in, but its libraries are not rebuilt.
2.6 KiB
2.6 KiB
| 1 | # Game profile of Unicorn Overlord (Switch, base game v0 + update 1.05 = v262144). In bring-up: on the Mac it plays from the title screen into the opening story scene | ||||
|---|---|---|---|---|---|
| 2 | # Format: see dm/games/README.md | ||||
| 3 | # Vanillaware's own engine (as 13 Sentinels: Aegis Rim), SDK 16.2.4, NVN; all data is in 7 CRI CPK archives (Unicorn.CPK, UnicornPatch.CPK and one per language), audio is CRI ADX2 with Opus streams | ||||
| 4 | # (nn::codec's hardware multi-stream decoder, replaced by the SDK's software one in hle_codec.c). | ||||
| 5 | # The shaders are not in RomFS: 2188 GLSLC compiler outputs (magic 0x19866891) are compiled into main's read-only segment (1725 distinct shaders, read by shader_split.py glslc_shaders) | ||||
| 6 | # The two DLC (indices 1 and 2) are licences only: their RomFS holds just the SDK's placeholder file | ||||
| 7 | # ---- Identity ---- | ||||
| 8 | title_id | 010069401ADB8000 | |||
| 9 | program_id | 010069401ADB8000 | |||
| 10 | # ---- App ---- | ||||
| 11 | # Game name: only a label for profile listings and the Mac window title; the iOS app name is the game name in the base NSP, and the bundle ID comes from the base game title ID (build_ipa.sh / NSP script) | ||||
| 12 | name | Unicorn Overlord | |||
| 13 | ipa | UnicornOverlord.ipa | |||
| 14 | app_category | public.app-category.role-playing-games | |||
| 15 | # ---- Versions ---- | ||||
| 16 | # only the merged 1.05 copy is extracted; the base game's own build IDs are added when needed | ||||
| 17 | build | v262144 | 1.05 | main=c841ffe2717ff03a13990480c51da73f | sdk=12f161039300861f1054371f0e36b8c9 |
| 18 | package | v262144 | |||
| 19 | shader_versions | v262144 | |||
| 20 | # ---- Files ---- | ||||
| 21 | # load order as on Horizon: main, sdk (no subsdk: the game has no movie module) | ||||
| 22 | modules | main sdk | |||
| 23 | romfs_marker | Unicorn.CPK | |||
| 24 | zip_store | .CPK:.metallib | |||
| 25 | # ---- Memory ---- | ||||
| 26 | # The NPDM declares no system resource (META +0x14 = 0): the game uses SetHeapSize with pool − used, as 13 Sentinels does. main's bss is 30 MB; the rewritten modules are 92 MB (mem_used). | ||||
| 27 | # Block = 256 MB in front + 256 MB alias region + 256 MB stack region + 3.25 GB heap region = 4 GB; the heap is 3.12 GB. On the Mac about 3.0 GB is resident in the opening story scene | ||||
| 28 | mem_reserve | 0x100000000 | |||
| 29 | mem_alias | 0x10000000 | |||
| 30 | mem_stack | 0x10000000 | |||
| 31 | app_pool | 0xCD500000 | |||
| 32 | # the rewritten modules are larger than the default 64 MB of used memory | ||||
| 33 | mem_used | 0x5c00000 | |||
| 34 | # The engine cuts ring heaps out of a memory pool at 64 KB GPU alignment, and the pool's storage comes from malloc: allocations of 64 KB or more are 64 KB aligned (hle_os.c); | ||||
| 35 | # without it a thread's ring heap keeps base 0 and the game writes to 0x268 right after the title screen | ||||
| 36 | alloc_big_align | on | |||
| 37 | # ---- Shader split (shader_split.py: GLSLC outputs in main, each a single-stage program; the program bound per draw combines a vertex and a pixel shader) ---- | ||||
| 38 | shader_groups | /=romfs | |||
| 39 | shader_note | Unicorn Overlord shaders |