Carpet Mod Documentation
website·Indexed 31 days ago
https://carpet.tis.worldDocumentation for Carpet TIS Addition, a mod providing technical tools and features for Minecraft. Includes guides on configuration rules, server and world state inspection commands, loggers, and the Scarpet scripting language for versions 1.16.4+.
What's inside Carpet
- Carpet TIS Addition is a mod for Technical Minecraft that provides a suite of tools including carpet rules, loggers, and commands. It is designed to maintain vanilla game behavior unless the user explicitly configures changes, ensuring the game remains vanilla by default.
Inspect server and world state using /info
The/infocommand provides real-time data about the game world and server counters.# Show the ticking order of current dimensions /info world ticking_order # Show world weather properties and a weather forecast /info world weather # Show the current server entity ID counter (net.minecraft.world.entity.Entity#ENTITY_COUNTER) /info server entity_id_counter # Show the current server tick counter (net.minecraft.server.MinecraftServer#getTickCount) /info server server_tick_counterRemove placement requirements for Wither Roses
Allows Wither Roses to be planted on any surface by removing all placement requirements. This is useful for creating update-suppressed wither rose setups for wither skeleton farms.# Default: false # Options: true, falseTrack entity lifetimes and spawn/removal reasons
The
/lifetimetracker monitors how long entities (mobs, items, XP orbs, vehicles) exist and why they were spawned or removed. This is primarily used for debugging mob farms.Key Concepts:
- Lifetime Definition: The number of game ticks an entity counts towards the mobcap between spawning and removal.
- Realtime Tracking: Append
realtimeto the command to get results based on real-world time instead of in-game ticks. - Mobcap Rule: By default, only entities counting towards the mobcap are tracked. This behavior can be modified via the
lifeTimeTrackerConsidersMobcaprule.
# Start, stop, or restart the lifetime tracker /lifetime tracking [<start|stop|restart>] # Show detailed statistics for a specific entity type (e.g., creeper) /lifetime creeper # Show only removal statistics for a specific entity type /lifetime creeper removal # Show only spawning statistics for a specific entity type /lifetime creeper spawningConfigure movement logger permissions
TheloggerMovementrule defines the switch or permission requirement for the movement logger. Supported values includetrue,false,ops, or permission levels (0-4)./carpet loggerMovement opsRemove permission requirements for F3 + I NBT queries
EnabledebugNbtQueryNoPermissionto remove the requirement for permission level 2 when performing the client's F3 + I debug NBT request. This requires the Carpet TIS Addition to be installed on the client.# Set to true to remove permission requirement debugNbtQueryNoPermission trueTrack block events using Scarpet
Scarpet allows developers to register specific block positions to be tracked for events. When a tracked block triggers an event, the__on_microtiming_eventfunction is called. This functionality requires the Carpet rulemicroTimingto be set totrue.Log redstone micro timings
The
/log microTiming <type>command logs micro timings of redstone components. Requirements: The chunk ticket must be at least lazy-processing (level 32) and/carpet microTiming truemust be enabled.Options:
all: Log all events.merged: Log all events and merged continuous identical events.unique: Log the first unique event per gametick.
/carpet microTiming true /log microTiming mergedUse the microTiming logger for redstone debugging
The
microTimingrule enables the MicroTiming logger, which logs and displays redstone component actions, block updates, and stack traces.- Activation: Use
/log microTimingto start logging. - Dye Markers: Use the
microTimingDyeMarkerrule to mark blocks for logging by right-clicking with a dye item. Renamed dyes create named markers. Use/carpet microTimingDyeMarker clearto remove all markers. - Targeting: Use
microTimingTargetto define what is logged. Themarker_onlyoption (default) logs only events labeled with dye markers. Other options likelabelled,in_range, andallare deprecated. - Tick Division: Use
microTimingTickDivisionto choose how game ticks are divided:world_timer(Overworld timer increment) orplayer_action(beginning of player action).
# Enable microTiming /carpet microTiming true # Start logging /log microTiming # Set target to marker only /carpet microTimingTarget marker_only- Activation: Use
Understand Carpet development branching strategy
Carpet uses a specific branching strategy to manage feature development and releases across different Minecraft versions. The project utilizes a preprocessor to maintain support for multiple Minecraft versions within a single branch. The current main development Minecraft version is 1.15.2 (tracked by
versions/mainProject).Branch purposes:
master: Contains stable release versions; this is the preferred target for Pull Requests. Direct commits to master are typically reserved for documentation updates.dev: Used for active feature development.future: Used for snapshot migrations.
Reintroduce dust-trapdoor instant update looper (MC >= 1.20)
For Minecraft 1.20 and above, enabledustTrapdoorReintroducedto restore pre-1.20 behavior. This does two things: 1) Makes opened trapdoors unable to redirect redstone dust, and 2) Makes redstone dust ignore state updates from below (pre-1.20.3 behavior).dustTrapdoorReintroduced trueConfigure lifetime tracker mobcap strategy
The
lifeTimeTrackerConsidersMobcaprule determines how the lifetime tracker handles mobs that do not count towards the mobcap:true: Does not track mobs that don't count towards mobcap and treats them as removed as soon as they stop affecting the mobcap (e.g., when picking up items). Recommended for mob farm design.false: Tracks all possible mobs and only marks them as removed when they are actually removed. Recommended for raid testing or non-mobfarm scenarios.
/carpet lifeTimeTrackerConsidersMobcap false