Sun Haven
You are viewing a potentially older version of this package. View Latest Version
Install with App

Details

Date Uploaded
Downloads
48
Size
59KB

Quiet Crafting — sound menu for Sun Haven

Silence crafting-table sawing and manage individual sounds in game. Open chat, enter /sounds, and submit to open the sound menu.

The initial mute list is WoodcuttingTable2; ElvenCraftingTable1. The basic table's clip was identified in a player runtime log; the elven clip was verified in the installed game assets.

0.4.2 is an early test release. Build, behavior, game API, and compiled volume-hook checks pass. The latest font-cache fix still needs in-game confirmation.

Install or upgrade

  1. Close the game and select your Sun Haven profile in r2modman or Thunderstore Mod Manager.
  2. Find QuietCrafting in the mod browser and install it. The declared BepInExPack by BepInEx dependency is installed by the manager.
  3. Click Start modded, load your character, and enter /sounds in chat.

For a local ZIP, use Settings → Install local mod and select QuietCrafting-0.4.2.zip. Reuse the existing local package's author when upgrading it. When moving from a local test build to the published package, keep only one installed copy of QuietCrafting; keep the existing configuration file.

/sounds replaces the old /soundlog command. Existing mute settings are kept. On the first upgrade from the original 0.1.0 preset, the unchanged preset migrates to the corrected table sounds; customized and intentionally empty lists remain unchanged.

The ZIP follows the manager's documented local installation and package structure. Use Install local mod, rather than profile import.

For a manual installation into an existing BepInEx setup, extract only plugins/QuietCrafting/QuietCrafting.dll into BepInEx/plugins/QuietCrafting/.

Sound menu

The menu uses a game-style layout: upright icon tabs extend above a gold/red window frame, with a centered title, corner close button, and one inset parchment page. Original pixel-art borders and icons complement Sun Haven's loaded button, scrollbar, and Gurajada font assets. Shared game assets are resolved at runtime and are not redistributed. Native borders are scaled for the overlay canvas rather than enlarged with the game's world-sprite scale.

Six full sound rows emphasize large outlined clip names beside timestamps. Toolbar icons, scrollbar arrows, and an explicit global-state indicator provide controls without extra technical subtext. Enabled toggles use the game's pressed button frame when loaded; otherwise they keep the normal frame. Captions and icons move with the native face when pressed. Dark timestamps, search text, and footer labels use a plain material without inherited outlines or stroke dilation. The menu owns its dynamic font textures and materials so glyph additions cannot overwrite the game's font atlas, or be overwritten by it. Opening the menu writes a Sound menu text: summary to LogOutput.log; a healthy summary reports zero empty meshes.

Sound log

Shows the latest 200 playback requests, including repeated and muted clips, newest first. Each row emphasizes the exact clip name alongside its capture time. Technical playback details remain available in optional file logging.

  • Mute / Unmute: change that clip's current mute preference immediately. All rows representing the same clip share one preference.
  • Search: filter the list by part of a sound's name.
  • Pause log / Resume log: freeze the displayed snapshot while collection continues in the background.
  • Clear: empty the recent log. This does not remove saved sounds or mutes.
  • Copy list: copy the filtered list, including complete names, to the clipboard.

Live controls update active audio sources managed by the patched playback helpers, as well as future playback. Unmuting does not replay a sound that has already finished. Muting matches exact clip names, without regard to case; every use of that clip through the supported paths shares the setting.

Saved sounds

Shows every currently muted sound and previously muted sounds you have kept. This list and its mute preferences survive game restarts in the mod's config.

  • Mute / Unmute: toggle the sound without removing it from the saved list.
  • Remove: unmute and forget the sound. It stays absent after a restart. Muting it again from the Sound log tab adds it back.
  • Search and Copy list work on this tab too.

The Global Enable toggle applies all selected mutes when on and bypasses them when off, preserving your selections. Its helper text shows the current ON / OFF state. Changes save automatically; the sound menu does not need a separate Apply button.

Close with X or Esc. The menu holds the local character's input and blocks clicks behind its backdrop. The world and crafting continue running. The command is handled locally, is not broadcast to other players, and does not enable cheats.

Configuration and optional file logging

After one launch, the selected profile contains:

BepInEx/config/local.sunhaven.quietcrafting.cfg

Example settings:

[General]
Enabled = true

[Sounds]
MutedClips = WoodcuttingTable2; ElvenCraftingTable1
SavedClips = WoodcuttingTable2; ElvenCraftingTable1

[Diagnostics]
LogSounds = false

MutedClips holds active mute selections; SavedClips also remembers sounds you unmuted. Entries use semicolons, exact clip names, and no file extensions or wildcards. The menu updates both settings for you. The internal DefaultsRevision setting controls one-time preset migration.

For external edits, close the game, use r2modman's Config editor or a text editor, and restart. Changes made through an optional in-game BepInEx ConfigurationManager update playback immediately.

/sounds works with LogSounds = false. If enabled, file logging writes each unique clip name once per session to BepInEx/LogOutput.log:

[Sound] Clip="WoodcuttingTable2" Muted=True Via=PlayOneShot

The recent log is held only in memory. Saved names and mute selections persist. These are playback requests, not microphone recordings; requests can include distant or otherwise inaudible sounds. sound-names.txt is a reference list from inspected assets and an observed runtime log, not a complete list of every possible playback path.

Test checklist

  1. Check LogOutput.log for Ready: patched 4/4 audio methods, Live volume control ready, and Sound menu ready: /sounds, with no plugin errors.
  2. Craft at the basic table and confirm the sawing is muted. In /sounds, use Unmute while it is playing, then Mute, and check both changes apply.
  3. On Saved sounds, unmute a clip and confirm it stays listed. Remove it and confirm it disappears. Mute it from Sound log and confirm it returns.
  4. Restart and check that muted, unmuted, and removed entries retain their states.
  5. Check normal chat, search typing, tab switching, scrolling, pause, clear, copying, closing with X/Esc, and movement after closing. Return to the title screen and reload the save, then open the menu again.
  6. Confirm music, footsteps, tools, and FinishCrafting2 remain normal unless specifically selected. If available, test an elven table and an ambient loop.
  7. Check the gold frame, upright tab icons, selected-tab height, six full rows, scrollbar arrows, and readable outlined text. Verify Global Enable updates its check/minus icon, indicator, and ON/OFF help without losing saved mutes.

Scope and removal

The plugin patches Sun Haven's managed audio helpers and their volume writes. Direct Unity AudioSource calls and music playback through other paths may not be covered. It preserves the game's object creation, cleanup, and intended volume values, and updates tracked active sources when preferences change.

Settings affect the local player's audio. The mod does not edit saves, recipes, items, or world time. Disable/uninstall it in the manager to remove its effect; saves do not depend on the plugin.

Build from source

Install a .NET SDK and build using your own game installation:

.\scripts\Build-Package.ps1 -GameDirectory 'D:\SteamLibrary\steamapps\common\Sun Haven'

The first restore uses NuGet.org and BepInEx's NuGet feed. Output is dist/QuietCrafting-0.4.2.zip and a SHA-256 checksum. Only the mod DLL and its documentation are packaged. Unity, game, BepInEx, and Harmony libraries are not redistributed; BepInExPack supplies the loader and Harmony.

With a .NET 10 SDK, run the state and command behavior checks:

dotnet run --project tests/QuietCrafting.Checks -c Release

scripts/Test-GameApi.ps1 reads the game's metadata with Mono.Cecil from the local NuGet cache (or -CecilDll <path>). scripts/Test-VolumeTranspiler.ps1 checks the compiled instruction transform without invoking Unity native audio. See docs/DEVELOPMENT.md for the implementation and validation boundary.

Thunderstore development is made possible with ads. Please consider making an exception to your adblock.