Commit Graph

149 Commits

Author SHA1 Message Date
d3ff4131a3 Fix incorrect light array reference.
Possibly fixes #531 and #535
2020-07-24 20:21:05 +01:00
3bc692ff11 Part 1 of upstream merge and format 2020-07-13 22:50:59 -04:00
f1d4104480 Bunch of changes to help masks 2020-07-02 22:09:12 +01:00
18c9da372c GetBlocks should default to air not reserved 2020-07-02 18:16:15 +01:00
6be429cc96 Lighting:
- bring fixes to 1.16
- Fix for all lighting where it only set sky lighting if not present, even if it was trying to set block lighting (unlikely to have caused issues as block lighting seems always to be present, but wrong nonetheless)
2020-07-01 12:55:58 +01:00
3b19738ea0 Merge branch '1.15' into 1.16
# Conflicts:
#	worldedit-bukkit/src/main/java/com/boydti/fawe/bukkit/adapter/mc1_16_1/BukkitGetBlocks_1_16_1.java
#	worldedit-bukkit/src/main/java/com/boydti/fawe/bukkit/wrapper/AsyncWorld.java
#	worldedit-bukkit/src/main/java/com/boydti/fawe/bukkit/wrapper/state/AsyncDataContainer.java
2020-07-01 12:47:04 +01:00
3f3c49c0a8 Looks like working block setting and removal 2020-07-01 12:41:20 +01:00
f84958957c Fix various lighting issues
fixes #496
possibly fixes #497
2020-06-30 13:44:26 +01:00
b59b95c282 Cherry-pick WNA, minor changes. 1.16 VERY WIP
First noticed incident of operations ruining ChunkSections. Do not build and use this unless you're testing.

Rushed some of the changes, gotta sleep. Would be nice to get a review of this one from @mattbdev and @dordsor21
2020-06-29 22:05:41 -04:00
f2bc8d86fc Work towards 1.16 compatibility
This commit will allow the branch to build properly but the plugin will not function properly due to the lack of a proper adapter implementation. Proceeding will require the implementation of the SideEffects system from upstream (865c3a24d2 (diff-8fd33296e427c87d0296ad7f3ccc050a)).
2020-06-26 19:08:45 -04:00
aab10adb79 Fixed all but one remaining API changes in 1.16.1
No testing has been performed yet.
2020-06-25 20:57:06 -04:00
b7debce4d4 1.16.1 Prep work 2020-06-25 20:29:09 -04:00
238c56a3c6 Revert "Revert matt's changes"
This reverts commit bfcc6184ad.
2020-06-13 14:41:36 -04:00
bfcc6184ad Revert matt's changes
Let's not break Fawe, thanks
2020-06-13 18:48:57 +02:00
9f6e0ebd5c Minor changes to NMS logic 2020-06-12 21:45:48 -04:00
75153d8da8 Fix getLightOpacity 2020-05-27 17:25:03 +01:00
bdc14c10c7 Fix relight and removelight (#475)
* Start work on lighting engine (does not build)

* Implement getLighting

* Setting, flushing light etc works. Getting light should be working..?

* Better queue/chunk handling

* Use correct location for lighting update

* Correct set location, remove debug

* cleanup a little

* Fix fixlight

* Apply to all versions for the numpties

* Remove lighting extent if not using

* Actually bitmask blocks when setting in chunks

* Initialise Maps and Dequeues with inital size

* format

* Documentation maybe
2020-05-27 11:45:08 +01:00
1f898cd0d1 Negate "hasCollision" for isTranslucent() also for 1.15.0 and 1.14 2020-05-25 19:00:16 +01:00
d9240c5626 Negate "hasCollision" for isTranslucent() 2020-05-25 19:00:16 +01:00
a6514f8a78 Ultimately the Striped locks will have no affect, even if kinda cool. 2020-05-20 07:58:14 +01:00
fd3604beba replace synchronisation with Striped access semaphore locks 2020-05-18 16:52:33 +01:00
31cc5e0b60 Synchronise on the nmsWorld so we're not attempting to load two chunks at the same time.
Possibly fixes #471
2020-05-18 16:04:10 +01:00
5be11c541b Put the synchronisation higher up the food chain 2020-05-14 22:32:32 +01:00
3a7c23be45 Fix #443
Temp as it's performance-degrading, but works well enough for now
2020-05-14 22:10:09 +01:00
35169230ad Sort of fix biome getting
It seems to want to put random blocks where the biome isn't
2020-05-14 16:27:24 +01:00
5225099ec0 Fix biome setting in 1.15 2020-05-14 16:17:29 +01:00
be58cd42ac Add option to disable ticking existing blocks when not fastmode 2020-05-11 16:09:31 +01:00
36faf107e6 Allow fastmode to be used in a lot more places
- Option to stop fastmode from bothering to fix existing ticking blocks
2020-05-11 15:36:52 +01:00
0dee452e1a Don't attempt to set field on null ChunkSection 2020-05-09 17:42:40 +01:00
b1f1c0f4f0 Possible fix for #331
- Should ensure the server doesn't tick the chunksection while we're editing it
- Basically using the old issue with FAWE breaking block ticking by setting this to zero :)
2020-05-09 16:23:38 +01:00
56c720914e Settings.IMP is terrible. Don't initialise it thousands of times. 2020-05-08 18:17:47 +01:00
c757b01803 By default only allow existing blocks to tick.
- Revert back to default FAWE behaviour where placed blocks do not tick by default (until a restart, or another edit is done in the same chunksection without changing the block)
2020-05-08 16:16:08 +01:00
56972ee40b Trim performance (#451)
* Increase performance slightly when trimming.
If the chunk section is all one blocks (common in plotworlds) it'll be a nice little boost.

* Cache whether blocks are ticking or not. Greatly reduces the time required to create a palette

* collapse 5 lines to 2.

* Also apply to 14 and 15 for the numpties

* Cleanup
Actually ignore the exception - remove my debug print.
Remove double semi-colon

* Apparently 1.14/15 matter too still.
2020-05-07 23:00:13 +01:00
0ca81e9d67 Fix FAWE killing chunk ticks. Also allow ticking for set blocks. (#439)
* Fix FAWE killing chunk ticks. Also allow ticking for set blocks.

* Reduce for-loop to being one loop in createPalette

* set the value in the set array and break so we don't continue onwards in the set's ordinal switch statement
2020-05-03 17:50:09 +01:00
5fb18259d5 Merge remote-tracking branch 'origin/1.15' into 1.15 2020-04-30 16:27:08 -04:00
ef3642d521 Small spring cleaning
I changed really small bits and pieces of code. If you have questions just comment and I'll answer them.
2020-04-30 16:26:52 -04:00
9869cf09c6 Apply fda7d00747 to other versions so numpties that use old versions for no reason stop complaining too 2020-04-30 15:14:59 +01:00
f9a40599fb Fix typos 2020-04-29 19:36:34 +02:00
fda7d00747 A more verbose fix to #329 and similar issues.
- Re-read chunksections the first time they're "loaded" for an operation
 - Reset the chunksection if there are block changes when setting blocks via reflection
 - These are maybe gonna affect performance a bit? Idk. Seems to be alright for me
 - These are maybe gonna make more issues? Yeah maybe, but I couldn't find any
2020-04-29 18:17:21 +01:00
600a1a5daa Implement previously unsupported methods in DelegateLock 2020-04-29 11:29:02 -04:00
c478dbd249 Backport changes 2020-04-21 23:58:14 +02:00
8a19c4c38c Don't mark the chunk as dirty. 2020-04-21 15:40:53 +02:00
2c85ff1673 Properly remove tile entities in BukkitGetBlocks_1_15_2 2020-04-21 15:23:23 +02:00
16df4abd18 Reflection field name changes
Old ones were outdated. Brush visualization is still WIP and can result in client being kicked from the server for bad packets.
2020-04-01 00:20:25 -04:00
6e1cb4cfbc Remove more useless messages 2020-03-31 19:39:37 -04:00
a6a4400317 Port fixed for #389 from 1.15.2 adapter to other adapters. 2020-03-31 10:26:23 +01:00
a49a09a042 Added clarification for debugging message because of people thinking it is an error. 2020-03-20 20:04:31 -04:00
1df5853f33 Remove unnecessary reflection 2020-03-17 22:27:41 -04:00
14d2c9a5c3 Update BlockStateIdAccess and added a debug message 2020-03-10 17:22:53 -04:00
c52db75976 Delete unused file 2020-02-25 18:26:04 -05:00