Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/yzl210/harvestleveltweaker

Harvest Level Tweaker for Minecraft
https://github.com/yzl210/harvestleveltweaker

Last synced: 7 days ago
JSON representation

Harvest Level Tweaker for Minecraft

Awesome Lists containing this project

README

        

[![][1]][3] [![][2]][3] [![][4]][5] [![][6]][7] [![][8]][9] [![][10]][11]

# Harvest Level Tweaker
A minecraft forge mod that allows modpack makers to add new harvest levels with custom names.

Currently supports:
* [The One Probe](https://www.curseforge.com/minecraft/mc-mods/the-one-probe)
* [Jade](https://www.curseforge.com/minecraft/mc-mods/jade)
* [WTHIT](https://www.curseforge.com/minecraft/mc-mods/wthit-forge)
* [Tinker's Construct](https://www.curseforge.com/minecraft/mc-mods/tinkers-construct)

## Table of Contents

* [Harvest Level Tweaker](#harvest-level-tweaker)
* [Table of Contents](#table-of-contents)
* [Add New Harvest Levels](#add-new-harvest-levels)
* [Example: `cobalt.json`:](#example-cobaltjson)
* [Example: `copper.json`:](#example-copperjson)
* [Override Item Harvest Level and Harvest Type](#override-item-harvest-level-and-harvest-type)
* [Set Block Harvest Level](#set-block-harvest-level)
* [Localization and custom vanilla level names](#localization-and-custom-vanilla-level-names)
* [Client Config](#client-config)
* [Commands](#commands)
* [Set Tinker's Construct Material Level (1.18 Only)](#set-tinkers-construct-material-level-118-only)

## Add New Harvest Levels
Go to folder `config/hltweaker/levels`

Create a json file with level id as the name.

For example: `cobalt.json` will create a new level with id `cobalt`

Json Format:

```
{
"level": ,
"better": ["", ...],
"worse": ["", ...],
"color": "",
"icons": {
"": "",
...
}
}
```

| Field | Type | Required | Description | Example |
|----------|--------------|---------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------|
| `level` | Integer | Yes | Order/tier of the custom level. No duplicates with other levels. If lower than `5`, `better` or `worse` field is required and duplicate is allowed | `5` |
| `better` | String Array | Required if `level` is lower than `5` and `worse` is not set | Levels that are better than this level, works only when `level` is lower than `5` | `["minecraft:netherite"]` |
| `worse` | String Array | Required if `level` is lower than `5` and `better` is not set | Levels that are worse than this level, works only when `level` is lower than `5` | `["minecraft:diamond"]` |
| `color` | String | No (Default: `white`) | Color of the harvest level in hex format (prefix `#`) or color name | `"#0047ab"` or `"blue"` |
| `icons` | Json Object | No | Icons for the harvest level in `"": ""` format | `{"minecraft:mineable/pickaxe": "minecraft:stone_pickaxe"}` |

### Example: `cobalt.json`:
```json
{
"level": 5,
"color": "#0047ab",
"icons": {
"minecraft:mineable/pickaxe": "kubejs:cobalt_pickaxe",
"minecraft:mineable/axe": "kubejs:cobalt_axe",
"minecraft:mineable/shovel": "kubejs:cobalt_shovel",
"minecraft:mineable/hoe": "kubejs:cobalt_hoe"
}
}
```
This will create a new level with id `cobalt` and level 5.

Or it can be as simple as:
```json
{
"level": 5
}
```

### Example: `copper.json`:
```json
{
"level": 1,
"better": ["minecraft:iron"],
"worse": ["minecraft:stone"]
}
```
This will create a new level with id `copper` between tier stone and iron (better than stone, worse than iron)

## Override Item Harvest Level and Harvest Type
Find the file `config/hltweaker/item_harvest_level_overrides.json`

Json Format:

```json
{
"": {
"": ""
}
}
```
* ``: Item id. Example: `minecraft:stone`

* ``: The mineable tag (required tool type). Example: `minecraft:mineable/pickaxe`

* ``: Harvest level id (with namespace if it's not from this mod). Example: `cobalt` or `minecraft:wood`

Example `item_harvest_level_overrides.json`:
```json
{
"minecraft:golden_pickaxe": {
"minecraft:mineable/pickaxe": "cobalt",
"minecraft:mineable/axe": "minecraft:netherite"
},
"minecraft:netherite_pickaxe": {
"minecraft:mineable/pickaxe": "minecraft:wood"
}
}
```
This will remove all existing harvest types and level of stone pickaxe and netherite pickaxe.

Then set the harvest level of stone pickaxe to cobalt as a pickaxe and netherite when used as an axe.

And set the harvest level of netherite pickaxe to wood when used as a pickaxe.

## Set Block Harvest Level
Create a datapack and add the blocks to tag:

* Harvest Level Tweaker Levels: `hltweaker:needs__tool`

* Vanilla levels:

* `stone`, `iron`, `diamond`: `minecraft:needs__tool`

* `wood`, `gold`, `netherite`: `forge:needs__tool`

Example `data/hltweaker/tags/blocks/needs_cobalt_tool.json`:
```json
{
"values": [
"#minecraft:stone",
"kubejs:cobalt_block"
]
}
```
This will set all blocks under `minecraft:stone` tag and cobalt block to require cobalt level tools.

## Localization and custom vanilla level names
* Translation key for custom harvest level is `text.hltweaker.level.`

Example: `"text.hltweaker.level.cobalt": "Cobalt"`

* Translation key for tool type is `text.hltweaker.tool..`

Example: `"text.hltweaker.tool.minecraft.pickaxe": "Pickaxe"`, `"text.hltweaker.tool.paxelmod.paxel": "Paxel"`

* Translation key for vanilla harvest level is `text.hltweaker.level.minecraft.`

Example: `"text.hltweaker.level.minecraft.wood": "This is Wood Level"`

## Client Config
Client config is located at `config/hltweaker/client.toml`

You can change the color of vanilla harvest levels in the config.

More details can be found in the config file.

## Commands
`/hltweaker levels` - Show vanilla and Harvest Level Tweaker levels

`/hltweaker levels all` - Show all harvest levels that are registered in the game

`/hltweaker overrides` - Show item harvest level overrides

## Set Tinker's Construct Material Level (1.18 Only)
In your datapack for tinker's construct, set the harvest level of the material to `hltweaker:`

[1]: http://cf.way2muchnoise.eu/full_833035_downloads.svg
[2]: http://cf.way2muchnoise.eu/versions/833035_all.svg
[3]: https://www.curseforge.com/minecraft/mc-mods/harvest-level-tweaker
[4]: https://img.shields.io/discord/809053891466887169?label=support&logo=discord
[5]: https://discord.gg/FFAdyuqNvm
[6]: https://img.shields.io/github/license/yzl210/HarvestLevelTweaker?logo=github
[7]: https://github.com/yzl210/HarvestLevelTweaker/blob/1.18/LICENSE
[8]: https://img.shields.io/github/issues/yzl210/HarvestLevelTweaker?logo=github
[9]: https://github.com/yzl210/HarvestLevelTweaker/issues
[10]: https://img.shields.io/github/stars/yzl210/HarvestLevelTweaker?logo=github
[11]: https://github.com/yzl210/HarvestLevelTweaker/stargazers