Files
MemRelay/projects/4eb30bec-355e-49d6-909c-e7868faef4f7/Checkpoint 2026-10-19 20-13-12 UTC [8e52c7d441].md
T
memrelay 34a5817c74 create: Checkpoint 2026-10-19 20:13:12 UTC [8e52c7d441]
MemRelay-Operation: checkpoint-save:ammo-display-2026-10-20-0413
MemRelay-Resource: 74ea463b-dd18-4419-be73-2f052efd56fb
2026-10-20 04:13:15 +08:00

24 lines
2.0 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: Checkpoint 2026-10-19 20:13:12 UTC [8e52c7d441]
type: checkpoint
permalink: main/projects/4eb30bec-355e-49d6-909c-e7868faef4f7/checkpoint-2026-10-19-20-13-12-utc-8e52c7d441
stable_id: 74ea463b-dd18-4419-be73-2f052efd56fb
scope: project
memory_type: checkpoint
project_id: 4eb30bec-355e-49d6-909c-e7868faef4f7
usage_profile_id: 0c9feb46-d06e-43cd-9ef0-c5813c84a998
status: active
revision: 1
request_id: ammo-display-2026-10-20-0413
created_at: '2026-10-19T20:13:12.765254+00:00'
updated_at: '2026-10-19T20:13:12.765254+00:00'
tags:
- ammo
- SOTFAssist
---
完成:把已安装的弹药显示 AmmoUi 1.1.2(Im-_-Axel)复刻进 SOTFAssist 定制游戏「界面功能」。没有对得上的公开源码,用 REA 看已安装 DLL。总开关「弹药显示」默认关闭;关掉后不再画右下角弹药。开关下面是不透明度(默认 1,范围 0–1)和显示大小(默认 1,范围 0.1–2),关掉时仍显示但不生效。拿着弹药武器且没打开背包时,右下角显示弹匣剩余和身上总弹药,带枪械图标。没有新增热键。配置在 SOTFAssist.cfg,不进 F1。
关键实现:Features/AmmoDisplay.cs;界面在 Ui/AssistView.cs 的界面功能里,与时间项同层。游戏功能分类保留。
提交:3612412f5de5cbe5341e5e67e0e86a66a5cb48f4 feat: 在界面功能中加入弹药显示;其上另有 d66dfcc3f7f2c011b74a521916fe698c8eaf8804 docs: 标出弹药显示已复刻。未 push。
验证:合进 main 后 Release 编译 0 错误,1 个既有警告(_windowPlaced 未使用)。DLL 已覆盖到 D:\\Game\\Sons.Of.The.Forest.v53951\\Mods\\SOTFAssist.dll,118272 字节,2026-10-20 04:12:12。游戏没在跑。已删 AmmoUi.dll、Mods\\AmmoUi 目录和 UserData\\AmmoUi.cfg。已删 worktree SOTFAssist-ammo 和 ammo 分支。
给下个会话:弹药显示总开关默认关闭。武器类型用 ItemData.WeaponType.AmmoBased。总弹药是 Inventory.AmountOf(弹药类型, true, false)。不要把它放进游戏功能或 F1。不要给它加热键。