Commit Graph

11 Commits

Author SHA1 Message Date
bloodshot e281231d87 Update for 1.5.10 release.
* Fix ClaimBlockTask prematurely exiting if a player had max claim blocks.
* Fix TaxApplyTask not pulling funds from claim bank first.
* Fix ClaimContextCalculator overwriting option claim contexts.
* Fix player option commands running during a command causing a loop.
* Fix player-command-enter running command from subclaim.
* Fix player-command-exit running command to subclaim.
* Fix player contexts not being added in all cases where a player is involved.
* Fix flag definitions not accepting any context.
* Fix elytra enter-claim bypass.
* Add 'claim-create-radius-limit' to global config.
* Add Simplified Chinese language support (zh_CN).
* Add enter-claim flag permission check on player login.
* Add enter/exit-claim support for player respawns. If denied, GD will respawn player back in source claim in a safe location.
* Add TE NBT id support for mods such as gregtech.
* (Hybrid) Fix mohist EntityType mod registration.
* (Hybrid/Sponge) Add TE NBT id support for mods such as gregtech. See new setting 'tile-id-nbt-map' under mod category in global.conf
* (Sponge) Add 'interact-item-force-list' to global config. Used to force interact-item flag checks when a player left/right-clicks with an item in hand.
* (Sponge) Add check to prevent re-registration of worlds.
* (Sponge) Add workaround during collisions when user is wrapped in ProjectileSource.
* (Sponge) Add EntityThrowable support for getEntityOwner.
* (Sponge) Add method to get internal DamageSource type name.
* (Sponge) Fix NPE when cancelling claim with '/claimrent cancel'
* (Sponge) Fix wrong block being checked during bucket interactions such as lava and water.
* (Sponge) Fix block-pre not handing certain mod permission checks such as AE2 cables.
* (Sponge) Fix 'block-id-convert-list' feature not using correct id during player interactions.
* (Sponge) Fix item-pickup flag not checking trust.
2021-03-10 21:25:04 -05:00
bloodshot e8e57c5f5d Update for 1.5.0
* Fix blockstate id lookup not using proper id when block data was different than actual block.
* Fix block-break showing air as target when source block broke on its own.
* Fix race condition when migrating GP Bukkit playerdata.
* Fix race condition during flag definition saves.
* Fix wrong owner showing in claim when non-owner changes claim type.
* Fix explosions causing no sound when cancelling event.
* Fix rent min message showing max.
* Fix rent min payment not being applied as credit.
* Fix rent restore not working on rent end.
* Fix sell sign not working when rent system was disabled.
* Fix '/abandonall' not giving all money back when using economy mode.
* Fix '/claimsell' requiring for sale to be turned on.
* Fix '/givepet' taming pets without owner.
* Fix explosion sounds not triggering on cancel.
* Fix pvp 'allow-fly' only affecting creative mode.
* Fix confirmation message not showing after abandoning a subdivision.
* Fix wrong location being checked when placing water/lava with bucket.
* Fix dynmap owner style colors not being used.
* Fix NPE when using /reload.
* Fix ghost claim overlap error when creating claim.
* Fix user showing up as cause when using rtp.
* Fix high memory usage caused by GDClaimManager fastutil usage.
* (Bukkit) Fix NPE during InventoryMoveItemEvent.
* (Sponge) Fix explosion-surface being triggered with no settings.
* Refactor CompletableFuture handling when applying LP permissions and meta to avoid race conditions.
* Remove owner override context for flag definition 'fire-spread' as it doesn't affect global overrides.
* Change flag definition 'turtle-egg-hatch' target from 'air' to 'turtle-egg-hatch'
* Change flag definition 'snow-melt' target from 'air' to 'snow'
* Change onPlayerInteractBlockSecondary event priority from lowest to low in order to support plugins that need to cancel early.
* Add support for CustomItems. Any customitem used in game will show up in debug as customitems:<item_id>. You can also use customitems for modification and investigation tool in config.
* Add support for Slimefun4. Any slimefun item/block used in game will show up in debug as slimefun:<id>. You can also use slimefun items for modification and investigation tool in config.
* Add '/acball' command for adjusting all online players' bonus blocks.
* Add '/claiminvestigate' command to investigate claims.
* Add '/claimtool' to toggle claim tool usage.
* Add source/target any contexts to flag definitions.
* Add 'piston-protection-in-claims' setting to control piston protection within claims.
* Add pvp setting 'combat-logout' to determine if a player should be killed on logout during combat. Default 'false'.
* Add `projectile-impact-entity` to `endcrystal-use` flag definition.
* Add aquatic target for `monster-animal-damage` flag definition.
* Add `restrict-world-max-height` to determine if claiming should be restricted to world max height. Default 'true'.
* Add ability to control dynmap color settings by claim type.
* Add permission griefdefender.user.claim.command.info.teleport.inside which controls whether a player can ONLY teleport within the claim they are in. This is useful if players become trapped.
Note: This does not allow players to teleport to any other claim except the one they are in. It can only be used if the player cannot build in claim.
* Add permission griefdefender.user.claim.command.info.others.creation-date to control whether a player sees creation date in /claiminfo
* Add permission griefdefender.user.claim.command.info.others.last-active to control whether a player sees last active date in /claiminfo
* Add permission griefdefender.user.claim.command.info.others.claim-uuid to control whether a player sees claim uuid in /claiminfo
* All flag definitions will now persist.
* Refresh player option cache on permission change.
* Show TP info in '/claiminfo' when player does not have TP permission.
* (Sponge) Use 'tnt' as identifier instead of 'primedtnt' to match bukkit.
* (Sponge) Use 'item_frame' as identifier instead of 'itemframe' to
  match bukkit.
2020-08-16 00:39:38 -04:00
bloodshot 26efaf2b73 Update for 1.4.7
* Fix multi-server permissions overwriting eachother when same contexts were used.
* Fix economy resize claim message showing too many decimals for balance.
* (Bukkit) Fix chunk tracking data not respecting world container argument.
* (Bukkit) Fix deny messages not appearing for bucket interactions.
* (Bukkit 1.16) Fix interact-block-secondary being triggered on non-interactable blocks.
* (Sponge) Fix enter/exit messages being triggered by non-players.
* (Sponge) Fix 'interact-entity-primary' not cancelling event if set to false.
* (Sponge) Fix wrong id used for 'item-drop' flag.
* (Sponge) Fix enderpearl being lost when teleport is cancelled.
* (Sponge) Fix bucket protection.
* Add greeting/farewell/name click support in /claiminfo.
* Add 'player-endportal-use' and 'player-netherportal-use' flag definitions.
* Remove 'player-portal-use' flag definition.
* Cache player options during movement to avoid constant LP lookups.
* Improve teleport handling.
* Ignore air blocks during explosions.
* Set block-modify to true by default for vanilla compatibility.
* The 'portal-use' flag is no longer used and has been disabled by default.
* (Sponge) 'entity-chunk-spawn' flag is disabled by default to avoid wrong usage.
* (Sponge) Ignore items and projectiles during MoveEntityEvent.
2020-07-04 21:06:59 -04:00
bloodshot 343dfe9566 Update for 1.4.2 release.
* Fix entity damage not passing source in all cases.
* Fix vehicle destroy source.
* Fix collision interactions being ignored.
* Fix #vehicle context not being added on vehicle item use.
* Fix 'any' context showing up as 'all'.
* Fix context entity type format using '#' in front of name instead of modid.
* Fix parent exit claim messages showing on subclaims.
* Fix block-place using wrong target in some cases.
* Fix NPE during chunk load on new world creation.
* Fix claim resize/subdivide resetting on error.
* Fix offline players not being found with some commands.
* Fix NPE in migrator during claim migration of subclaims.
* Fix accrued blocks not being set for players if value exceeded max during migration.
* Fix playerdata migrate file not being created if parent folder did not exist.
* Fix hover contexts for partial results in flag GUI.
* Fix #pet tag not being formatted properly with contexts.
* Fix entity-damage used_item context not being added.
* Add new group context #hanging which represents hanging entities such as item frames.
* Add lava source to fire-spread flag definition.
* Add user context support for advanced flag GUI.
* Add endercrystal-use and armorstand-use definitions.
* Add entity-damage-source-blacklist.
* Add active claim visual time to config.
* Add tag support for used_item.
* Add visual tracking for create block visuals.
* (Bukkit) Add extra permission check when using item on a block.
* Add gd_claim_override=claim context to water-flow flag definition.
* Add new admin command '/abandonworld [<world>]' which will abandon all user claims in world specified.
* Add support for world argument in commands '/abandonall', '/deleteall', and '/deletealladmin'.
* Add MC 1.16.1 support.
* Update kyori libraries to latest.
* Don't process stair blocks on right-click.
* Refactor ADMIN group handling in PRESET GUI.
   - All ADMIN flags will now be forced to claim only.
   - If you want to change flags globally then simply provide a default context in the definition which will be applied at startup.
* Cleanup USER PRESET hover for normal users.
* Improve persistent check done if a user is trusted.
   - Only non-claim owners that are trusted will have an additional permission check to see if an admin denied/allowed something via a flag not given by trust system.
* (Hybrid) Add mod registry support for hybrid servers.
* (Hybrid) Add mod category to 'global.conf' to identify fakeplayers and mod id's.
* (Hybrid) Add initial fakeplayer support.
* (Hybrid) Added pixelmon animal support.
* (Hybrid) Added #pixelmon:animal tag for natural spawns.
* Check user/group permission excluding default group before trust is checked.
  Note: This allows admins to allow/deny permissions while using trust.
  Note: Only '/cfp' and '/cfg' is supported.
* Only check persistent permissions with overrides.
* Change user context to support all claim types except wilderness.
* Change global context to support all claim types including wilderness.
* Rename /cfd command to /cfdebug to avoid accidental use.
* Disable /cfdebug on logout.
2020-06-25 09:16:08 -04:00
bloodshot f801c065f3 Refactor Flag Definition System. Fixes #123
The flag definition system has had a major rehaul.
The following improvements have been made :
- Support for default values that can be applied on startup.
- All definitions have been moved to its own file 'flags.conf'.
- The 'enabled' setting now works as expected.
- GUI has been updated to show all relevant context/flag information.
- Admin definitions will now display the direct result of a definition.
  Note: The final active result will show on hover.
- User definitions will only display the result of the current claim.
  Note: User's can see extra info on hover.
  Note: If a user definition has been overridden, it won't be toggable.

* Add Context/Location improvements to GDDebug.
  - Users will now be able to expand location/context columns for more
  information.
* Add version check to use proper id for flag definitions.
* Move options from 'global.conf' to its own file 'options.conf'.
* Ignore suffocation for entity damage checks.
* Fix monster projectile's not checking monster source.
* Fix 'used_item' not showing up for buckets.
* Fix flag GUI sort when changing value.
* Fix town tag not showing properly on sponge. Fixes #201
* Change permission 'griefdefender.user.claim.command.flag.arg' to
  admin.
2020-05-05 15:55:32 -04:00
bloodshot 63005e72f8 More fixes on handling of server contexts. Fixes #88
* Server contexts will be automatically added if not found on set.
* Flag definitions will automatically add a server context if none is
found on deserialization.
* Option and Flag GUI will fallback to no server context if none is
found.
2019-12-31 22:42:15 -05:00
bloodshot 436f053fbe Finish implementing options for next major release.
* Fixed '/cfg' and '/cog' commands.
* Fixed 'create-mode' not working as intended.
* Fixed 'any' usage with flag commands.
* Fixed 'command-execute' usage.
* Fixed 'command-execute-pvp' usage.
* Fixed option removal/save with LP v5.
* Added context support for controlling user flag command usage.
* Added context support to option GUI.
* Added permission 'griefdefender.user.claim.command.flag.arg' which controls if a user can use flag command with arguments.
* Added permission 'griefdefender.user.claim.command.flag.gui' which controls if a user can use flag GUI.
* Added new group context '#all' which can be used to represent all sources or targets.
* Removed 'max-claim-inspection-distance' from config as it is now controlled by 'radius-inspect' option.
* Removed 'combat-timeout' from config as it is now controlled by 'pvp-combat-timeout' option.
* Implemented the folloing new options
  'player-command-enter' - Handles executing commands when a player enters a claim.
  'player-command-exit' - Handles executing commands when a player exits a claim.
   Note: both command options support the following placeholders : %player%, %owner%, %uuid%, %world%, %server%, %location%

  'player-gamemode' - Used to determine the gamemode of a player when entering a claim.
  'player-deny-godmode' - Used to determine if a player can be in godmode when entering a claim.
  'player-walk-speed' - Controls the player walk speed when entering a claim.
  'player-weather' - Controls player local weather when entering a claim.
  'pvp-combat-command' - Used to determine if a player can use commands during PvP combat.
  'pvp-combat-teleport' - Used to determine if a player can teleport during PvP combat.
  'pvp-combat-timeout' - Used to determine how many seconds PvP combat is considered to continue after the most recent damage.
  'radius-inspect' - Controls the radius in blocks to search within when inspecting for claims.
  'spawn-limit' - Used to control the spawn limit for a specific set of entities in a claim.
* Only save once when toggling flag definitions that include multiple definitions.
2019-12-30 18:27:37 -05:00
bloodshot d92365e50a More fixes and improvements for 1.2.2 release.
* Fix flags being reset on claim deletion.
* Fix user claim flag permission check.
* Fix sign interaction not using proper flag 'interact-block-secondary'.
* Fix '/claimexpand' and '/claimcontract' tab completion.
* Fix 'entity-damage' flag attempting to protect dropped items.
* Fix 'player-keep-inventory' not clearing drops on death.
* Fix 'player-keep-level' not clearing XP drops on death.
* Fix EntityChangeBlockEvent using wrong source location.
* Fix claim create mode triggering twice on first right-click.
* Fix default/override claim types not showing up properly in Flag GUI.
* Fix entity-damage flag not using proper user on left-click.
* Fix abandon-delay default value.
* Remove ability to resize claims when auto-schematic-restore is enabled.
* Add support for setting no modification/investigation tool in config.
* Add '/claim', '/gd mode claim' command to toggle a new claim mode for inspecting and claim creation.
* Add 'combat-timeout' pvp setting to config to control how long a player stays in pvp combat after an attack.
* Implement 'abandon-delay' option.
* Implement 'player-teleport-delay' option.
* Implement 'pvp' option.
  - When a player attempts to attack another player, both players must have pvp allowed.
  If 1 player is not allowed to PvP, the attack will be cancelled.
* Improve '/claimlist' command.
  - Only trusted claims will be shown to users.
  - Admins can use '/ignoreclaims' to see all claims.
  - Fixed server crash if too many claims were listed.
  - Fixed subdivision filter.
* Improve '/claimspawn' command.
  - The command now takes the following arguments  '/claimspawn [name] [player]'
  Ex. If you want to spawn in a claim that you own named 'lair', you would enter '/claimspawn lair'
  Ex. If you want to spawn in a claim owned by 'Mike' named 'stables', you would enter '/claimspawn stables mike'
* Improve flag definition defaults.
* Improve flag default configuration.

Fixes #51, Fixes #53, Fixes #54
Fixes #55, Fixes #56, Fixes #57
2019-09-18 11:28:49 -04:00
bloodshot e9377d4935 Final fixes for 1.2.0 release.
* Fix user custom flag GUI init not showing USER group.
* Fix item frame protection during explosions.
* Fix entity-spawn not being triggered with slime splits.
* Fix 'SouthCorners' lang translation in /claiminfo.
* Fix 'explosion-entity' flag.
* Fix shovel visual not hitting leaves.
* Add explosion pre support.
* Add extra teleport check for claim corners.
* Add additional overlay/style for custom flags.
* Add javadocs for PermissionProvider.
* Add many improvements to custom flag GUI.
2019-08-25 04:19:31 -04:00
zml c7bed01866 Add support for PermissionsEx v2 (#46)
Support is still fairly rudimentary, but this is a first step to be expanded on
as PEX becomes more stable
2019-08-23 22:26:52 -04:00
bloodshot 6991d6395c Update for 1.2.0 release.
* Implement custom flag system to allow admins to create any flag they desire with contexts.
  See wiki for more info.
* Rewrite option and flag GUI's to be more user friendly.
* Refactor permission handling to support more permission plugins.
* Refactor permission lookups to use storage directly for better context handling
* Refactor option system to support generics.
* Add many new options.
See https://github.com/bloodmc/GriefDefenderAPI/blob/master/src/main/java/com/griefdefender/api/permission/option/Options.java

* Add new permission 'griefdefender.user.claim.option' to control what options user's can use
in their claims. Ex. If a user tries to use 'player-deny-fly', GD will check 'griefdefender.user.claim.option.player-deny-fly'
* Added the following permissions to allow admins to designate a player to manage options
'griefdefender.admin.claim.command.option.group.{type}'
'griefdefender.admin.claim.command.option.player.{type}'

* Add new claim restore setting 'auto-schematic-restore'.
This setting will allow servers to have newly created claims auto-generate a schematic.
When these claims expire, the auto-generated schematic will be used for restore.
Note: This setting is only designed for newly created worlds where players cannot build
in the wilderness. Use with caution and read comments carefully.

* Add new message setting 'enter-exit-chat-type'.
This setting is used to control the default chat type (Chat/ActionBar/Title) used when sending
enter/exit claim messages to players.
Note: This can be overridden by plugins.

* Add support for controlling raids. You can find the new toggle in /raid
* Add various GP command aliases to make it easier for users transitioning to GD
* Add confirmations for all claim delete commands.
* Add GPFlags migrator.
Note: When the GP Bukkit migrator is enabled, GD will automatically look for GPFlags data and migrate
with claim data.
* Add support for EntityCombustByBlockEvent, EntityCombustByEntityEvent, and EntityDamageByBlockEvent.
* Add EssentialsX hook to deny '/fly' command when 'player-deny-flight' is true for a user
* Add event result cache.
* Add contexts to hover in '/cf' command
* Add /givepet command
* Add confirmations to abandon and delete commands
* Add support for /sellblocks in economy mode
* Add new messages for economy mode

* Fix NPE during checkSizeLimits
* Fix interactions with custom inventories.
* Fix custom flags not showing up in '/cf' command.
* Fix interact-inventory denying action when interact-block-secondary is true
* Fix interact-inventory not checking entity ids.
* Fix shovel location being reset with insufficient blocks
* Fix GP Bukkit migrator not handling subdivisions properly.
* Fix 'block-break' flag being ignored in wilderness
* Fix invalid playerdata UUID files being loaded causing errors in console.
* Fix HashSet error in TaxApplyTask
* Fix 'command-execute' flag
* Fix PvP setting in /claiminfo.
* Fix claim overrides not checking default group.
* Fix various message issues
* Fix 'minecraft:air' showing up as used_item context.
* Fix EntityChangeBlockEvent user tracking.
* Fix abandonclaims not returning blocks to player.
* Fix players not being able to use pet inventories in other claims.
* Fix players being kicked when using gd callbacks.
* Fix '/cf' display issues
* Fix '/cf' mod id not being set properly with contexts
* Fix '/cf' item id context lookups
* Fix '/scb' command
* Fix '/gddebug' start/end time.
* Fix economy plugin detection
* Fix economy mode buy/sell not applying proper funds
* Fix ClaimBlocks task not depositing funds while in economy mode
* Prevent /buyblocks working in economy mode
* Remove economy mode check from /scb and /acb
* Rewrite option and flag GUI's to be more user friendly.
* Improve PermissionHolderCache
* Refactor permission handling to support more permission plugins.
* Refactor permission lookups to use storage directly for better context handling
Note: '/lp verbose' will no longer be able to track GD flag lookups.
* Increase cache to 30min
* Change gddebug paste site to griefdefender.github.io
2019-08-23 16:49:00 -04:00