▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
Playtime

Playtime

Standalone Paper playtime tracking with daily, monthly, all-time, and event based playtime support.

Оцените первым
107
2

Playtime

A lightweight Paper plugin that tracks player playtime without needing Essentials, Minecraft statistics, or another playtime plugin.


What does it track?

It tracks several types of playtime separately:

TypeDescription
TodayPlaytime earned during the current day
This MonthPlaytime earned during the current month
All-TimeTotal playtime tracked by hPlaytime
EventsTemporary playtime contests with their own logs

This plugin starts tracking from the moment it is installed. It does not import Essentials data or use Minecraft statistics.


Commands

User

CommandPermissionDescription
/playtimehplaytime.useShows your own playtime
/pthplaytime.useAlias for /playtime
/playtime <player>hplaytime.othersShows another player's playtime
/playtime tophplaytime.useShows the top 10 all-time playtime leaderboard
/playtime topdayhplaytime.useShows the top 10 daily playtime leaderboard
/playtime topmonthhplaytime.useShows the top 10 monthly playtime leaderboard

Admin

CommandPermissionDescription
/hplaytime reloadhplaytime.reloadReloads config, language, storage settings, AFK settings, and formats
/hplaytime reset <player>hplaytime.resetResets one player' main playtime
/hplaytime resetallhplaytime.resetallResets all players' main playtime

Events

CommandPermissionDescription
/playtime event create <name> <duration>hplaytime.event.createCreates a playtime event
/playtime start <name>hplaytime.event.startStarts an event fresh
/playtime event end <name>hplaytime.event.endEnds an event and writes a log
/playtime event delete <name>hplaytime.event.deleteDeletes active event tracking files
/event listhplaytime.event.listLists events

Example:

/playtime event create weekend 24h
/playtime start weekend

Supported duration examples:

24h
7d
1h30m
45m
Permissions
PermissionDefaultDescription
hplaytime.useEveryoneUse /playtime
hplaytime.othersOPCheck another player's playtime
hplaytime.reloadOPReload hPlaytime
hplaytime.resetOPReset one player's main playtime
hplaytime.resetallOPReset all main playtime
hplaytime.event.createOPCreate playtime events
hplaytime.event.startOPStart playtime events
hplaytime.event.endOPEnd playtime events
hplaytime.event.deleteOPDelete event tracking files
hplaytime.event.listOPList events

Features

  • Standalone playtime tracking
  • Daily, monthly, and all-time totals
  • Temporary playtime events
  • Local YAML storage by default
  • Optional MySQL storage
  • Built-in AFK protection
  • AFK worlds where playtime does not count
  • Optional last-seen display
  • Configurable date, timezone, and time formatting
  • Fully editable lang.yml
  • Player and global reset commands
  • Event winner broadcasts
  • Permanent event result logs
  • Simple text commands, no GUI required

Requirements

RequirementVersion
Server SoftwarePaper 1.21.10+
JavaJava 21+

MySQL is optional. hPlaytime uses local YAML storage by default.


Installation

  1. Download the latest jar.
  2. Place it inside your server’s plugins folder.
  3. Restart your server.
  4. Edit the generated files in plugins/hPlaytime/.
  5. Run /hplaytime reload after making changes.

Plugin Files

hPlaytime creates its own folder inside your server’s plugins directory.

PathPurpose
config.ymlStorage, formatting, AFK, AFK worlds, and save settings
lang.ymlEditable plugin messages
data/Local player playtime files
events/Active event tracking files
event-logs/Saved event result logs
Storage Settings

hPlaytime supports local YAML storage and MySQL.

Local storage is enabled by default:

storage:
  type: local

Local player data is saved here:

plugins/hPlaytime/data/<uuid>.yml

This is the simplest option and is recommended for single-server setups.

To use MySQL:

storage:
  type: mysql

  mysql:
    host: localhost
    port: 3306
    database: minecraft
    username: root
    password: ""
    use-ssl: false
    table-prefix: hplaytime_

hPlaytime creates the required MySQL tables automatically.

Main playtime can use MySQL, but event tracking is currently local-file based.

AFK Protection

hPlaytime includes its own AFK system. It does not rely on Essentials AFK.

afk:
  enabled: true
  timeout-seconds: 300

  worlds:
    - afk

When a player is inactive, new playtime stops counting until they move, interact, or run a command.

Players in configured AFK worlds do not gain:

  • Main playtime
  • Event playtime
Date, Time, and Last Seen Formatting

Date keys and timezone are configurable in config.yml.

date-format:
  timezone: system
  daily-pattern: yyyy-MM-dd
  monthly-pattern: yyyy-MM

Use timezone: system for the server machine timezone, or use a Java timezone ID:

timezone: America/Chicago

Time output can also be customized:

time-format:
  style: compact
  show-seconds: true
  zero: 0s

Compact output example:

1d 4h 22m

Long output example:

1 day 4 hours 22 minutes

Last-seen output can be enabled, disabled, or reformatted:

last-seen:
  enabled: true
  pattern: yyyy-MM-dd HH:mm:ss z
Language File

All messages are editable in:

plugins/hPlaytime/lang.yml

Messages support & color codes.

Common placeholders:

PlaceholderDescription
%prefix%Configured prefix from lang.yml
%player%Player name
%today%Today's playtime
%month%This month's playtime
%alltime%All-time playtime
%lastseen%Last-seen status
%event%Event name
%duration%Event duration
%time%Formatted time
%events%Event list

After editing lang.yml, run:

/hplaytime reload

Important Notes

  • hPlaytime starts tracking after it is installed.
  • It does not import Essentials playtime.
  • It does not use Minecraft statistics for all-time totals.
  • Reset commands affect main playtime only.
  • Reset commands do not delete event logs.
  • AFK timeout applies to main playtime and event playtime.
  • AFK worlds apply to main playtime and event playtime.
  • Event logs are kept even after an event is deleted.
  • Event tracking is currently local-file based, even when MySQL is enabled.

Support

If you find a bug or have a suggestion, please open an issue on GitHub with your server version, plugin version, and any relevant console errors.

The plugin is actively maintained, but new features are added carefully to keep it lightweight.


Authors

  • HBOJ

Sponsored By

  • AsteroidMC

License

  • ARR License

Часто задаваемые вопросы

Совместимость

Minecraft: Java Edition

26.1.x1.21.x1.20.x1.19.x

Поддерживаемые окружения

Сервер

Ссылки


Детали

Лицензия:
Опубликован:1 месяц назад
Обновлён:3 недели назад
Главная