RA-StreakSystem
Author: RajaAditya Website: rajaaditya.my.id Version: 1.0.0 API: Paper 1.21.x (Java 21)
This is a different plugin from RA-Streak. RA-Streak uses chat commands and money tiers, while RA-StreakSystem is menu driven, supports Bedrock forms, and tracks rewards per server.
Features
Personal Streak
- Logging in once per day extends the streak, and a missed day resets it
- Day boundaries use a configurable timezone (default
Asia/Jakarta) - A background task catches players who stay online across midnight without rejoining
Friend Streak
- Two players pair up with
/streak friend invite <player>, and a day only counts when both partners log in that day - Invites can be accepted, declined, or ended at any time
- Friend heads are shown in the menu using cached skins
Grace Period and Recovery
- When a streak "goes out", the player can recover it from the menu, up to a monthly limit (default 3)
- Recovery is manual by default (the player clicks it), and can be made automatic
- When the monthly recoveries are used up, the streak resets to 1
Per-Server Rewards
- Daily and milestone rewards are defined separately for personal and friend streaks in
rewards.yml - Each reward is a list of console commands plus messages
- Claims are tracked per
(player, server, date), so the same streak can be claimed once per server per day while the streak count itself is shared everywhere - Milestones can repeat after a reset or be one-time only
Java and Bedrock Menus
/streakopens a chest GUI for Java players and a Cumulus SimpleForm for Bedrock players, chosen automatically- Every menu item supports a
bedrock:override withenable,priority, andicon, the same convention as RA-ExcellentMenus
Built for Performance
- Database and network work runs on the plugin's own thread pool, and results are returned to the main thread only when Bukkit API is needed
- SQLite mode uses WAL, and is meant for one server only
Dependencies
| Plugin | Required | Purpose |
|---|---|---|
| Floodgate | No (softdepend) | Bedrock player detection and forms |
| LuckPerms | No (softdepend) | Useful for permission rewards |
| PlaceholderAPI | No (softdepend) | Placeholder support |
Installation
- Place
RA-StreakSystem.jarinto yourplugins/folder - Start the server once to generate the config folder, then stop it
- In
config.yml, set a uniqueserver-idand choosedatabase.type(mysqlorsqlite) - If you use MySQL, create an empty database first. The plugin creates its tables itself
- Edit
rewards.yml,messages.yml, andmenu.yml - Start the server
File Structure
text
1
plugins/RA-StreakSystem/
├── config.yml # Server ID, timezone, database, grace period
├── rewards.yml # Daily and milestone rewards (per server)
├── messages.yml # All messages
├── menu.yml # Java GUI and Bedrock form layout
└── streak_data.db # SQLite file (only in sqlite mode)
Configuration
config.yml
yaml
1
server-id: "server-1" # must be unique per server, claims are tracked by it
timezone: "Asia/Jakarta"
database:
type: "mysql" # mysql or sqlite
host: localhost
port: 3306
name: streak_db
user: root
password: "YOUR_PASSWORD"
pool-size: 10
connection-timeout-ms: 8000
sqlite-file: "streak_data.db" # used when type is sqlite
async:
thread-pool-size: 4
scheduled-check-interval-minutes: 5
grace-period:
enabled: true
max-recovery-per-month: 3
auto-recover: false # true = recover automatically on login
skin-cache-ttl-minutes: 15
rewards.yml
yaml
1
personal:
daily:
commands:
- "eco give %player% 100"
messages:
- "&aYou received 100 coins from your daily streak!"
milestones:
7:
commands:
- "give %player% diamond 5"
messages:
- "&6A 7 day streak! You received 5 diamonds!"
30:
commands:
- "lp user %player% parent add vip-temp"
friend:
daily:
commands:
- "eco give %player% 150"
milestones:
7:
commands:
- "give %player% golden_apple 2"
# false = a milestone can repeat each time the streak reaches that number again
reset-milestones-after-claim: false
%player% is replaced with the claiming player's name in every command.
menu.yml
yaml
1
main-menu:
title: "&8Streak Menu"
size: 27
items:
personal-streak:
slot: 11
material: EMERALD
name: "&aPersonal Streak"
bedrock:
enable: true
priority: 1
icon: "textures/items/emerald"
Commands
| Command | Description | Access |
|---|---|---|
/streak | Open the streak menu (Java GUI or Bedrock form) | streak.use |
/streak claim | Claim today's personal reward without the menu | streak.use |
/streak friend invite <player> | Invite a player to a friend streak | streak.use |
/streak friend accept | Accept the latest invite | streak.use |
/streak friend decline | Decline the latest invite | streak.use |
/streak friend end <player> | End an active friend streak | streak.use |
/streak reload | Reload config.yml, messages.yml, rewards.yml, and menu.yml | streak.admin.reload |
Permissions
| Permission | Default | Description |
|---|---|---|
streak.use | true | Base streak commands and the menu |
streak.admin.reload | op | Reload the configuration |
License
Developed by RajaAditya — rajaaditya.my.id