playtime reward
1.0.0A powerful and flexible playtime reward plugin that automatically rewards your players for their time spent on your server!
A flexible playtime reward plugin that automatically rewards your players for their time spent on your server!
🌟 Features
Core Features
Time-Based Rewards - Automatically reward players based on their playtime
Fully Configurable - Customize everything: items, amounts, intervals, messages
Smart Storage System - Stores rewards when inventory is full for later collection
Player Tracking - Tracks total playtime, session time, and reward history
Rich Visual Feedback - Custom messages, sounds, particles, and actionbar countdowns
Admin Tools - Comprehensive commands to manage and monitor player rewards
Performance Optimized - Efficient tracking with auto-save system
Permission-Based - Control who receives rewards and who has admin access
Advanced Features
- Inventory Full Protection - Never lose rewards! They're stored automatically
- Custom Item Support - Any Minecraft item with custom names and lore
- Actionbar Countdown - Players see countdown in their actionbar
- Welcome Messages - Greet players with playtime information on join
- AFK Prevention - Minimum online time requirement before earning rewards
- Maximum Storage Limit - Configurable limit to prevent abuse
- Data Persistence - All data saved automatically and persists across restarts
- Tab Completion - All commands support tab completion for better UX
📥 Installation
Prerequisites
- Paper or Spigot server running Minecraft 1.21+
- Java 17 or higher installed on your server
Steps
- Download the latest
PlaytimeReward-1.0.0.jarfile - Stop your Minecraft server
- Place the JAR file in your server's
pluginsfolder - Start your server
- The plugin will create a
PlaytimeRewardfolder with default configuration - Configure the plugin by editing
plugins/PlaytimeReward/config.yml - Reload the plugin with
/ptr reloador restart the server
Verification
After installation, verify the plugin is working:
> plugins
[10:00:00 INFO]: Plugins (1): PlaytimeReward
⚙️ Configuration
The plugin generates a config.yml file in plugins/PlaytimeReward/ with extensive customization options.
Basic Configuration
Reward Settings
reward:
# Time in seconds between each reward
interval: 300 # 5 minutes (300 seconds)
# Item to give as reward (use Minecraft material names)
# Examples: DIAMOND, EMERALD, GOLD_INGOT, IRON_INGOT, NETHERITE_INGOT
item: DIAMOND
# Amount of items to give per reward
amount: 1
# Custom display name for the reward item (optional)
# Use & for color codes (&a = green, &b = blue, etc.)
display-name: "&b&lPlaytime Reward"
# Lore for the reward item (optional)
lore:
- "&7Thank you for playing!"
- "&7Earned from playtime"
Message Customization
All messages support Minecraft color codes (& format):
messages:
# Message when player receives reward
reward-received: "&a&l✦ &aYou received &e{amount}x {item} &afor playing!"
# Message when inventory is full
inventory-full: "&c&l⚠ &cYour inventory is full! &7Reward saved. Use &e/ptr claim &7to claim it later."
# Message when claiming stored rewards
rewards-claimed: "&a&l✦ &aYou claimed &e{amount} &astored reward(s)!"
# Message when no rewards to claim
no-rewards: "&c&l✦ &cYou don't have any stored rewards!"
# Message for next reward countdown
next-reward: "&b&l⏰ &bNext reward in: &e{time}"
# Welcome message on join
welcome: "&a&l✦ &aWelcome back! You'll earn rewards every &e{interval} &aof playtime!"
Feature Toggles
features:
# Send welcome message when player joins
welcome-message: true
# Show actionbar with time until next reward
actionbar-countdown: true
# Play sound when reward is received
reward-sound: true
sound: ENTITY_PLAYER_LEVELUP
# Enable particle effects when giving reward
reward-particles: true
particle: TOTEM_OF_UNDYING
Advanced Settings
advanced:
# Auto-save player data (in minutes)
auto-save-interval: 5
# Reset playtime on server restart (not recommended)
reset-on-restart: false
# Maximum stored rewards per player (prevents abuse)
max-stored-rewards: 100
# Minimum online time to start earning (in seconds)
# Prevents AFK farmers at spawn
minimum-online-time: 60
Configuration Examples
Example 1: Give 3 Emeralds every 10 minutes
reward:
interval: 600
item: EMERALD
amount: 3
Example 2: Give 1 Netherite Ingot every hour
reward:
interval: 3600
item: NETHERITE_INGOT
amount: 1
display-name: "&6&l⭐ &ePremium Hour Reward &6&l⭐"
lore:
- "&7You've played for 1 hour!"
- "&eThank you for your dedication"
Example 3: Quick rewards for testing (30 seconds)
reward:
interval: 30
item: DIAMOND
amount: 5
Available Items
You can use any valid Minecraft material name. Common examples:
DIAMOND,EMERALD,GOLD_INGOT,IRON_INGOTNETHERITE_INGOT,ANCIENT_DEBRISENCHANTED_GOLDEN_APPLE,GOLDEN_APPLEELYTRA,TOTEM_OF_UNDYINGEXPERIENCE_BOTTLE,BEACON
See Spigot Material List for all available materials.
📜 Commands
All commands use the /ptr prefix (alias for /playtimereward).
Player Commands
| Command | Description | Permission |
|---|---|---|
/ptr info | Displays your playtime statistics | None (default) |
/ptr claim | Claims your stored rewards | None (default) |
Admin Commands
| Command | Description | Permission |
|---|---|---|
/ptr reload | Reloads the configuration | PlaytimeReward.admin |
/ptr check <player> | Views a player's statistics | PlaytimeReward.admin |
/ptr reset <player> | Resets a player's playtime data | PlaytimeReward.admin |
/ptr save | Manually saves all player data | PlaytimeReward.admin |
Command Details
/ptr info
Shows your personal playtime information:
- Total playtime
- Current session time
- Time until next reward
- Number of stored rewards (if any)
Example Output:
=== Your Playtime Info ===
Total Playtime: 2 hours 45 minutes 30 seconds
Current Session: 15 minutes 10 seconds
Next Reward: 4 minutes 30 seconds
Stored Rewards: 3 (Use /ptr claim)
/ptr claim
Claims all stored rewards that were saved due to full inventory.
Example Output:
✦ You claimed 5 stored reward(s)!
/ptr reload
Reloads the plugin configuration without restarting the server.
Use Case: After editing config.yml
/ptr check <player>
Views detailed statistics for any player.
Example Output:
=== Steve's Playtime Data ===
Total Playtime: 2 hours 45 minutes 30 seconds
Time Since Last Reward: 4 minutes 20 seconds
Stored Rewards: 3
Current Session: 15 minutes 10 seconds
/ptr reset <player>
WARNING: Permanently resets all playtime data for a player. Cannot be undone!
/ptr save
Forces an immediate save of all player data to disk.
Use Case: Before server maintenance or manual file edits
🔐 Permissions
| Permission | Description | Default |
|---|---|---|
PlaytimeReward.receive | Allows receiving playtime rewards | true (everyone) |
PlaytimeReward.admin | Allows using admin commands | op (operators only) |
Permission Examples
Give admin permission to a moderator:
# Using LuckPerms
/lp user Moderator permission set PlaytimeReward.admin true
Remove receive permission from a player:
# Using LuckPerms
/lp user Player permission set PlaytimeReward.receive false
Group permissions (in your permissions plugin):
groups:
default:
permissions:
- PlaytimeReward.receive
moderator:
permissions:
- PlaytimeReward.admin
📖 Usage Guide
For Players
Joining the Server
When you join, you'll see a welcome message (if enabled):
✦ Welcome back! You'll earn rewards every 5 minutes of playtime!
Earning Rewards
Simply play on the server! Every configured interval (default 5 minutes), you'll automatically receive a reward:
✦ You received 1x diamond for playing!
[Sound and particle effects play]
Full Inventory
If your inventory is full, the reward is automatically stored:
⚠ Your inventory is full! Reward saved. Use /ptr claim to claim it later.
Checking Your Progress
Use /ptr info to see:
- How long until your next reward
- Your total playtime
- Any stored rewards waiting
Claiming Stored Rewards
When you have inventory space, use /ptr claim to collect all stored rewards at once.
For Admins
Monitoring Players
Check any player's statistics:
/ptr check PlayerName
Testing the System
Give yourself a test reward:
/ptr check YourName # Check your current data
# (Wait for automatic reward or adjust config for testing)
Changing Configuration
- Edit
plugins/PlaytimeReward/config.yml - Run
/ptr reload - Changes apply immediately
Managing Player Data
- Check data:
/ptr check <player> - Reset player:
/ptr reset <player>(use cautiously) - Force save:
/ptr save(before maintenance)
💾 Data Storage
Files Created
plugins/
└── PlaytimeReward/
├── config.yml # Plugin configuration
└── playerdata.yml # Player playtime data
Player Data Structure
The playerdata.yml file stores:
- UUID-based player identification
- Total playtime (in seconds)
- Last reward timestamp
- Stored (unclaimed) rewards
- Session information
Data Persistence
Player data is automatically saved:
- When a player disconnects
- Every 5 minutes (configurable)
- When the server stops
- When
/ptr saveis executed
🔧 Troubleshooting
Common Issues
Issue: Players not receiving rewards
Solutions:
- Check player has
PlaytimeReward.receivepermission - Verify config interval setting:
/ptr reload - Check player data:
/ptr check <player> - Ensure
minimum-online-timerequirement is met
Issue: Invalid material error in console
Solutions:
- Check your
reward.itemsetting in config.yml - Use valid Minecraft 1.21+ material names
- See Material List
- Reload config:
/ptr reload
Issue: Commands not working
Solutions:
- Verify permissions are set correctly
- Check console for errors
- Ensure player is online (for check/reset commands)
- Try using the full command:
/playtimerewardinstead of/ptr
Issue: Data not saving
Solutions:
- Check file permissions on server
- Look for errors in console
- Manually trigger save:
/ptr save - Verify plugin folder exists and is writable
Issue: Rewards given too frequently/slowly
Solutions:
- Check
reward.intervalin config.yml (value is in seconds) - Use
/ptr reloadafter changing - Example: 300 = 5 minutes, 600 = 10 minutes, 3600 = 1 hour
Getting Help
If you need additional support:
- Check console logs for error messages
- Verify your configuration is valid YAML syntax
- Join our Discord server: https://discord.gg/cybycQ9wGp
📊 Performance
Resource Usage
- Memory: Minimal (<5MB for typical server)
- CPU: Very light (single async task every second)
- Disk: Small data file (YAML format)
- Network: No network operations
Optimization Tips
- Adjust
auto-save-intervalbased on player count - Set appropriate
max-stored-rewardslimit - Use
minimum-online-timeto reduce unnecessary checks - Consider longer intervals for high-population servers
Tested Performance
Works efficiently with 100+ concurrent players
No noticeable TPS impact
Fast data saving (<100ms)
Minimal memory footprint
🚀 Roadmap
Potential features for future versions:
- Multiple reward tiers based on total playtime
- Discord webhook integration for milestones
- MySQL/PostgreSQL database support
- PlaceholderAPI integration
- Per-world reward configuration
- Reward multipliers for events/boosters
- GUI for viewing statistics
- Reward history tracking
🤝 Support
Bug Reports
If you find a bug, please report it with:
- Plugin version
- Server software and version
- Steps to reproduce
- Console errors (if any)
Feature Requests
Have an idea? Share it with details about:
- What you want to achieve
- How it would benefit users
- Example use cases
Discord Community
Join our Discord server for support, updates, and community discussion:
https://discord.gg/cybycQ9wGp
📜 License
This plugin is free to use for your server.
Terms
Licensed for use on any server
Modification for personal purposes is prohibited
Redistribution, even with credit, is prohibited
Commercial resale is prohibited
No warranty or guarantee is provided
👨💻 Author
Yenith
⭐ Thank You!
Thank you for using PlaytimeReward! If you enjoy this plugin:
- Share it with other server owners
- Leave feedback and suggestions
- Report bugs to help improve it
- Consider supporting future development
- Join our Discord community: https://discord.gg/cybycQ9wGp
Made with ❤️ for the Minecraft community
Last Updated: 06 October 2025
Similar projects
Plugin →VeinMiner
Mine the whole vein on mining a single ore/block. Make the tedious mining experience to something satisfying and fun! FTB Ultimine alternative
99.3MSueta
Let Me Despawn
Improves performance by tweaking mob despawn rules. Say bye to pesky unintentional persistent mobs.
25MSueta
VeinMiner Enchantment
Veinminer Addon - Adds vineminer enchantment to enchanting tables. Only tools with the enchantment can veinmine
18MSueta
JourneyMap
Real-time map used for mapping in-game or your browser as you explore.
14.7MSueta
Emotecraft
Create your own emotes in Minecraft.
7.5MSueta
Simple Tpa
A simple tpa plugin which sends requests
5.4MSueta