Skip to main content

Custom achievements

You can define your own custom achievements in the mod's config. Achievements with specified requirements for obtaining, a description, and an achievement name are added to the achievements.json file.


Structure

{
"achievements": [
{
"id": "test_achievment",
"name": "First Night",
"tooltip": "You survived the first night!",
"conditions": {
"deathsMax": 999
}
}
]
}
info

The id determines whether an achievement has already been earned. Multiple achievements can share the same id, but they will be counted as one — if a player has earned any achievement with that id, all others sharing it will also be marked as earned.


Conditions

ParameterDescription
deathsEq / deathsMin / deathsMaxNumber of deaths
mobsKilledEq / mobsKilledMin / mobsKilledMaxMobs killed
blocksDestroyedEq / blocksDestroyedMin / blocksDestroyedMaxBlocks destroyed
distanceWalkedEq / distanceWalkedMin / distanceWalkedMaxDistance walked
jumpsEq / jumpsMin / jumpsMaxNumber of jumps
damageDealtEq / damageDealtMin / damageDealtMaxDamage dealt
  • Eq — exactly the value required
  • Min — minimum value required
  • Max — maximum value allowed

Example

{
"achievements": [
{
"id": "test_achievment",
"name": "First Night",
"tooltip": "You survived the first night!",
"conditions": {
"deathsMax": 999
}
}
]
}