You are viewing a potentially older version of this package. View all versions.
Aestelwen-TarExtractor-1.1.0 icon

TarExtractor

Adds a buildable Tar Extractor that passively collects Tar from Plains tar pits.

Date uploaded a week ago
Version 1.1.0
Download link Aestelwen-TarExtractor-1.1.0.zip
Downloads 331
Dependency string Aestelwen-TarExtractor-1.1.0

This mod requires the following mods to function

denikson-BepInExPack_Valheim-5.4.2360 icon
denikson-BepInExPack_Valheim

BepInEx pack for Valheim. Preconfigured with the correct entry point for mods and preferred defaults for the community.

Preferred version: 5.4.2360
ValheimModding-Jotunn-2.30.3 icon
ValheimModding-Jotunn

Jötunn (/ˈjɔːtʊn/, 'giant'), the Valheim Library was created with the goal of making the lives of mod developers easier. It enables you to create mods for Valheim using an abstracted API so you can focus on the actual content creation.

Preferred version: 2.30.3

README

CI Package License: MIT

TarExtractor

Adds a buildable Tar Extractor that passively collects Tar from Plains tar pits.

TarExtractor Example

How It Works

The Tar Extractor works like the Sap Extractor, but for tar pits instead of Ancient Roots:

  • Place it inside a tar pit (it also works on drained pits). Outside a tar pit the placement ghost turns red and a message tells you why.
  • It produces 1 Tar every 60 seconds and holds up to 200 Tar.
  • Interact with it to collect the stored Tar. It drops next to the extractor.
  • Progress is saved on the piece, so it keeps filling up while you are away.

Building It

Find it in the Hammer's Crafting tab. It needs a Workbench nearby and the same materials as the Sap Extractor:

Material Amount
Yggdrasil wood 10
Black metal 5
Dvergr extractor 1

Configuration

Settings are in the BepInEx config file javidahmed64592.tarextractor.cfg. Settings marked "(Synced with server)" use the server's values when the server has the mod installed. DisabledFeatures under [Debug] is for testing: it turns parts of the mod off by name. Leave it empty to play normally.

Compatibility

  • The Tar Extractor is built from the vanilla Sap Extractor, so mods that change the Sap Extractor may change it too.
  • It looks for the vanilla tar pit locations, so world generation mods that rename or replace them may stop it being placed.
  • If a game update breaks part of the mod, that part turns off on its own and the log says which one; the rest keeps working.
  • This mod has not been tested with a gamepad, only with keyboard and mouse.

Uninstalling

Tar Extractors disappear from the world when the mod is removed, along with any Tar stored in them. Collect the Tar and deconstruct them first to get their materials back.

License

This project is licensed under the MIT License - see the LICENSE file for details.

CHANGELOG

Changelog

1.1.1

  • The mod's safety net for game updates no longer wraps the game's item and prefab startup methods, which Jotunn tracks; doing so could drop the game to a few frames a second. Nothing changes in play.

1.1.0

  • Fixed the message for a blocked placement: it said "Invalid placement" instead of why (outside a tar pit, or the pit is full).
  • Safer after game updates: if an update breaks the blocked placement message, only that part turns off and the log says which, in one line; the Tar Extractor can still only be built in a tar pit. If the Tar Extractor itself breaks, the whole mod turns off cleanly instead of throwing errors.
  • Debug setting: the new DisabledFeatures setting under [Debug] turns parts of the mod off by name, for testing.
  • Updated Jotunn to 2.30.3.

1.0.0

  • First stable release. The features are unchanged from 0.4.0.
  • Moved the source files into folders (Core, Extractor, Prefabs, Patches), leaving only Plugin.cs at the root, with each Harmony patch in its own file under Patches. Building the Tar Extractor piece and loading translations moved out of Plugin.cs too. No behaviour change.

0.4.0

  • Collecting Tar is now handled by whoever's game is looking after the extractor, like the vanilla Sap Extractor, so two players collecting at the same moment can no longer both get the Tar.
  • New Max Per Pit setting: the most Tar Extractors that can be built in one tar pit. The default of 0 means no limit, so nothing changes for extractors you have already built. When the pit is full, the placement ghost turns red and a message says why.
  • Declared the mod as required on the server and every client to Jotunn, with matching minor versions.
  • Removed a leftover log message that referred to diagnostics which no longer exist.
  • Added a CI check that the version matches in every file.
  • Moved package.sh into .github/scripts and made it the same for every mod: the name, version and DLL now come from manifest.json and the .csproj.

0.3.1

  • Updated the BepInExPack_Valheim dependency to 5.4.2360.

0.3.0

  • Added an .editorconfig, Directory.Build.props and a CI workflow that runs dotnet format, a Release build and a NuGet vulnerability check.
  • Reformatted the code to match the new code style rules (no behaviour change).
  • Renamed some internal static fields and made string comparisons ordinal to satisfy the new code analysis rules.
  • Tidied up packaging scripts and workflow files.
  • Added a .gitattributes to keep line endings consistent.
  • Moved the local Valheim install paths into Directory.Build.props; set VALHEIM_DIR and BEPINEX_PROFILE_DIR once to build every mod without editing the .csproj.
  • Updated README and icon.

0.2.1

  • Removed diagnostic log lines that were used for development purposes.

0.2.0

  • Fixed the mod failing to load on the current Valheim version ("Cannot get result from void method Player::PlacePiece").
  • New tar-themed effects:
    • The Sap Extractor's green glow and particles are now a very dark purple.
    • The green light has been removed.
    • Oozing tar splashes, borrowed from the Growth, now drip from the spout.
    • These effects only show while the extractor holds Tar, and are no longer visible on the placement ghost.
  • Localization support for all languages supported by Valheim (except Abenaki, which falls back to English).
    • Translations reuse Valheim's own terms for Tar and the Sap Extractor where available.
    • Translation files live in Translations/<Language>.json and are embedded in the mod.

0.1.0

  • New buildable piece, the Tar Extractor, available from the Hammer's Crafting tab.
    • Built at a Workbench using the same materials as the Sap Extractor: 10 Yggdrasil wood, 5 Black metal and 1 Dvergr extractor.
    • Reuses the Sap Extractor model with a darker, tar-like tint.
  • Passive Tar collection: produces 1 Tar every 60 seconds and holds a maximum of 200 Tar.
    • Progress is saved on the piece, so it keeps accumulating while you are away.
    • Interact with the extractor to collect the stored Tar, which is dropped next to it.
    • Hover text shows how much Tar is currently stored.
  • Placement restriction: the Tar Extractor can only be placed inside a tar pit.
    • The placement ghost turns red outside a tar pit.
    • A message is shown if you try to place it somewhere invalid.
  • Admin-synced configuration options for Seconds Per Tar (default 60) and Max Tar (default 200).