Pixnop.Manifold 0.4.1

dotnet add package Pixnop.Manifold --version 0.4.1
                    
NuGet\Install-Package Pixnop.Manifold -Version 0.4.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Pixnop.Manifold" Version="0.4.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Pixnop.Manifold" Version="0.4.1" />
                    
Directory.Packages.props
<PackageReference Include="Pixnop.Manifold" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Pixnop.Manifold --version 0.4.1
                    
#r "nuget: Pixnop.Manifold, 0.4.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Pixnop.Manifold@0.4.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Pixnop.Manifold&version=0.4.1
                    
Install as a Cake Addin
#tool nuget:?package=Pixnop.Manifold&version=0.4.1
                    
Install as a Cake Tool

<p align="center"> <img src="manifold.svg" width="180" alt="Manifold logo" /> </p>

Manifold

A Vintage Story 1.21+ library mod for declaring and managing custom dimensions.

Mod DB NuGet Build Quality Gate Coverage License: MIT


Download

  • Players: Manifold on the Mod DB - install this (the library other mods depend on). Optional demo: Manifold Sample.
  • Mod developers: reference the API at compile time from NuGet - dotnet add package Pixnop.Manifold. Your mod still declares manifold as a runtime dependency in modinfo.json.

Companion mods

  • Chart (0.1.0, alpha) - dimension-aware world map. Per-dimension tile cache, vanilla-style rendering pipeline (palette + hillshade + blur), hot-swap on transit. Client-side only. Requires Manifold 0.3.1+. Source under companions/Chart/.

Features

  • Custom dimensions - declare persistent or ephemeral dimensions from any mod; boot-time (RegisterStatic) or runtime (Create).
  • Active worldgen - two modes, both configurable per dimension. Bounded (default): Manifold pre-generates a fixed chunk region around the transit target before the player arrives, radius set via WithGenerationRadius. Streaming (opt-in): call .Streaming(loadRadius) and Manifold generates chunks on demand as players move, with no invisible walls at a region edge. The streaming radius is extended to the server view distance so generated terrain always reaches as far as the player can see. The relight band height is set per dimension via WithRelightHeight (default 20).
  • Player transit - ITransitionService.TeleportPlayer moves a player between any two dimensions with a single call.
  • Entity transit - ITransitionService.TeleportEntity moves non-player entities (dropped items, mobs) between dimensions; the destination region is generated on demand before the entity is re-homed.
  • Block transit (0.4.0) - ITransitionService.TeleportBlock(source, targetDim, targetLocal) moves a single block plus its BlockEntity state (inventory, attributes, BE-behaviors) between dimensions. Completes the Player / Entity / Block triplet; the destination region is generated on demand and the BE state is round-tripped through ToTreeAttributes / FromTreeAttributes.
  • Transit events (0.4.0) - PlayerEntering (pre-generation, cancellable), PlayerArriving (post-generation, pre-teleport, cancellable), PlayerLeft / PlayerEntered (post-teleport), and EntityChangedDimension (post TeleportEntity for non-player entities).
  • Travel policy per dimension - spawn behavior (SameCoordinates / DimensionSpawn / LastVisited), optional forced game mode, all configured through a fluent builder.
  • Per-dimension inventory (opt-in) - WithSeparateInventory(ManifoldInventory.Hotbar | Backpack | Character) gives a dimension its own player inventory for the chosen categories. Entering swaps to the dimension's set (empty on the first visit), leaving restores the previous one. Stored in player moddata so it survives logout and restarts, with no item loss.
  • Per-dimension metadata (0.4.0) - .WithMetadata(key, value) attaches typed registration-time hints to a dimension; consumers read them via IDimension.Metadata or the typed GetMetadata<T>(key, defaultValue) extension. Supports primitives, string, enum, byte[], and null.
  • Per-dimension streaming budget (0.4.0) - .WithStreamingBudget(maxColumnsPerTick) (range 1..64) caps how many columns the streaming driver may ensure for that dimension per tick. Budgets are independent so a busy dim cannot starve a quiet one.
  • Persistence - dimension manifest, generated-column set, and per-player last-visited positions survive server restarts. Dimensions from uninstalled mods are quarantined (chunks kept, transit refused).
  • Client mirror - the dimension list is replicated to connected clients via IManifoldClient.
  • Zero Harmony patches - built entirely on the public VintagestoryAPI. 0Harmony and protobuf are provided by the game and not patched.
  • Opt-in helpers - PortalBlockBase, DimensionCommandBuilder, BasicVoidWorldgenStrategy to get started with minimal boilerplate.

Quickstart

1. Declare the dependency in modinfo.json

{
  "modid": "mymod",
  "name": "My Mod",
  "version": "1.0.0",
  "dependencies": {
    "game": "1.21.0",
    "manifold": ""
  }
}

2. Register a dimension and a transit command

using Manifold.Api.Helpers;
using Manifold.Api.Server;
using Manifold.Api.Transitions;
using Vintagestory.API.Common;
using Vintagestory.API.MathTools;
using Vintagestory.API.Server;

public sealed class MyModSystem : ModSystem
{
    public override double ExecuteOrder() => 0.5; // run after Manifold (0.05)

    public override void StartServerSide(ICoreServerAPI sapi)
    {
        base.StartServerSide(sapi);

        var manifold = sapi.GetManifoldServer(this); // owner-scoped facade
        if (!manifold.IsHealthy) return;

        manifold.Registry
            .Define(new AssetLocation("mymod", "void"))
            .Persistent()
            .WithWorldgen(new BasicVoidWorldgenStrategy())
            .WithFixedSpawn(new BlockPos(1024, 64, 1024, 0))
            .WithGenerationRadius(5)
            .RegisterStatic();

        new DimensionCommandBuilder()
            .Command("voiddim")
            .TargetDimension(new AssetLocation("mymod", "void"))
            .RequiresPrivilege("chat")
            .DescribedAs("Teleport to the void dimension.")
            .Register(sapi);
    }
}

Compatibility

Requirement Version
Vintage Story 1.21+
.NET 10
Harmony Not required (0Harmony provided by the game)
protobuf-net Not required (bundled with the game)

Documentation


Building from Source

Requires a local Vintage Story install with the VINTAGE_STORY environment variable pointing to the game directory (the folder containing VintagestoryAPI.dll).

# Build all projects
dotnet build -c Release

# Run pure (non-VS-runtime) unit tests
dotnet test tests/Manifold.Pure.Tests

# Run with code coverage
dotnet test tests/Manifold.Pure.Tests --collect:"XPlat Code Coverage"

# Build the documentation site (requires docfx installed globally)
docfx docfx/docfx.json

License

MIT

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.4.1 183 6/12/2026
0.4.0 103 5/29/2026
0.3.1 105 5/23/2026
0.3.0 112 5/22/2026
0.2.0 114 5/21/2026
0.2.0-alpha.1 62 5/21/2026