Mods are a feature of the full game, not the demo. They open when the full game launches, and details may change before then.

Crops

Add a plant players can farm: the seed item is made for you, and the grown crop gives whatever you choose.

The crops table lets players grow something new on a farm plot. You say what the crop is called, what it gives when harvested, how many, how long it takes to grow, and its colours at three stages. The seed becomes an item automatically, with the id <crop id>_seed.

In the editor#

Open the Crops tab under Food & gathering in the left column. Press Add to start a new crop, or Copy from game to start from a base game crop.

FieldWhat it does
Crop nameThe name shown in fields and the codex (Other languages underneath).
Seed nameThe seed name in the bag. Leave it empty to use the crop name.
Harvest itemWhat you get when you harvest. Pick a base game item or one from this mod.
Harvest amountHow many you get in one harvest. Left is the minimum, right is the maximum.
Ripening timeHow many in-game hours it takes to ripen after planting.
Crop colorsThree swatches in order: leaves, seed, ripe fruit.
Plant heightHigher numbers make the plant grow taller.

This tab has no preview. The top-bar Test reloads the game with your mod and drops you in a flat test field, which is a quick way to confirm it loads without problems. The test field has no villages, water or farm plots, so to see this in action, turn the mod on under My Mods and play in a world. The seed item is made for you.

Advanced: writing the JSON by hand#

Below is the same content as it looks in the file. The editor saves exactly this format. You can also press Open folder at the top of the editor and edit the file in an outside text editor; when you save, the editor picks up the change. Fields the form does not show are kept as they are. Where the file goes and how it is listed: Mod folder and mod.json.

The table is one JSON file; put its path under content.crops in mod.json.

Smallest working example#

A frost berry bush that grows in 36 game hours and gives 2 to 4 base game Healing Herb per harvest:

data/crops.json
[
  {
    "id": "frost_berry_bush",
    "name": "Frost berry bush",
    "names": { "zh-TW": "霜莓叢" },
    "seedName": "Frost berry seeds",
    "seedNames": { "zh-TW": "霜莓種子" },
    "product": "healing_herb",
    "yield": [2, 4],
    "growHours": 36,
    "colors": ["#7bc043", "#5fa83c", "#9fd6e8"],
    "height": 0.6
  }
]

Fields#

FieldRequired?What it meansAllowed values
idYesThe crop’s name inside your mod. The seed id becomes <id>_seedStarts with a lowercase letter or digit; only lowercase letters, digits and underscores; up to 48 characters
name, namesAt least oneCrop nameUp to 32 characters each
seedName, seedNamesNoName of the seed item; the crop name is used if missingUp to 32 characters each
productYesThe item you get when harvestingAn item id: base game, your own (item, fish or dish) or @modid/name
yieldYesHow many per harvest, [fewest, most]Two whole numbers, each 1 to 12; the second cannot be smaller than the first
growHoursNoGame hours needed to grow12 to 168. Default 24
colorsYesThree colours: sprout, growing, ripeExactly three "#rrggbb" values
heightNoHow tall it grows0.2 to 1.5. Default 0.6

How it points at other things#

  • product can be a base game item (healing_herb), a local id from your items table, your own fish or dish, or @modid/name from another mod.
  • The seed is an item made for you, named by your seedName. To let enemies drop seeds, write "item": "frost_berry_bush_seed" in Loot.
  • To use your own seed or crop as a material in a recipe you need two mods, because recipes load before crops within one mod.

Common mistakes#

  • Forgetting product, yield or colors.
  • colors that is not exactly three colours.
  • Writing yield as one number. It has to look like [2, 4].
  • growHours below 12 or above 168.
  • A misspelled product. The game says there is no item called "something".
  • Items: the harvest is often an item of your own.
  • Dishes: cook with what you harvest.
  • Loot: let enemies drop seeds.
  • The mod editor: build this kind of content with forms and test it in the game.