
Grace999
GracePlugin provides configurable, per-world grace periods with PvP and mob damage protection, boss bar countdowns, sound alerts, and customizable safe zone regions with flag-based protections.
New Features
Admin GUI Panels
- Added
/grace guito open a full admin control panel. - Added a timer control panel for start, pause/resume, stop, extend, reduce, and reload actions.
- Added a global flag panel with live click-to-toggle controls.
Bug Fixes
Deathban Bypass
- Fixed deathban bypass handling so the bypass permission is respected when enabled.
Warning Intervals
- Fixed warning interval behavior so warnings trigger on threshold crossing instead of firing early in batches.
- Improved warning state tracking after time changes.
Pause and Resume
- Fixed pause behavior to stop only the timer task without destroying the boss bar.
- Fixed resume behavior to correctly continue countdown state and warnings.
Per-Player Grace Rejoin Abuse
- Fixed personal grace rejoin abuse by persisting completed personal grace records.
- Players who finish personal grace no longer receive a fresh timer on reconnect.
Reload and Defaults
- Fixed reload flow to refresh default flag baselines before rebuilding world/global runtime values.
Auto-Start and World Duration
- Fixed auto-start so it starts once instead of repeatedly restarting per enabled world.
- Fixed grace start duration resolution to use world duration defaults when no manual duration is provided.
Command Blocking
- Fixed blocked command matching to normalize namespaced command forms.
- Added
New Features
Warning Intervals System
- Configurable warning broadcasts before grace period ends
- Set custom times for warnings (e.g., 10 minutes, 5 minutes, 1 minute, 30 seconds)
- Custom messages for each warning interval with time placeholder support
- Optional warning sounds
Configurable Sounds
- Customize the sound played when grace period starts
- Customize the sound played when grace period ends
- Customize the sound played for warning broadcasts
- Customize the sound played when an action is blocked
- Adjustable volume and pitch for all sounds
World-Specific Flag Defaults
- Set different default flag values for each world
- Example: Disable PVP protection in the Nether but enable it in the Overworld
- Falls back to global defaults if world-specific settings are not defined
New Commands
/grace extend <seconds>- Extend the current grace period by a specified amount/grace reduce <seconds>- Reduce the current grace period by a specified amount
PlaceholderAPI Integration
- Full PlaceholderAPI support for use with scoreboards, holograms, and other plugins
- Global grace placeholders (active status, time remaining, paused status)
- Per-player grace placeholders (personal grace status and time)
- Region placeholders (current region name)
- World placeholders (grace enabled status)
- Flag placeholders (value of any flag)
- Multiple time format options (seconds, formatted, short)
Changes
Flag Naming Convention
- Renamed all flags to use
allow-*prefix for clarity pvp→allow-pvpblock-breaking→allow-block-breakingblock-placing→allow-block-placingmob-damage→allow-mob-damagemob-spawning→allow-mob-spawningitem-drop→allow-item-dropitem-pickup→allow-item-pickupcommand-blocking→allow-commandstruenow means the action is allowedfalsenow means the action is blocked
Configuration Documentation
- Added complete command reference to config.yml
- Added complete permission reference to config.yml
- Added complete placeholder reference to config.yml
- Added complete flag reference to config.yml
New Features
Commands
- Added
/grace stopcommand to manually stop an active grace period - Added
/grace start [duration]command with optional duration parameter in seconds - Added
/grace delete <regionName>command to remove existing regions - Added
/grace listcommand to display all created regions - Added
/grace info <regionName>command to view detailed region information including all flag states - Added
/grace setflag <regionName> <flag> <true|false>command as an alternative syntax for setting region flags - Added full tab completion support for all commands, subcommands, region names, flag names, and boolean values
Configuration
- Added
default-flagssection in config.yml allowing server admins to configure the default state of each flag - All flags now default to
true(enabled) when not explicitly set - Added
grace-stoppedmessage configuration option - Flags can now be pre-configured before the plugin loads
Permissions
- Added
grace.stoppermission for stopping grace periods - Added
grace.deletepermission for deleting regions - Added
grace.listpermission for listing regions - Added
grace.infopermission for viewing region information
Quality of Life
- Status command now displays the state of all global flags
- Help menu now only shows commands the player has permission to use
- Time formatting now includes hours for longer durations
- Improved feedback messages with color coding for flag states
- Region creation now validates that both corners are in the same world
- Region creation now checks for duplicate region names
- Added helpful hints after command execution
Bug Fixes
Combat and Damage
- Fixed projectile damage (arrows, tridents, etc.) not being blocked during grace period
- Fixed invincible-players flag logic being inverted
- Fixed PVP checks not properly considering per-player grace status
- Fixed mob damage flag not applying correctly in some situations
Grace Period Management
- Fixed grace period not properly ending when time expires
- Fixed boss bar progress calculation going negative or above 100%
- Fixed paused grace time not being calculated correctly when resumed
- Fixed grace period persisting across server restarts incorrectly
- Fixed auto-start not finding valid worlds when worlds section is missing
Per-Player Grace
- Fixed personal grace period not starting for new players
- Fixed players receiving duplicate grace start notifications
- Fixed personal grace expiry check not removing expired entries
- Fixed extra life feature not properly preserving inventory and experience
Deathban System
- Fixed deathban not properly kicking players after the delay
- Fixed spectator mode not being applied before deathban kick
- Fixed IP ban using incorrect method
- Fixed deathban ignore permission not being checked correctly
Regions and Flags
- Fixed region flag values not being read correctly from grace.yml
- Fixed global flags not loading default values from config
- Fixed command blocking flag logic being inverted
- Fixed flight not being disabled when leaving a flight-allowed region
- Fixed null pointer exception when checking regions in unloaded worlds
General
- Fixed cooldown messages being sent too frequently
- Fixed null pointer exceptions when items have no metadata
- Fixed region selection tools not being recognized after relog
- Fixed mob spawning flag blocking custom/plugin spawns
- Fixed movement event firing on head rotation without position change
- Fixed configuration not reloading all values on
/grace reload
- Added
Version 1.0.5
New Features
- No damage from everything: Players can be protected from all types of damage during grace period
- Grace starts from join: Individual grace periods start for each player when they join the server
- 1 Extra Life: Players get one extra chance during grace period to prevent immediate death
- No Hunger Loss: Players don't lose hunger during grace period
- Deathban Settings: Comprehensive deathban system with configurable options:
- Custom ban reason
- Configurable ban delay
- Spectator mode after death
- Ban duration in seconds
- IP ban option
- Permission handling for spectator mode
Configuration Changes
- Added new settings to config.yml for all new features
- Enhanced deathban configuration with detailed comments
- Added data persistence for extra life usage
Added
- Global Flag System: A new system to control plugin features globally.
- New command
/grace flag <flagname> <true|false>to set global flags (e.g.,/grace flag pvp false). - Flag states are saved in
grace.ymland persist across server restarts. - New permission
grace.globalflagto control usage of the global flag command.
- New command
Changed
- All Flags Now Work Globally: All existing flags can now be controlled at a global level, acting as a master switch. This includes:
pvpblock-breakingblock-placingmob-damagemob-spawninginvincible-playerscommand-blockingallow-flightitem-dropitem-pickup
- PvP Region Flag: The
pvpflag can now also be applied to specific regions, in addition to being a global flag.
- Global Flag System: A new system to control plugin features globally.
GracePlugin v1.0.3 Changelog
This update introduces several new features and flags to enhance the functionality of the GracePlugin.
New Features
Grace Period Pause and Resume
Admins can now pause and resume the grace period timer. This is useful for server maintenance or other events.
/grace pause: Pauses the grace period timer./grace resume: Resumes the grace period timer.
Command Blocking
A new
command-blockingflag has been added to regions. When enabled, this flag will block the commands listed in theblocked-commandssection of theconfig.ymlfile. This can be used to prevent players from using commands like/homeor/tpato escape combat.New Region Flags
The following new flags have been added to regions:
allow-flight: When set totrue, players will be allowed to fly in the region, even if they are not in creative mode.item-drop: When set totrue, players will be prevented from dropping items in the region.item-pickup: When set totrue, players will be prevented from picking up items in the region.
New Permissions
grace.pause: Allows players to use the/grace pausecommand.grace.resume: Allows players to use the/grace resumecommand.
New Configuration Options
The
config.ymlfile now includes ablocked-commandslist. This list contains the commands that will be blocked when thecommand-blockingflag is enabled for a region.blocked-commands: - home - tpa - spawnFixed bug where grace period remained active indefinitely if end time was in the past on server restart. Separated auto-start grace duration from the main grace duration to prevent unintended overwrites. Added a BossBar countdown visible to all players during the grace period showing remaining time. Added sound notification (Ender Dragon growl) to all players when the grace period ends. Made mob damage prevention during grace configurable and applied it to safe zones. Implemented per-world grace periods allowing grace to be toggled and configured separately per world. Introduced temporary safe zones with region claiming via /grace tools and /grace claim
. Provided special wooden pickaxe and shovel tools for region corner selection, only usable if given by the plugin. Added configurable flags for safe zones: block-breaking, block-placing, mob-damage, mob-spawning, and invincible-players (all disabled by default). Stored safe zone regions and flags persistently in a separate grace.yml file. Added commands to manage safe zones and flags: /grace <true|false>. Improved messaging with action bar timers, titles, and cooldown messages to reduce spam. Added permission checks for all commands and features to ensure proper access control. Version 1.0.1 - Major Update 🚀 New Features
- Grace Period Persistence Across Server Restarts
Description: Grace period state now persists through server restarts and crashes Implementation: Both graceActive status and graceEndTime are saved to config file Benefit: No more lost grace periods when server restarts unexpectedly 2. Auto-Start on Server Startup
Description: Configurable automatic grace period start when server loads Configuration: auto-start: true/false - Enable/disable auto-start auto-start-duration-seconds: 120 - Duration for auto-started grace period Benefit: Perfect for server resets or scheduled maintenance periods 3. Countdown Broadcast System
Description: Automatic countdown announcements during final 10 seconds Implementation: Broadcasts "Grace ends in X second(s)!" messages Benefit: Players get clear warning before PVP enables 4. Enhanced Entity Protection
Description: Configurable entity blocking system (placeholder) Implementation: Framework for future entity-specific blocking configuration Benefit: Flexible protection beyond just player vs player combat 🐛 Critical Bug Fixes
- Memory Leak Prevention
Issue: HashMap<Player, Long> caused memory leaks as players logged out Fix: Changed to HashMap<UUID, Long> using player UUIDs instead of Player objects Impact: Eliminates memory buildup over time, improves server stability 2. Refined Wolf Protection Logic
Issue: All wolves were protected, including wild wolves unrelated to PVP Fix: Now only protects tamed wolves owned by players Implementation: Uses wolf.isTamed() && wolf.getOwner() instanceof Player checks Impact: More targeted protection that doesn't interfere with normal gameplay 3. Grace State Synchronization
Issue: Potential desync between memory state and saved state Fix: Immediate config save when grace period starts Impact: Prevents state loss between command execution and server shutdown 4. Negative Time Display Prevention
Issue: Grace timer could display negative seconds Fix: Added bounds checking in formatTime() method Impact: Cleaner, more professional time displays 🔧 Technical Improvements
- Enhanced Command Sender Handling
Change: Replaced string-based console detection with ConsoleCommandSender instanceof check Benefit: More reliable and maintainable console command handling 2. Improved Config Management
Change: Reduced unnecessary config saves to prevent overwriting user changes Benefit: Better preservation of custom configuration settings 3. Action Bar Integration
Feature: Grace period remaining time displayed above experience bar Benefit: Constant visual reminder for players during grace period 4. Message Cooldown System
Enhancement: 5-second cooldown on PVP disabled messages Benefit: Prevents message spam when players rapidly attack during grace
the first release
