Skip to content

de_de API and Tags

Rifa edited this page Sep 1, 2026 · 1 revision

🏷️ API & Data-Driven Tag Extension

🌐 Languages: 🇺🇸 English | 🇨🇳 简体中文 | 🇭🇰 繁體中文 | 🇷🇺 Русский | 🇪🇸 Español | 🇩🇪 Deutsch | 🇫🇷 Français | 🇧🇷 Português | 🇯🇵 日本語 | 🇮🇩 Bahasa Indonesia | 🇰🇷 한국어

📌 Repository Source Disclaimer: The documentation in this Wiki reflects the current source code state in the repository, which may include recent unreleased commits or developmental features ahead of public release builds on CurseForge and Modrinth.


📦 Data-Driven Tags

Datapack creators and addon mod developers can customize True Sleep's machine and entity behaviors without writing Java code.


1. Accelerated Machines Tag (#truesleep:accelerated_machines)

  • Tag File: data/truesleep/tags/block_entity_type/accelerated_machines.json
  • Purpose: Declares block entity types that receive multi-tick acceleration during sleep.
{
  "replace": false,
  "values": [
    "minecraft:furnace",
    "minecraft:blast_furnace",
    "minecraft:smoker",
    "minecraft:brewing_stand",
    "minecraft:campfire",
    "minecraft:soul_campfire",
    "minecraft:beehive",
    "mymod:custom_smelter",
    "mymod:alloy_forge"
  ]
}

2. Worker Mobs Tag (#truesleep:worker_mobs)

  • Tag File: data/truesleep/tags/entity_type/worker_mobs.json
  • Purpose: Declares entity types governed by the truesleep:freeze_workers GameRule instead of global freeze_mobs.
{
  "replace": false,
  "values": [
    "minecraft:allay",
    "minecraft:villager",
    "mymod:goblin_trader"
  ]
}

💻 Developer Java Hooks

1. TimeWarpManager Static Accessor

import net.vanillaoutsider.truesleep.logic.TimeWarpManager;

// Check if world time is currently accelerating
boolean isWarping = TimeWarpManager.get().isWarping();

// Get current time stride multiplier
long stride = TimeWarpManager.get().getStride();

2. Potion Effect Aging Interface

import net.vanillaoutsider.truesleep.MobEffectInstanceExtensions;

MobEffectInstance effect = mob.getEffect(MobEffects.REGENERATION);
if (effect != null) {
    ((MobEffectInstanceExtensions) effect).truesleep$ageEffect(skipTicks);
}

🧭 Navigation

🇺🇸 English


🇨🇳 简体中文 (Simplified Chinese)
🇭🇰 繁體中文 (Traditional Chinese)
🇷🇺 Русский (Russian)
🇪🇸 Español (Spanish)
🇩🇪 Deutsch (German)
🇫🇷 Français (French)
🇧🇷 Português do Brasil (Portuguese)
🇯🇵 日本語 (Japanese)
🇮🇩 Bahasa Indonesia (Indonesian)
🇰🇷 한국어 (Korean)

Clone this wiki locally