Commit Graph

47 Commits

Author SHA1 Message Date
Alexander Brandes 3d5c694daa
chore: Comply with OSSRH licensing guidelines (#3684) 2022-06-15 20:17:17 +02:00
Alexander Brandes 1470b7117a
chore: Add tadpole buckets to the list of dispensable items (#3669)
chore: Add tadpole buckets to the list of disposables

Signed-off-by: Alexander Brandes <mc.cache@web.de>
2022-06-12 10:46:21 +02:00
Bernhard 0a32268784
Prevent blocks moving/generating below and above build height (#3641)
* fix: cancel BlockFormEvent outside of build limit

* refactor: rename variables for easier readability

* fix: cancel liquid flow outside build limit

* refactor: implement to/from context
2022-06-05 20:51:07 +02:00
Jordan 9f632af0ae
Implement extended world heights from Y-64 to Y319 #3473 (#3473)
* Begin to implement extended world heights:
 - Implemented in Bukkit module (and where required in Core module)

* Implement extended world heights into core module

* Add min gen height to setup,

* Default gen/build heights based on minecraft version

* Few fixes

* Fix up queues

* Address comments

* Make road schematic stuff slightly more efficient by sharing queues

* Minor fixes, don't overlay error many times for the same y

* Fix incorrect schematic paste height, undo changes to HybridUtils

* Overhall regenallroads method to make it work, make sure BukkitChunkCoordinator can/will finish

* Process chunks in order when regenerating all roads

* Address comments

* Address comments

* Ground level//bedrock is at min gen height
 - Add comment on == rather than <= being used
 - It's because it's only checking for the bedrock layer being broken if that's disabled

* Fix offset for min build height in SchematicHandler

* Better javadoc

Co-authored-by: Hannes Greule <SirYwell@users.noreply.github.com>

* Address inclusivity issues for max world height

* Javadocs/comments/deprecation

* Use world min/max heights if present in QueueCoordinator

* Address some deprecations for regions and biome setting

* Add a count for chunks we're currently trying to load to not skip chunks at the end of a queue's edit

* Use minGenHeight + 1 rather than build height in AugmentedUtils

* Create utility method for layer index in GenChunk

* Correct height in HybridUtils, also use minGenHeight + 1

* Don't magically split to 128 height in regeneration

* Add utility methods for world height in QueueCoordinator

* Clean up ClassicPlotManager road creation/removal

* Start generation at min gen height if bedrock is disabled

* min gen height is set in PlotArea

* Add note on schem y normalisation

* Improve plot getVolume method readability

* Don't overly extend height when regenerating road region

* y index utility method in ChunknQueueCoordinator

* Layer index utility method in LocalChunk

* Use version min/max heights if world not present in QueueCoordinator

* Fix min -> max

* Don't allow players to modify outside build height when using plot set  / schematics.
 - Also fixes schematic height issues

* Remove debug

* Address comments

* Switch loadingChunks to AtomicInteger to be safe (in case of multi-threaded)

* Fix "security" issue that was already present

* Ensure sign isn't physicsed

Co-authored-by: Hannes Greule <SirYwell@users.noreply.github.com>
2022-03-05 19:03:39 +01:00
Pierre Maurice Schwang 7557df96c7
Cancel block placement if the block consists of two block states (#3487)
* fix: cancel block placements out of area

* chore: use BlockMultiPlaceEvent

* chore: fix comment typo

* fix: max build height should be exclusive
2022-02-11 11:21:59 +01:00
Jordan 1f28bac955
Fix: Plot#getOwner can be nullable, and redstone may be present on unowned plots (#3472) 2022-01-27 12:14:16 +01:00
NotMyFault 25095f4546
chore: Welcome 2022 2022-01-02 22:22:19 +01:00
Alex 47ae79e123
Revert "refactor: Address MiniMessage deprecations (#3354)" (#3371)
This reverts commit f086826942.
2021-12-14 23:04:36 +01:00
Alex f086826942
refactor: Address MiniMessage deprecations (#3354)
* refactor: Address MiniMessage deprecations

* refactor: More MiniMessage deprecations

* Move away from our `Templates#of`

* Address comments

* style: Address migration style issues

* docs: Add javadoc link for MiniMessage
2021-12-13 09:48:34 +01:00
Alex 48c7a3e94e
refactor: Use player friendly done message on restricted building (#3309) 2021-11-02 13:32:04 +00:00
NotMyFault 2988ad6b11
Address style violations 2021-08-18 11:58:18 +02:00
Traks fd4cec39c4
Fix sponge absorbing water across plot borders (#3191)
* Fix sponge absorbing water across plot borders

* Shorten for-loops by using removeIf

* Use 'Location' instead of 'var'

Co-authored-by: NotMyFault <mc.cache@web.de>
2021-08-03 19:07:02 +00:00
dordsor21 a5452012b5
separate 1.17-only events 2021-06-26 20:08:25 +01:00
NotMyFault 6a57a5c369
Fixes #3100 2021-06-24 16:40:10 +02:00
NotMyFault 45c566859e
Don't fail loading on versions prior to 1.17 2021-06-21 10:30:48 +02:00
NotMyFault 4dbbf8f599
1.17 (#3088)
* Minor work for 1.17

* Address TODOs

Introduce `entity-change-block` flag covering blocks affected by `onPeskyMobsChangeTheWorldLikeWTFEvent`. Previously this was covered by the mob-place flag, however, changing the tilt state of big drip leafs and a series of other blocks call `EntityChangeBlockEvent` so this shouldn't be covered by mob flags only.

* Address other TODOs

* Compile against paper 1.17

This will only work if you built paper locally and deployed it to your local maven repo.

* Updated linked javadoc links

* Handle sculk sensor events in a more controllable way

* Update issue forms for 1.17
2021-06-20 18:17:18 +02:00
NotMyFault b196c9ce8e
Fix place flag message 2021-06-16 01:15:09 +02:00
Patrick "IPat" Hein 2045a4988d
Prevent dragon eggs from leaving or entering plot bounds (#3075)
* Negate mob-place flag debug message

* fixed a little typo :)

* Added check for dragon egg teleportation event
https://github.com/IntellectualSites/PlotSquared/issues/3074

* Basic dragon egg interact bugfix (Left-click interaction)

Co-authored-by: NotMyFault <mc.cache@web.de>
2021-05-28 10:57:48 +02:00
Patrick "IPat" Hein 7c4a85325c
Added event handler for cauldron water level modification to prevent untrusted players interacting with a plot (#3035)
* Added check for burning players using non-trusted plots cauldrons to extinguish themselves, causing the cauldron level to decrease

* Cancelling burning of players without downscaling water instead of ignoring their burn status

* Using Java 14 JEP 305 enhanced instanceOf

Co-authored-by: NotMyFault <mc.cache@web.de>

* Players without permissions may not wash banners or armor now either. Rain modification is now permitted.

* Extinguishing is now explicitly handled so that event handling for other plugins has the actual information of the new cauldron water level

* Un-nestified the if-condition :)

* Properly cancelled the event (since it is semantically cancelled)

* (Actually) properly cancelled the event (since it is semantically cancelled)

Co-authored-by: NotMyFault <mc.cache@web.de>
2021-05-18 19:23:22 +00:00
NotMyFault 3748d8e246
Minor cleanup in favor of Java 16
- Addressing a few command deprecations during the major release superseded by toggles
- Don't swallow SQL warnings in loggers behind debug, as it's often set to false
- Deleted JavaVersionCheck, it's part of ServerLib.
2021-05-15 20:39:16 +02:00
NotMyFault e1fb8c1ae5
Take building min height also into consideration 2021-04-11 10:12:37 +02:00
NotMyFault 027456fd77
Add crop-grow flag 2021-02-24 18:41:36 +01:00
Alexander Söderberg 57fc51d013 Initial annotation usage cleanup + EditorConfig 2021-01-09 22:28:41 +01:00
N0tMyFaultOG f47561b580
Invert leaf-decay message 2021-01-01 21:51:28 +01:00
N0tMyFaultOG 4f60da292a
Add leaf-decay flag
Stop leaves from decaying.
2021-01-01 21:47:09 +01:00
N0tMyFaultOG e8642df674
Update licenses to 2021
Happy new year 🎆
2021-01-01 00:19:45 +01:00
Hannes Greule fafdae9ba9
Only check ice-form for ice (#2940)
Co-authored-by: NotMyFault <mc.cache@web.de>
2020-12-28 14:11:30 +00:00
dordsor21 992a683ba2
another annoying cache thing 2020-12-14 15:22:10 +00:00
dordsor21 e8e116312a
Merge branch 'v5' into v6
# Conflicts:
#	Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntityEventListener.java
#	Core/src/main/java/com/plotsquared/core/command/Deny.java
#	Core/src/main/java/com/plotsquared/core/util/SchematicHandler.java
2020-12-14 15:15:27 +00:00
dordsor21 de3ba9a25c
re-send block change for blocks with gravity if they're physicsed
fixes PS-159
2020-12-14 14:53:53 +00:00
Alexander Söderberg c8ad936d26
Clean up PlotPlatform a bit and make the placeholder registry injectible 2020-12-05 18:41:41 +01:00
N0tMyFaultOG fed7f89f96 Fix compiling 2020-11-02 11:58:07 +01:00
N0tMyFaultOG aefa629509 Generify permissions thru Permission class
- Fixed a few improper permissions
- Fixed a couple of typos
2020-11-02 00:55:58 +01:00
Mariell Hoversholm c3069a425d Format licence headers 2020-10-08 14:02:08 +02:00
N0tMyFaultOG ec23fcdd75 Rewrite build scripts
Co-Authored By: Mariell Hoversholm <proximyst@proximyst.com>
2020-10-08 14:02:08 +02:00
N0tMyFaultOG 0f9554c717 Merge branch 'v5' into v6 2020-09-02 17:19:12 +02:00
N0tMyFaultOG d19dde2f85 Add more debugs 2020-09-02 17:18:41 +02:00
N0tMyFaultOG 7a529e156d Add deb for onBlockIgnite event 2020-09-02 17:03:56 +02:00
N0tMyFaultOG 4a220f9bfb Update license header 2020-08-15 14:59:29 +02:00
N0tMyFaultOG 2b17f730d4 Merge v5 into v6 2020-08-12 18:20:37 +02:00
dordsor21 7bad242944
Merge branch 'v6' into feature/v6/json. It builds!
# Conflicts:
#	Bukkit/build.gradle
#	Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/generator/DelegatePlotGenerator.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/inject/BukkitModule.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEvents.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/queue/ChunkCoordinator.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java
#	Bukkit/src/main/java/com/plotsquared/bukkit/util/BukkitUtil.java
#	Core/src/main/java/com/plotsquared/core/PlotSquared.java
#	Core/src/main/java/com/plotsquared/core/command/Area.java
#	Core/src/main/java/com/plotsquared/core/command/Clear.java
#	Core/src/main/java/com/plotsquared/core/command/Debug.java
#	Core/src/main/java/com/plotsquared/core/command/DebugRoadRegen.java
#	Core/src/main/java/com/plotsquared/core/command/Relight.java
#	Core/src/main/java/com/plotsquared/core/command/Set.java
#	Core/src/main/java/com/plotsquared/core/command/Template.java
#	Core/src/main/java/com/plotsquared/core/command/Trim.java
#	Core/src/main/java/com/plotsquared/core/components/ComponentPresetManager.java
#	Core/src/main/java/com/plotsquared/core/generator/ClassicPlotManager.java
#	Core/src/main/java/com/plotsquared/core/generator/HybridPlotManager.java
#	Core/src/main/java/com/plotsquared/core/plot/Plot.java
#	Core/src/main/java/com/plotsquared/core/plot/flag/GlobalFlagContainer.java
#	Core/src/main/java/com/plotsquared/core/queue/AreaBoundDelegateQueueCoordinator.java
#	Core/src/main/java/com/plotsquared/core/queue/ChunkQueueCoordinator.java
#	Core/src/main/java/com/plotsquared/core/queue/LocalBlockQueue.java
#	Core/src/main/java/com/plotsquared/core/util/ChunkUtil.java
#	Core/src/main/java/com/plotsquared/core/util/EntityUtil.java
#	Core/src/main/java/com/plotsquared/core/util/RegionManager.java
#	Core/src/main/java/com/plotsquared/core/util/WorldUtil.java
#	Core/src/main/java/com/plotsquared/core/uuid/UUIDPipeline.java
#	build.gradle
2020-08-08 13:20:30 +01:00
N0tMyFaultOG ab121c7eee Fixes https://github.com/IntellectualSites/PlotSquaredSuggestions/issues/133 2020-07-26 21:12:32 +02:00
dordsor21 221d299052
Fix a few remaining merge issues (+1 squashed commits)
Squashed commits:

[8c6b55dd4] Fix a few remaining merge issues
2020-07-24 17:57:16 +01:00
Alexander Söderberg 73e3572c72
Fix the redstone flag on roads 2020-07-21 13:11:28 +02:00
dordsor21 14b6f84816
fix typos that were c/p over 2020-07-12 18:50:04 +01:00
dordsor21 c045ef698c
Add license headers and fix method change in PlotSquared.java 2020-07-12 11:42:45 +01:00
dordsor21 3a11ffc77a
Clean up bukkit listeners by splitting them up 2020-07-11 19:03:55 +01:00