github akirahayabusa/ngb-pc-native-port-release v2.2.36.2
Ninja Gaiden Black Hurricane PC 2.2.36.2

59 minutes ago

《忍者龙剑传 黑之章》(含飓风版中文汉化 vb-zh-x2.1)与《忍者龙剑传》(2004)的非官方 Windows 原生移植。2.2.36.2。

2.2.36.2:Linux / Wine 下的“可用区块不足”和启动器方块字

这是 2.2.36.1 的修正版,只改了下面几处,都是为在 Linux(Wine)上玩的玩家准备的。Windows 上的游戏与启动器行为和 2.2.36.1 相同。

先看这里:这次更新对你有什么影响

你的情况 更新后
Windows 玩家 没有变化(启动器每一页与 2.2.36.1 逐像素相同;剩余空间的回答也相同)
Linux / Wine(如 Batocera)玩家,每次开机都提示“没有足够的可用区块” 如果你的盘其实还有空间,提示不再出现;如果盘真的满了,提示照旧(这时提示是对的,请清理磁盘)
Linux / Wine 玩家,启动器里中文和图标都是方块 系统里有中文字体时正常显示中文;没有就改用英文显示、不画图标,不再有方块
Linux / Wine 玩家,用启动器“从镜像安装”时提示空间不足 同上:盘其实有空间就能安装

修了什么

  1. 系统查不到剩余空间时,实际写入 1 MB 来判断
    • 一位 Batocera 玩家每次开机都提示“没有足够的可用区块来保存游戏”。日志显示:系统对一块 461 GB 的盘回答“剩余 0 字节”。
    • 0 有两种可能:盘真的满了,或者这块盘的文件系统不报剩余空间(某些外接盘驱动会这样)。查询函数本身分不出来,换别的函数也一样——在 Wine 里它们最终问的是 Linux 的同一个地方。
    • 现在:只有系统回答 0 或查询失败时,程序在 savedata 文件夹里写一个 1 MB 的临时文件并立即删除。写得进去,就按以前的规则回答(分区容量);写不进去,才回答 0,游戏会自己提示区块不足——这时提示是真实的。最多每 10 秒验证一次,结果写进日志。
    • 系统给出数字时(所有正常的 Windows 电脑),和 2.2.36.1 完全一样:报系统给的可用空间,最多到分区容量。
    • 启动器“从镜像安装”的空间检查用同样的方法:写得进去就允许安装,显示“可用空间未知”;写不进去仍显示空间不足。
  2. 启动器在没有中文字体 / 图标字体的系统上不再显示方块
    • 启动器的中文用 Windows 自带的“微软雅黑”,图标用 Windows 的图标字体;Wine 里两者都没有,于是全是方块。
    • 现在中文字体按顺序找:微软雅黑 → 黑体、宋体 → Noto Sans CJK、思源黑体、文泉驿等 Linux 常见中文字体 → 系统里任何含中文字的字体。一个都没有,启动器用英文显示(不改你保存的语言设置),左上角写 NINJA GAIDEN,“ZH”按钮变灰;没有图标字体就不画图标。
    • 想在 Wine 里看到中文启动器:把任意一个中文字体(如 Windows 的 msyh.ttc,或 NotoSansCJK-Regular.ttc、文泉驿)复制到 Wine 前缀的 drive_c/windows/Fonts 里即可。

Linux / Wine 玩家的其他提示

  • 加载角色时崩溃:如果缓存曾被写坏(例如旧版卡死时被强制关闭或断电),读缓存里的角色文件会崩溃。删除 savedata 下 Partition4、Partition5 里的内容即可(只是缓存,游戏会重建;不要动 Partition1,那是存档)。删除后第一次启动会重建缓存,开场动画可能花屏一次,之后正常。
  • 已知问题:部分 Wine 环境下 CG 画面不动、只有字幕在动。这一版没有修,正在排查(怀疑 Wine 对 Windows“内存写入监视”的支持不完整)。Windows 上不受影响。

测试

  • 发布包:Windows Defender 扫描三个程序,无威胁;文件清单与 2.2.36.1 相同(11 个),附带的着色器种子等数据文件逐字节相同;程序文件属性显示 2.2.36.2。
  • 启动器:9 个页面 × 黑之章 / 2004 × 中文 / 英文,共 36 张截图,与 2.2.36.1 逐像素相同;模拟“没有中文字体和图标字体”的系统截图:全英文,没有方块。
  • 剩余空间:正常运行时存档分区 312,501 个区块、缓存分区 48,000 个,与 2.2.36.1 相同,不触发写入验证;临时把系统回答改成 0 测试(测完还原):能写入时存档分区报 312,501 个区块、缓存分区 48,000 个,写入被拒绝时都报 0 个区块;没有残留临时文件。
  • 冒烟测试(核显后台,发布包本身):黑之章 150 秒与 2004 更新补丁版 20 秒,绘制状态全部回放、0 条遗漏,0 次卡顿;空间数字与 2.2.36.1 相同。
  • 性能(核显,待机演示 160 秒,与 2.2.36.1 各跑 1 次,测试期间无其他负载):游戏速度 93.6% 对 93.7%;平均帧时间 4.61 对 4.60 ms,99% 帧 16.96 对 16.97 ms,超过 16.7 ms 的帧 607 对 606 个,卡顿 3 对 2 次。
  • 新代码在默认设置下:只有系统回答 0 或查询失败时才多一次写入;启动器只在启动时查一次字体;没有测试用代码。

源码

本版提交:20500c6(写入验证)、6ddf032(回到 2.2.36.1 的空间规则,只有查不到时写入验证)、a2bcd8f + 05adb76(启动器字体)、01fce87(版本号与 README)。中间的 d80b411、c13929a、02f415e、aeea345 是测试包阶段的做法,已被上面几项取代。

发布包

  • ngb-hurricane-pc-2.2.36.2-win32.zip
  • 大小:3,413,011 字节
  • SHA-256:4818e019afc18b452f81acb4a86e6c88f46358a3bba5379c61fab2ef42c95ceb
  • 符号包 ngb-hurricane-pc-2.2.36.2-win32-symbols.zip:39,381,217 字节
  • SHA-256:082c6162cd157d78f1e9035e3f7c5944d8ac9f593ce2e2515a81be64c28efc6e

作者:b站 哈雅布撒(QQ:2682557218)


English

An unofficial native Windows port of Ninja Gaiden Black (including the Hurricane Chinese translation vb-zh-x2.1) and Ninja Gaiden (2004). 2.2.36.2.

2.2.36.2: "not enough free blocks" and box characters in the launcher under Linux / Wine

A fix release of 2.2.36.1; only the following changed, all for players on Linux (Wine). On Windows the game and the launcher behave as in 2.2.36.1.

Start here: what this update means for you

Your setup After the update
Windows No change (every launcher page matches 2.2.36.1 pixel for pixel; the free space given to the game is the same)
Linux / Wine (e.g. Batocera), "not enough free blocks" at every start If your disk does have room, the message is gone; if it really is full, the message stays (then it is right: free some space)
Linux / Wine, the launcher's Chinese and icons are boxes With a Chinese font on the system the launcher shows Chinese; without, it shows in English with no icons - no boxes
Linux / Wine, the launcher's install from an image says there is no room As above: if the disk has room, the install goes ahead

What was fixed

  1. With no free space from the system, a 1 MB test write decides
    • A Batocera player was told "not enough free blocks to save the game" at every start. The log: the system said 0 bytes free on a 461 GB disk.
    • 0 can mean a full disk, or a file system that gives no free space (some external-disk drivers do). The query cannot tell, and no other call would: under Wine they all end at the same place in Linux.
    • Now, only when the system says 0 or the query fails, 1 MB is written to a temporary file in the savedata folder and removed at once. It fits, and the answer is as before (the partition's size); it does not, and 0 is reported - the game's own "not enough free blocks", then true. Redone at most every 10 s; logged.
    • With a figure from the system (every normal Windows PC), as in 2.2.36.1: the free space given, capped at the partition's size.
    • The launcher's space check for an install from an image works the same way: it fits, and the install may go ahead ("free space unknown"); it does not, and it still says there is no room.
  2. No box characters in the launcher without a Chinese or an icon font
    • The launcher's Chinese is drawn in Windows' Microsoft YaHei and its icons in Windows' icon font; Wine has neither, so all were boxes.
    • The Chinese font is now the first found of: YaHei, then SimHei and SimSun, then Linux's usual Chinese fonts (Noto Sans CJK, Source Han Sans, WenQuanYi...), then any font with Chinese characters. With none the launcher shows in English (your saved language is kept), the corner reads NINJA GAIDEN and the ZH button is greyed; with no icon font the icons are left out.
    • For a Chinese launcher under Wine, copy any Chinese font (Windows' msyh.ttc, NotoSansCJK-Regular.ttc, WenQuanYi) into the Wine prefix's drive_c/windows/Fonts.

More for Linux / Wine players

  • A crash when a character loads: a cache written wrong (an old build killed or the machine switched off while it hung, say) crashes when its character files are read. Delete what is in savedata's Partition4 and Partition5 (only the cache, the game rebuilds it; leave Partition1, your saves, alone). The first start after that rebuilds the cache and the opening movie may be garbled once; then it is fine.
  • Known issue: on some Wine setups the CG picture stands still and only the subtitles move. Not fixed in this release; under investigation (Wine's support of Windows' memory write watch is suspected). Windows is not affected.

Tests

  • The package: Windows Defender scan of the three programs, no threats; the same 11 files as 2.2.36.1, its seed data files byte for byte; the programs' properties say 2.2.36.2.
  • Launcher: 9 pages x Black / NG2004 x Chinese / English, 36 snapshots, identical to 2.2.36.1 pixel for pixel; drawn as on a system without a Chinese or an icon font: all English, no boxes.
  • Free space: a normal run gives the save partition 312,501 blocks and the cache partition 48,000, as 2.2.36.1, with no test write; with the system's answer forced to 0 for a test (undone after), room -> 312,501 blocks for saves and 48,000 for the cache, the write denied -> 0 blocks for both; no temporary file left.
  • Smoke tests (Iris Xe, background, the package itself): Black 150 s and the NG2004 title update 20 s, all draw states replayed, none left out, no hitch; the free space figures as 2.2.36.1.
  • Performance (Iris Xe, attract demo 160 s, one run each against 2.2.36.1, nothing else running): game speed 93.6% vs 93.7%; average frame 4.61 vs 4.60 ms, 99th percentile 16.96 vs 16.97 ms, frames over 16.7 ms 607 vs 606, hitches 3 vs 2.
  • New code with the default settings: one more write only when the system says 0 or the query fails; the launcher looks for fonts once at start; no test code.

Source

This release's commits: 20500c6 (the test write), 6ddf032 (back to 2.2.36.1's rule, the test write only with no figure), a2bcd8f + 05adb76 (launcher fonts), 01fce87 (version and README). d80b411, c13929a, 02f415e and aeea345 in between were the test packages' approaches, replaced by the above.

Package

  • ngb-hurricane-pc-2.2.36.2-win32.zip
  • Size: 3,413,011 bytes
  • SHA-256: 4818e019afc18b452f81acb4a86e6c88f46358a3bba5379c61fab2ef42c95ceb
  • Symbols ngb-hurricane-pc-2.2.36.2-win32-symbols.zip: 39,381,217 bytes
  • SHA-256: 082c6162cd157d78f1e9035e3f7c5944d8ac9f593ce2e2515a81be64c28efc6e

Author: 哈雅布撒 on Bilibili (QQ: 2682557218)

Don't miss a new ngb-pc-native-port-release release

NewReleases is sending notifications on new releases.