Skip to content

A lightweight real-time timer datapack for Minecraft

License

Notifications You must be signed in to change notification settings

richardthornton/rtimer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RTimer

A lightweight real-time timer datapack for Minecraft 1.21.8

Time your speedruns, parkour courses, escape rooms, and any other challenge you can dream up! RTimer displays a live countdown in your action bar and broadcasts your final time when you're done.

Features

  • Live Timer Display - See your time tick up in real-time (above your hotbar)
  • Simple Commands - Start, stop, and reset with easy functions
  • Pressure Plate Compatible - Perfect for parkour courses and racing maps
  • Multiplayer Friendly - Only the active player sees the timer, but everyone sees the final result
  • Zero Configuration - Just install and go!

Installation

For Single Player or Server Owners

  1. Download this datapack (or clone this repository)
  2. Locate your world folder:
    • Windows: %appdata%\.minecraft\saves\[YourWorldName]
    • Mac: ~/Library/Application Support/minecraft/saves/[YourWorldName]
    • Linux: ~/.minecraft/saves/[YourWorldName]
    • Server: [YourServerFolder]/[WorldName]
  3. Copy the rtimer folder into the datapacks folder inside your world folder
    • If the datapacks folder doesn't exist, create it
  4. Load the datapack:
    • Start/join your world
    • Run /reload in the chat
    • You should see a confirmation message

Verify Installation

Run /datapack list - you should see [file/rtimer] in green text.

Usage

Basic Commands

Command What it does
/function rtimer:start Start the timer
/function rtimer:end Stop the timer and show your final time
/function rtimer:reset Cancel and reset the timer (no message)
/function rtimer:debug Check if timer is running and see current time

Example: Manual Timing

  1. Stand at your starting point
  2. Run /function rtimer:start
  3. Complete your challenge
  4. Run /function rtimer:end
  5. Your final time will be announced to all players!

Example: Automatic Timing with Pressure Plates

Perfect for parkour courses! Set up command blocks to automatically start/stop the timer:

Start Line Setup

  1. Place a pressure plate where you want to start
  2. Place a command block underneath it (make sure it's impulse mode, not repeating)
  3. Put this command in the command block:
    execute as @p run function rtimer:start
    
  4. Make sure the command block is set to "Always Active"

Finish Line Setup

  1. Place a pressure plate at the finish line
  2. Place a command block underneath it
  3. Put this command in the command block:
    execute as @p run function rtimer:end
    
  4. Make sure the command block is set to "Always Active"

Now when you step on the start plate, your timer begins! When you reach the finish, your time is displayed.

Example: Speedrun Racing

Challenge your friends to beat your time:

  1. Player 1 runs /function rtimer:start
  2. Player 1 completes the challenge and runs /function rtimer:end
  3. Everyone sees Player 1's time
  4. Player 2 runs /function rtimer:start to attempt to beat it
  5. Repeat!

How It Works

  • Timer Display: Shows as M:SS format (e.g., 0:05, 1:23, 12:30)
  • Action Bar Only: The live timer only shows to the player who started it
  • Broadcast Finish: When you finish, the final time is announced to all players
  • One at a Time: Only one timer can run at once (prevents conflicts)
  • Smart Restart Prevention: Can't start a new timer while one is already running

Troubleshooting

Problem: The /function commands don't work

  • Solution: Make sure you have operator permissions (op). Ask your server admin or run /op [YourUsername] in single player

Problem: Timer shows for wrong player

  • Solution: Use /function rtimer:reset to clear the timer, then start fresh

Problem: Timer stuck running

  • Solution: Run /function rtimer:reset to force a reset

Problem: Datapack doesn't load after /reload

  • Solution: Check that the folder structure is correct: datapacks/rtimer/pack.mcmeta should exist
  • Make sure pack.mcmeta is valid JSON

Problem: Commands work but no timer appears

  • Solution: Make sure you started the timer with /function rtimer:start and check that your action bar isn't being used by another datapack

Technical Details

  • Compatible with: Minecraft 1.21.8 (pack format 81)
  • Namespace: rtimer
  • Scoreboards used: rtimer.running, rtimer.ticks
  • Player tags: rtimer.active

FAQ

Q: Can multiple players use the timer at once? A: No, only one timer can run at a time. This prevents conflicts and keeps things simple.

Q: Does this work on servers? A: Yes! Works perfectly on multiplayer servers.

Q: Can I modify this datapack? A: Absolutely! Feel free to customize it for your needs.

Q: Will this slow down my game? A: No, RTimer is extremely lightweight and has no noticeable performance impact.

License

Free to use and modify. Credit appreciated but not required!

Support

Found a bug or have a suggestion? Open an issue on GitHub!


Happy timing! Whether you're speedrunning, building parkour courses, or just timing how long it takes to find diamonds, RTimer has you covered.

About

A lightweight real-time timer datapack for Minecraft

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published