Mods / BlockPatch Patcher

Tags: #Library
Author: jayu
Side: Server
Created: Sep 23rd 2024 at 7:40 PM
Last modified: Mar 21st at 2:22 PM
Downloads: 140
Follow Unfollow 3

Latest release (for outdated Vintage Story v1.20.x):
blockpatchpatcher_1.1.0.zip  1-click install


Buy Me a Coffee at ko-fi.com

This mod is a library and adds no content to the game

This is a small library to allow to patch blockpatches. With this installed, a content mod can add a file of blockpatch patches at config/blockpatchpatches.json. Patches target all blockpatches, either in worldgen/blockpatches.json or in the worldgen/blockpatches folder.

The allowed format resembles very closely the blockpatch one, as seen in the example patch:

{
"comment": "Patch berries",
"code": "@.*(berry).*",
"op": "replace",
"minTemp": -100,
"maxTemp": 100,
"minRain": 0.0,
"maxRain": 1.0,
"minFertility": 0.0,
"maxFertility": 1.0,
"chance": 2000.0,
"minForest": 0.0,
"maxForest": 1.0,
"minY": 0.0,
"maxY": 1.0,
"quantity": { "dist": "invexp", "avg": 80.0, "var": 30.0 }
}

All numerical values of a block patch can be patched using one of three operation types: "add", "multiply", "replace". The first two will use the existing value dynamically, multiplying it or adding the value in the patch to it. Replace will instead simply replace the value.

Currently supported value types are:

  • Numerical values (int, float)
  • NatFloat (as an example, see "quantity" in the patch above)
  • Strings and lists of strings

Only numerical values support multiplication, string support addition and replacement, while the rest only support replacement. You can make multiple patches targeting the same code to get around this.

More modding tools and libraries

image

VTML Editor

Edit VTML in-game

image

ExtraCode

Adds extra classes and behaviors for content modders

image

Vintage Mod Templates [Code][Content]

Custom templates for code and content mods

Version For Game version Downloads Release date Changelog Download 1-click mod install*
v1.1.0 31 Mar 21st at 2:22 PM Show blockpatchpatcher_1.1.0.zip 1-click install
v1.0.0 109 Sep 23rd 2024 at 7:40 PM Show BlockPatchPatcher.dll 1-click install

0 Comments (oldest first | newest first)

 (edit comment delete)