Commit Graph

2466 Commits

Author SHA1 Message Date
Alexander Brandes
aa94612b70
feat: Add support for 1.19 (#1783)
* feat: Add support for 1.19

* build: Update paperweight version

* fix: obfuscated names, invalid method signatures

* avoid NPE on config access

* build: Update paperweight

* implement no-op light engine to avoid stalled tasks that never complete

* Apply DelegateSemaphore fixes to 1.19 (#1782)

* Apply DelegateSemaphore fixes to 1.19

* Fixes

* Avoid using PalettedContainerRO#recreate as much as possible. Show an error or warning when we're forced to use it to help fix (#1784)

Co-authored-by: Pierre Maurice Schwang <mail@pschwang.eu>
Co-authored-by: SirYwell <hannesgreule@outlook.de>
Co-authored-by: Jordan <dordsor21@gmail.com>
2022-06-10 23:22:06 +02:00
Alexander Brandes
3ec17f3507
chore: Drop WEManager#cancelEditSafe() logger (#1779) 2022-06-10 01:26:59 +02:00
Alexander Brandes
c5a50179f2
[ci skip] build: Switch to bom (#1778)
* build: Switch to bom

* chore: Use javax over checkerframework
2022-06-10 01:26:48 +02:00
Alexander Brandes
d7d43869e6
chore: Update upstream
31e5298 Fixed //stack erroring when given a count of 0 (2108)
2022-06-10 01:05:51 +02:00
Jordan
0b33fa8757
Allow NBT stored in DiskOptimizedClipboards to be written to disk as a compressed byte array at the end of the file (#1745)
* Allow NBT stored in DiskOptimizedClipboards to be written to disk as a compressed byte array at the end of the file

* Add some deprecations/javadocs and provide the expected clipboard version on error

* Javadoc since tags and add location of clipboard folder to error

* Refactor load-from-file method into DOC class

* Refactor nbt loading code into separate method in DOC
2022-06-09 12:48:35 +02:00
Owen
af234b284b
Add block break effect to area pickaxe (#1770)
* Add block break effect to area pickaxe

* Create pos lower

* Check before queueing block effect

* comment
2022-06-09 12:48:24 +02:00
Owen
a16074cbe4
Fix //snowsmooth not working below Y0 (#1769)
* Use min y instead of 0 for SnowHeightMap

* Correctly handle rounding for height

* Revert old fix

* Use y instead of newHeight

* Remove line diff
2022-06-07 12:06:03 +02:00
Jordan
32231b48fe
Avoid int overflow when using fillr in negative coords (#1711)
Fix int overflow when using fill and fillr in negative y-coordinates
2022-06-05 20:52:36 +02:00
Jordan
198c6b7800
Some fixes and improvements to internal queuing (#1715)
* the set array given in NMSAdapter should have get data written to it
 - Fixes #1664
 - May fix #1700

* Having target size >= 2* parallel threads allows for adjacent chunks to be loaded with issues

* "empty" chunk section doesn't need to be localised to the chunk and may be static

* Switch to slightly more performant stream method for testing for non-empty sections

* Implement lock into ChunkHolder preventing any modification to occur whilst the edit is being applied to the world
 (when ChunkHolder is called)

* Add config note about target-size

* set ordinal equal to air if both set and get are `__reserved__`

* Add note to checkAndWaitOnCalledLock method of its use

* Don't print exception and throw

* Switch to a wrapped StampedLock allowing reentrant behaviour
 - StampedLock is not reentrent
 - Allow unlock from a different thread only if it provides the correct stamp
 - This stamp can only be retrieved by the thread owning the lock

* Avoid some "doubling-up" of using checkAndWaitOnCalledLock

* Unbloat `checkAndWaitOnCalledLock`

* Add since tags
2022-06-05 20:52:28 +02:00
Jordan
8228b798e5
Implement biomes to filter blocks and use in Clipboard pasting (#1743)
- Fixes #1741
2022-06-05 20:52:14 +02:00
Alexander Brandes
3a65c64977
chore: Use correct since annoation dates 2022-05-18 21:50:20 +02:00
Alexander Brandes
3c4695bb73
build: Release 2.2.0 2022-05-18 21:46:22 +02:00
Pierre Maurice Schwang
39d77091d9
Don't error when loading a schematic fails (#1744)
fix: Throwable#getMessage may be null
2022-05-16 13:23:21 +01:00
Jordan
deaf5ad2d6
Respect clipboard settings (disk vs memory) when loading a schematic (#1742) 2022-05-14 21:10:13 +01:00
Jordan
1c7643bb58
Allow use of BlockVectorSet for large //line selections instead of LocalBlockVectorSet (#1713) 2022-05-11 13:22:10 +01:00
dordsor21
059c5f046d
"Empty" side effects is default, and default does "apply" side effects 2022-05-10 17:28:09 +01:00
Jordan
b237ddf076
Cherry pick upstream commits to fix SideEffectSet (#1737)
* Fix SideEffectSet.none() being the default set (#1620)

* Fix SideEffectSet.none() being the default set

* Remove the unnecessary private empty constructor for SideEffectSet

* Back to ImmutableMap.of

* Speed up Fast Reorder Mode and make it default (#1653)

* Speed up Fast Reorder Mode and make it default

* Make non-exposed side effects internal

* Docs on isExposed

Co-authored-by: Matthew Miller <mnmiller1@me.com>
2022-05-10 10:11:12 +02:00
Jordan
267dc153f0
Don't initialise a DiskOptimisedClipboard before checking for an existing one in the LocalSession when using loadClipboardFromDisk (#1731) 2022-05-09 12:50:19 +01:00
Jordan
210ee9f2ef
Implement getNameUnsafe method to allow an unloaded world's name to be accessed (#1712)
* Implement getNameUnsafe method to allow an unloaded world's name to be accessed
 - Fixes #1671 and #504

* Add javadoc since tag

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

Co-authored-by: Alexander Brandes <mc.cache@web.de>
2022-05-05 21:39:45 +02:00
Jordan
e294245ec4
Fix some horrendous code where methods supposed to return a boolean only ever return true (#1718) 2022-04-24 18:03:40 +02:00
dordsor21
82ba96bf71
Add constraints to //asc and //desc 2022-04-24 00:11:57 +01:00
dordsor21
f5ef0cadb6
Clean up remaining byte casts from 39081e62c9 2022-04-20 23:47:09 +01:00
Orlaando
3610af15e8
Show number of affected blocks in //set command (#1703)
* Show # of blocks affected in //set

* Fix typo

* fix: Add amount of blocks affected to strings.json

Co-authored-by: NotMyFault <mc.cache@web.de>
2022-04-19 08:55:19 +02:00
Pierre Maurice Schwang
6e26741fdc
fix: respect block categories in RichMaskParser (#1694) 2022-04-11 13:59:54 +02:00
NotMyFault
4970db0405
chore: Use assets for 1.18.2 2022-03-29 12:53:19 +02:00
Pierre Maurice Schwang
d1588f9207
Fix tabcomplete for random pattern / multiple pattern (#1675)
* Merge RandomPatternParser#getSuggestions with upstream

* fix: don't throw AIIBE if patterns are empty

shouldn't be the case in the first place
2022-03-27 09:46:36 +02:00
NotMyFault
d400a470a1
Update upstream
5843aa5 Change vector command converter wording. (2059)
2022-03-13 19:19:59 +01:00
Jordan
5a97b23347
Don't error when adding processors to NullExtent, simply do nothing (#1654) 2022-03-13 18:35:27 +01:00
NotMyFault
95512a4c0b
build: Release 2.1.0 2022-03-10 22:57:23 +01:00
Jordan
e9db749e2f
Add fluid ticking and refactor post-processing a bit (#1554)
* Make postProcessSet a default method and change to void

* Throwable#getMessage is nullable

* Move (re-)ticking to a post-processor per "platform"
 - Add fluid ticking

* chore: Ignore (for us) irrelevant rules

* chore: Fix correct toml syntax?

* Re-add removed method for API-compliance and refactor it to have a use

* Switch to javax annotations

* Switch to recalcBlockCounts for ticking blocks.

* No need to set air count anymore either

* We can still "not tick" in fast mode in 1.17.2

* update adapters

* Let paper create the chunk section if biomes are null

* Adjust notes to settings

* 1.17.2 didn't exist

* Add 1.18.2

* Don't attempt to cache plains biome ID

* Use correct annotation

Co-authored-by: NotMyFault <mc.cache@web.de>
2022-03-10 15:27:25 +01:00
Alex
5d18e15128
Replace JB occurrences with JSR 305 (for now) (#1651)
* refactor: Replace JB occurrences with JSR 305 (for now)

* chore: Update adapter jar
2022-03-10 14:24:44 +01:00
Alex
345785a25e
feat: Support for 1.18.2 (#1641)
* feat: Preliminary work for 1.18.2

* Update SpigotNames to 1.18.2 (#1642)

* 1.18.2 / Biome-Holders, regeneration (#1645)

* 1.18.2 / Biome-Holders, regeneration

* fix: reuse old structure sets

* build: Update dev bundles

* fix: Don't log regen world generation

* fix: Run DataConverter with CBT

* fix: Override `#toNativeBinary`

* fix: Exception on regen

Co-Authored-By: Pierre Maurice Schwang <mail@pschwang.eu>

* refactor: Minor cleanup

Co-authored-by: Aurora <21148213+aurorasmiles@users.noreply.github.com>
Co-authored-by: Pierre Maurice Schwang <mail@pschwang.eu>
2022-03-07 15:20:05 +01:00
Jordan
dec0373081
Fix 1.17 snapshot restoration (#1632) 2022-02-27 21:20:16 +00:00
Jordan
b8ab2a5204
Don't allow heightmap-based brushes to edit the entire world "depth" (#1617)
Fixes #1614

Co-authored-by: Alex <mc.cache@web.de>
2022-02-24 10:33:37 +01:00
Jordan
fc2662e51e
Fix //snapshot in 1.18 and re-implement biome/entity restoration (#1620)
* Re-add "//snap" and "//snapshot"

* Place code in correct method

* Use CompoundBinaryTags in AnvilChunk18 and implement biome/entity restoration

* Address comments

* Fix biome reading

* Fix retrieval of entities from zipped snapshot world

Co-authored-by: Alex <mc.cache@web.de>
2022-02-24 10:33:25 +01:00
Jordan
28a0239437
Fix clipboards to allow proper heights by allowing extended CuboidRegion heights (#1624)
* Fix clipboards to allow proper heights by allowing extended CuboidRegion heights
Fixes #1534

* Add @since

* Fix javadoc comment

Co-authored-by: Alex <mc.cache@web.de>
2022-02-24 10:32:45 +01:00
NotMyFault
f8e6feb1f2
Update upstream
17b9f00 Move tinyurls to ehub.to (2033)
76ec878 Allow biome commands to be used from non-player actors (2034)
2022-02-20 14:18:58 +01:00
Jordan
39081e62c9
byte cannot be used to represent height anymore (#1618)
Fixes #1593
2022-02-17 19:34:25 +01:00
Jordan
f7a0c14a1b
Correctly use getNearestSurfaceTerrainBlock in SurfaceSpline and SchemGen (#1616)
Fixes #1609
2022-02-17 19:34:07 +01:00
dordsor21
3f28a5759d
Make slope method slightly more readable in AngleMask 2022-02-16 18:18:58 +00:00
dordsor21
a40d1ccf51
Better naming for min position in HeightMap 2022-02-16 18:13:04 +00:00
dordsor21
fbe0c08c26
FAWE HeightMap constructor shouldn't be deprecated 2022-02-16 18:02:20 +00:00
dordsor21
05bd84b504
Don't crazily initialise HeightMapFilter...?? 2022-02-16 17:47:43 +00:00
dordsor21
3e85369765
Make angle pattern slope a little more readable 2022-02-16 17:42:22 +00:00
Pierre Maurice Schwang
f657a80dc6
fix: set size of MappedByteBuffer accordingly (#1608) 2022-02-13 13:57:19 +01:00
Pierre Maurice Schwang
646a683f22
fix: add coordinates to tile-entity nbt component (#1607) 2022-02-12 13:38:37 +01:00
NotMyFault
d80bfc7495
docs: Update wiki link 2022-02-04 11:16:23 +01:00
NotMyFault
38b0dcf7e4
Update upstream
e485433 Fix legacy error message output for WorldGuard commands (2023)
2022-01-30 19:54:50 +01:00
NotMyFault
e309cf8f3c
build: Update PlotSquared 2022-01-27 15:30:18 +01:00
Alex
e8f72d6521
fix: Deduplicate error messages (#1557)
Fixes https://github.com/IntellectualSites/FastAsyncWorldEdit/issues/1535
2022-01-24 12:52:33 +01:00
Alex
016b4ba81d
fix: Unify superpickaxe behavior (#1553)
Fixes https://github.com/IntellectualSites/FastAsyncWorldEdit/issues/1547
2022-01-21 14:41:24 +01:00
NotMyFault
d17e3a6555
chore: Add missing Fawe annotations to //regen command 2022-01-19 13:58:52 +01:00
dordsor21
d3696f91d4
Synchronise access to the PriorityQueue used for effect queuing in AbstractWorld
- Makes it thread-safe
2022-01-15 17:09:49 +00:00
Jordan
6a972e7b99
Heightmaps used for brushes etc. should be normalised to zero. (#1522)
* Heightmaps used for brushes etc. should be normalised to zero.
Fixes #1508

* chars are unsigned

* Add scale paramer to javadoc
2022-01-14 10:49:23 +01:00
Alex
9e40b972b1
refactor: Put Fawe version information at debugpaste to (#1533) 2022-01-12 01:22:24 +01:00
Alex
9ba90d8c83
refactor: Drop custom snakeyaml implementation (#1523)
* refactor: Drop custom snakeyaml implementation

* Merge branch 'main' into chore/main/remove-snakeyaml-wannabe-abstraction
2022-01-09 10:55:16 +01:00
dordsor21
c2f3c13a09
Fix #1510 2022-01-08 18:10:14 +00:00
dordsor21
4754f660c7
Fix #1524
Also brings in line with upstream
2022-01-08 17:46:28 +00:00
Alex
64442a8051
refactor: Tackle a few Semgrep and ErrorProne violations (#1520)
* refactor: Tackle a few Semgrep and ErrorProne violations

* Address comments
2022-01-07 12:45:53 +01:00
dordsor21
722c411219
Add workaround for when expressions are parsed in masks/patterns where '&&' is used
Fixes #1517
2022-01-05 17:46:18 +00:00
Owen1212055
c27a34ce40
feat: Add worldedit.schematic.list.other permission and functionality (#1507)
* Add worldedit.schematic.list.other permission and functionality

* Implement StringMan#containsUuid

* Javadocs

* chore: Add since annotation

Co-authored-by: NotMyFault <mc.cache@web.de>
2022-01-05 16:21:44 +01:00
NotMyFault
ef686af8dd
Update upstream
fb5ec19 Fix error for snapshot restore missing chunk
2022-01-04 21:01:49 +01:00
NotMyFault
b8399abfe1
refactor: Deprecate tick limiter API for public use 2022-01-04 20:33:05 +01:00
NotMyFault
7e96853b89
docs: Fix deprecation tag 2022-01-01 18:46:28 +01:00
dordsor21
0994ea1e67
Fix issue with offset/origin when pasting a clipboard via API without wrapping into a BlockArrayClipboard 2021-12-30 16:05:16 +00:00
dordsor21
f30ea96268
Refactor: add javadoc to Clipboard#create and improve variables when delegating to another paste method 2021-12-30 16:04:38 +00:00
NotMyFault
122cba677a
docs: Put since annotation on newly introduced API 2021-12-29 18:14:18 +01:00
dordsor21
235d0360da
Don't wrap Exception thrown upon invalid schematic path inside a RuntimeException
Fixes #1506
2021-12-29 16:55:32 +00:00
dordsor21
52fa44516e
Throw, catch, and rethrow our own exception to make sure we're finding the culprit to a possible shaded-FAWE. 2021-12-29 16:47:34 +00:00
dordsor21
9e8f0e7325
Refactor: getVersionMin/MaxY -> versionMin/MaxY 2021-12-29 16:44:41 +00:00
dordsor21
f505828af1
More enhanced switches 2021-12-29 16:44:18 +00:00
NotMyFault
19de815ab4
chore: Format our loggers properly 2021-12-29 17:13:20 +01:00
dordsor21
f38859237a
Move to BinaryTags where appropriate in adapters 2021-12-29 16:00:49 +00:00
Jordan
177d731957
Add back statically-set reserved IDs for air blocks only, make it clear they're "reserved" (#1502)
* Add back statically-set reserved IDs for air blocks only, make it clear they're "reserved"
Also:
 - Ensure that reserved is never returned in GET block operations
 - "empty" thus doesn't exist in the GET update methods; remove the needless checks
 - Allow GET/SET chunks to determine their own default values for non-present blocks/sections

* Add comments
2021-12-29 16:17:20 +01:00
JOO200
5d4a2a4a0d
Use Math.floor instead of int cast 757bef1f7d2b16317ab3d18427ad22183344e28d 2021-12-29 12:42:19 +00:00
dordsor21
c28a5ee66e
Merge branch 'main' into major/2.0.0/1.18 2021-12-29 00:19:25 +00:00
dordsor21
3ec1912046
Fix tests 2021-12-28 23:22:59 +00:00
dordsor21
36857a5064
Fix #1490 2021-12-28 23:02:48 +00:00
dordsor21
f236934a39
Add get default version min/max world height to platform
- Fixes #1500
2021-12-28 22:46:19 +00:00
dordsor21
46fdceaea6
add missing annotation to Region 2021-12-28 22:05:40 +00:00
NotMyFault
596356a936
refactor: Shift FileAlreadyExistsException catch to a higher level 2021-12-27 00:00:49 +01:00
NotMyFault
0c8db1e1fe
feat: Add a bunch of new types to the flora generator 2021-12-25 19:03:30 +01:00
NotMyFault
42035bdb87
chore: Lazily prepare update checker for future job
Future versions of Fawe use a version agnostic job. This commit will remain unmerged to any other branch but warrant a working update checker.
2021-12-25 17:24:26 +01:00
NotMyFault
3b24a8ae8a
Merge branch 'main' into major/2.0.0/1.18 2021-12-25 17:20:52 +01:00
Hannes Greule
96ca83704a
fix: Backport fixing delay closing of clipboards on quit (#1493) 2021-12-25 17:18:39 +01:00
NotMyFault
28079e8129
refactor: Also deprecated IMP for DBHandler 2021-12-23 15:59:05 +01:00
Aurélien
ca5ad58f01
Fix WEManager (#1487)
* Fix WeManager?

* Fix WeManager?

* Also register WEManager if not available, like TaskManager.
2021-12-23 12:39:11 +01:00
NotMyFault
7da921e075
refactor: Deprecate IMP initializors in favor of builders 2021-12-22 20:58:23 +01:00
NotMyFault
1715f35341
refactor: Do prepared statements properly
- Update TextureUtil client jar to 1.18.1
- Limit the update checker to our domain
2021-12-22 13:10:04 +01:00
dordsor21
77802758a9
Fix parsing of build in FaweVersion 2021-12-22 11:44:37 +00:00
Jordan
6b6c94556a
refactor! Remove deprecations marked for removal that are not present in upstream (#1483) 2021-12-22 01:53:45 +01:00
NotMyFault
94b392dd39
refactor: Address a few TODO 1.18's
(cherry picked from commit 0b77932b6e46c825d78b8c7ccae2a68ad890564e)
2021-12-21 18:02:20 +00:00
NotMyFault
7453f12e66
chore: Lazily change build delimiter 2021-12-21 16:27:46 +01:00
dordsor21
e9d97fc7b1
Update version (checking) for semver 2021-12-20 21:18:26 +00:00
Jordan
d6e3c331d4
Make 1.18 to be effectively in a usable state (#1452)
* Update swathes of easy-to-update-sort-of-code.
 - Untested
 - Should compile but NMF broken something
 - Several todos:
  - biome history//better support (move to biome sections in core)
  - regen (haha lol no thanks, someone else can do that)
  - probably actually do the palette stuff that probably won't work in PaperweightPlatformAdapter

* ci: Provide basic Jenkinsfile for ghprb pipeline

* build: Update paperweight

* upstream: Update Upstream

de6fa17 Add getBrush helper for use with instanceof pattern matching (1926)

* FAWE will now load on startup

* it....works?

* Begin to allow biome edits (and fix biomes reverting to plains upon editing blocks)

* Add new blocks/block properties

* Only create biome palette if supplies is null

* Fix biome operations

* Finally get removing BlockID done (major version change allows it)

* refactor!: Drop PlotSquared v4

Fawe 2.0.0 and newer requires Java 17, PlotSquared v4 supports 1.13 and 1.14, Fawe wont work on these versions nevertheless and refuses to load due Java version incompatiblities with older versions. Newer versions can use PlotSquared v6.

* docs: Update readme

* Added and removed some comments

* Added and removed some comments

* refactor: Rename worldedit configuration

* build: Re-add 1.17 module

This the a very nasty commit

* chore: Implement missing methods

* build: Update paperweight

* upstream: Update upstream

6df194e Remove finalize, use a Cleaner instead (1943)
9843a4f Fix snapshots in 1.18 (1959)

* ci: Escape workflows

* build: Update paperweight to 1.18.1

* build: Update Paster

* Fix compilation

* Bump to 1.18.1

* Do both 1.18 and 1.18.1

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

* Fix single-block lookups

* Reserve ordinals 0 through 3 for air/"reserved"

* Create block palette data with values

* Fix classpath for testing for starlight

* Correctly use block rather than sky light layer [not used in paper]

Co-authored-by: NotMyFault <mc.cache@web.de>
Co-authored-by: Matt <4009945+MattBDev@users.noreply.github.com>
2021-12-20 21:12:04 +00:00
dordsor21
c697eb8d41
Merge branch 'main' into major/2.0.0/1.18 2021-12-20 20:28:15 +00:00
Owen1212055
781bfc542f
fix: Properly delete ChangeSets on history clear (#1413)
Fixes #1347

Co-authored-by: Jordan <dordsor21@gmail.com>
Co-authored-by: Alex <mc.cache@web.de>
2021-12-06 14:31:46 +01:00
NotMyFault
1f975ac044
Update templates, address JEP deprecations and place a few TODOs 2021-11-30 21:30:46 +01:00
NotMyFault
e296a329c2
Port initial paperweight classes to 1.18 folder structure 2021-11-30 12:35:34 +01:00
NotMyFault
0b45248b8c
style: Use minimized version output 2021-11-29 22:15:41 +01:00