✨ SUPERPICKAXE UPDATE v11.0.0 ✨
Bringing a more thrilling and engaging mining experience than ever before!
---
FEATURE 1: LUCKY SPIN
Description:
When mining blocks with a special pickaxe, players have a small random chance to receive a
Spin Ticket (a special Paper item in their inventory). Use the
/sp spin command to open a 3x3 GUI wheel with a rolling animation that stops to grant a random reward.
Available Rewards (Fully configurable in config.yml):
- Large Cash Prizes: From $5,000 to $50,000.
- ⚡ 30-Minute Boosters: Money x2 or XP x2.
- Rare Items: Diamonds, Netherite Ingots...
- Free Pickaxe Repair.
- Jackpot: Double drops on the next mine!
- ❌ Nothing: An unlucky slot (no reward) to add more drama and excitement.
️ Gameplay Flow:
- Mine blocks ➡️ 0.5% random chance to drop a Spin Ticket directly into the inventory.
- Server broadcast: [LUCKY] %player% just received a Spin Ticket! Use /sp spin
- Type /sp spin ➡️ Opens a 9-slot GUI, playing a 2-second rolling animation.
- A random slot flashes ➡️ Rewards are given + Server broadcast if it's a Jackpot.
---
⚔️ FEATURE 2: MINING DUEL
Description:
Players can use the command
/sp duel <player> <bet_amount> to challenge someone to a 1v1 match. Both players will mine at the same time for 60 seconds; whoever breaks more blocks wins and takes the entire pool!
️ Gameplay Flow:
- /sp duel Steve 10000 ➡️ Sends a duel invitation with a bet. Steve receives a notification to accept via /sp duel accept.
- Once accepted ➡️ Countdown 3 - 2 - 1 ➡️ The 60-second duel begins.
- During the duel, the ActionBar continuously updates in real-time: [DUEL] You: %blocks% | Steve: %blocks% | %time%s left
- Time's up ➡️ Server-wide broadcast of the results, and the winner is automatically rewarded.
Rules:
- Players must be holding a special pickaxe to participate in a duel.
- A player cannot participate in or host two duels simultaneously.
- The duel request will automatically expire (Timeout) after 30 seconds if not accepted.
- Block count is tracked accurately using the totalBrokenThisTurn variable from MiningListener.
---
️ PROPOSED CHANGES (CODE STRUCTURE)
- [NEW] SpinManager.java: Manages spin logic, generates Spin Tickets, handles random drops, and calculates rewards based on configuration rates.
- [NEW] SpinGUI.java (Listener): Creates the 9-slot GUI with a fake rolling animation (Uses a Bukkit scheduler running 5 times to update slots), handles click events, and distributes rewards.
- [NEW] MiningDuelManager.java: Manages pending and active duels using a Map: UUID ➡️ DuelSession { opponent, blocks, endTime, bet }. Integrates a scheduler to update the ActionBar every second.
- [MODIFY] MiningListener.java: Adds the random Spin Ticket drop after the processBlockBreak method and increments block count for the DuelSession if the player is in an active duel.
- [MODIFY] SuperPickaxePlugin.java: Initializes the new managers (SpinManager, MiningDuelManager) and registers the SpinGUI listener.
- [MODIFY] SuperPickaxeCommand.java: Implements new subcommands:
- • /sp spin — Opens the SpinGUI (Only works if holding a ticket).
- • /sp duel <player> <amount> — Sends a duel invite with a specific bet amount.
- • /sp duel accept — Accepts the incoming duel invite.
- • /sp duel cancel — Declines or cancels the current duel.
---
CONFIGURATION & LANGUAGE FILES
⚙️ config.yml
Code (YAML):
lucky-spin:
enabled
: true
drop-chance
: 0.5
# % per block mined
broadcast-on-drop
: true
rewards:
- type
: MONEY
amount
: 5000
weight
: 40
display
:
"§a$5,000"
- type
: MONEY
amount
: 20000
weight
: 20
display
:
"§a$20,000"
- type
: MONEY
amount
: 50000
weight
: 5
display
:
"§6§l$50,000 JACKPOT!"
- type
: ITEM
material
: DIAMOND
amount
: 5
weight
: 15
display
:
"§b5x Diamond"
- type
: BOOSTER
booster-type
: MONEY
multiplier
: 2.0
minutes
: 30
weight
: 10
display
:
"§6x2 Money Booster 30min"
- type
: REPAIR
weight
: 5
display
:
"§aFree Repair"
- type
: NOTHING
weight
: 5
display
:
"§7Better luck next time!"
mining-duel:
enabled
: true
duration-seconds
: 60
min-bet
: 1000
max-bet
: 1000000
accept-timeout-seconds
: 30
language.yml
- Added all required message strings for the Lucky Spin and Mining Duel systems for easy localization.
---
VERIFICATION PLAN
- Mine blocks with a special pickaxe ➡️ Wait for a Spin Ticket to drop ➡️ Use /sp spin ➡️ Verify the animation runs smoothly and rewards are given properly according to weights.
- Run /sp duel <player> <amount> ➡️ Have the target player accept ➡️ Verify countdown ➡️ Confirm the ActionBar updates blocks and time live ➡️ Ensure the winner gets the correct payout at the end.
- Test edge cases: Prevent duels when not holding a special pickaxe, having insufficient balance, or when already in another duel session.