Commit graph

1748 commits

Author SHA1 Message Date
Jake Potrebic
4567f41500 Updated Upstream (CraftBukkit) (#8680)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

CraftBukkit Changes:
2ed3e3e6e SPIGOT-7210: Fix structures in custom worlds
585ab5ba1 SPIGOT-7207: WorldCreator creates world as super flat even when normal is specified
2022-12-15 17:16:34 -08:00
Jakub Žáček
fab251199d Add Sneaking API for Entities (#8485) 2022-12-15 20:43:14 +01:00
Jake Potrebic
b5ab281c29 Deprecate TargetBlock/EntityInfo and assocated methods (#7381) 2022-12-15 09:10:03 -08:00
Jake Potrebic
9eb6b1db93 Add BlockLockCheckEvent (#7840) 2022-12-15 08:49:49 -08:00
Nassim Jahnke
dd2051ae52 Remove guardian beam render issue workaround
Messing with game time sent to the client isn't worth the trouble whenever it may be used by the client now and in the future for such a small issue. Mojang, plz fix
2022-12-15 14:19:09 +01:00
Jake Potrebic
e28eb9ab05 Fix explosion yield with new gamerules (#8674) 2022-12-14 20:01:31 -08:00
Jake Potrebic
74e9dbfa19 Improve some logging and errors (#8673) 2022-12-14 19:54:43 -08:00
Jake Potrebic
96d7b7b6e4 Add more breakNaturally functionality (#7379) 2022-12-14 19:37:16 -08:00
Jake Potrebic
a0b62c40db Remove deprecated event warning for inventory result event (#8672) 2022-12-14 15:09:11 -08:00
Jake Potrebic
437103e45e Fix inconsistencies in dispense events regarding stack size (#8653)
* Fix inconsistencies in dispense events regarding stack size

The javadocs for BlockDispenseEvent suggest the ItemStack is a single
item which is being dispensed. Before this fix, sometimes it was the whole
stack before a single item had been taken. This fixes that so the stack size
is always 1.

* Ensure stack size is correct in minecart and armor dispense behaviors
2022-12-14 13:05:11 -08:00
Jake Potrebic
a4112a5c50 Updated Upstream (Bukkit/CraftBukkit) (#8663)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
f50ad1f8 PR-798: Add PrepareGrindstoneEvent and refactor related events to use PrepareInventoryResultEvent
0cac7963 SPIGOT-7204: Add TeleportCause#DISMOUNT
b4dd47b0 SPIGOT-7202: Deprecate removed door effects

CraftBukkit Changes:
ab1586c2f PR-1123: Add PrepareGrindstoneEvent
b402824ea SPIGOT-7204: Add TeleportCause#DISMOUNT
06a6a1012 PR-1121: Add unit test for spawn egg meta
c18668be3 SPIGOT-7192: Call PlayerInteractEvent with Action.LEFT_CLICK_AIR if the entity interacted is hidden to the player
47124f639 Increase outdated build delay
645993470 SPIGOT-7201: Spawner ItemMeta not working as expected
2022-12-13 21:03:57 -08:00
Jake Potrebic
e849888abb Fix fire charge not being consumed igniting a creeper (#8652) 2022-12-13 09:23:05 -08:00
SoSeDiK
45821f2511 Fix locateNearestBiome nullability check (#8662) 2022-12-13 17:01:54 +02:00
EpicPlayerA10
851a363fad Fix death message containing empty string (#8656)
Resolves: #8654
2022-12-13 13:24:59 +01:00
Jake Potrebic
2c4d034313 Fix items equipped on AbstractHorse losing NBT (#8647)
* Fix items equipped on AbstractHorse losing NBT

* squash later mc fix into vanilla patch
2022-12-11 15:22:56 -08:00
Jake Potrebic
3a0963092a Add the non-flammable wood item tag (#8648) 2022-12-11 13:01:18 -08:00
Noah van der Aa
2b86179e7e [ci skip] Correct chat preview removal version in javadoc (#8646) 2022-12-11 19:34:31 +01:00
Jake Potrebic
e74fb06010 Deprecate isPreview method in decorate events (#8645) 2022-12-11 09:55:39 -08:00
Jason Penilla
cf2bb8381b [ci skip] Remove non-functioning patch 2022-12-10 21:40:18 -07:00
Jake Potrebic
63e191936d Add Position (#7639)
* Add Position

* move Position patch to start
2022-12-10 16:50:32 -08:00
Jake Potrebic
09c45d4cab Fix empty effect clouds from lingering potions (#8641) 2022-12-10 14:52:37 -08:00
Lulu13022002
8b951a41ae Don't show particles when splash events are canceled (#8637) 2022-12-10 22:27:36 +01:00
Jake Potrebic
f976ec6b19 Fix MapLike Codec missing key 'selector' (#8634)
* Fix MapLike Codec missing key 'selector'

* Make sure a new instance is created each time
2022-12-10 09:04:27 -08:00
Nassim Jahnke
a29f26bb86 [ci skip] Fix leaf'd patch names 2022-12-10 17:42:50 +01:00
Nassim Jahnke
169ac46b2b Readd BlockBehavior inlining patch 2022-12-10 17:24:01 +01:00
Lulu13022002
2f97008db9 Fix chunksnapshot biome getter (#8639) 2022-12-10 14:11:39 +01:00
Lulu13022002
ef47433fdb Add eating regain reason for Camels (#8638) 2022-12-10 14:07:35 +01:00
Owen1212055
e383b8e15d Rabbit API (#8627) 2022-12-09 19:56:13 -05:00
Jake Potrebic
ad6b5121b7 Properly identify golem spawn reason (#8635) 2022-12-09 16:37:03 -08:00
Jake Potrebic
7332b8c2c4 Readd improve/fix EntityTargetLivingEntityEvent (#8630) 2022-12-09 03:30:55 -08:00
Jake Potrebic
7c8a0e8e83 Add new 1.19.3 fires of EntityInsideBlockEvent (#8629) 2022-12-09 02:46:47 -08:00
Jake Potrebic
ff9d51df21 last instrument fix, I promise 2022-12-09 02:03:06 -08:00
Jake Potrebic
d1e41fdc47 couple more instrument/note fixes 2022-12-09 01:49:15 -08:00
Jake Potrebic
a4bd0cf67b fix Instruments 2022-12-09 01:34:39 -08:00
Jake Potrebic
2c494f0af9 Mark experimental api as such (#8628) 2022-12-09 01:13:22 -08:00
Owen1212055
fcb3cfa2f5 Update adventure (#8625) 2022-12-09 04:11:28 -05:00
Jake Potrebic
5e31c8a26b fix method rename issue in Camel 2022-12-08 18:17:06 -08:00
Jason Penilla
449f63be8c Account for splash water bottles now extinguishing entities (#8622)
* Account for splash water bottles now extinguishing entities

* improvements and javadocs

* reorder patches

* rename event to WaterBottleSplashEvent

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
2022-12-08 17:33:22 -07:00
Owen1212055
d7dbb07235 Deprecate PluginLoader and impls (#8619) 2022-12-08 16:27:37 -05:00
Jake Potrebic
6b6282af03 fix a few structure seed configs 2022-12-08 12:15:18 -08:00
Jake Potrebic
759e2acf0e readd missing structure set seeds patch 2022-12-08 11:06:54 -08:00
Jake Potrebic
40bdabb571 properly handle xray bypass perm 2022-12-08 10:35:33 -08:00
Jake Potrebic
6f65677ca2 check now succeeds 2022-12-08 10:23:12 -08:00
Jake Potrebic
b344c04a4a fix some tests and DoNotUse violations 2022-12-08 09:06:14 -08:00
Nassim Jahnke
c29c901ae8 Readd fixes for SpawnReason API patch 2022-12-08 17:51:06 +01:00
Jake Potrebic
58a098403c fix ChatProcessor 2022-12-08 08:32:29 -08:00
Nassim Jahnke
461e31b4f8 Update Velocity modern forwarding reading 2022-12-08 12:16:44 +01:00
Nassim Jahnke
a95d2378e7 Fix bad AT 2022-12-08 12:00:10 +01:00
Nassim Jahnke
27fddd665d Updated Upstream (Bukkit/CraftBukkit/Spigot)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
dea9ce0a SPIGOT-7198: Add Sittable interface to Camel

CraftBukkit Changes:
eecb4c0dc SPIGOT-7196: Exception loading alternate worlds
0ff61e8fa SPIGOT-7198: Add Sittable interface to Camel
676441aac PR-1121: Handle additional missing SpawnEggs in MetaSpawnEgg
e85280e02 Handle missing SpawnEggs in MetaSpawnEgg

Spigot Changes:
d90018e0 SPIGOT-7199: NPE loading or creating world with custom chunk generator
2022-12-08 11:53:14 +01:00
Jake Potrebic
06018dbedf fix some startup issues 2022-12-08 00:52:08 -08:00
Jake Potrebic
181b2c7e46 fix more compile issues 2022-12-07 22:11:20 -08:00
Jason Penilla
a0a9b9291a more compile fixes 2022-12-07 21:24:59 -07:00
Jason Penilla
6e1deb99aa compile fixes 2022-12-07 20:24:00 -07:00
Noah van der Aa
d654558a4e More 1.19.3 registry fun (#8618) 2022-12-08 00:49:41 +01:00
Owen1212055
3a5be0bbe7 Properly resend entities (#8617) 2022-12-07 18:11:44 -05:00
Nassim Jahnke
be2259ea83 Fix MCVersions 2022-12-07 23:29:30 +01:00
Noah van der Aa
8208e3d1c4 Add missing spawn eggs: Electric Boogaloo (#8616) 2022-12-07 23:10:51 +01:00
Nassim Jahnke
3d2c9cd064 Almost all patches 2022-12-07 23:05:32 +01:00
Nassim Jahnke
580e157417 More patchidy patched patch patches 2022-12-07 22:57:15 +01:00
Noah van der Aa
6513000165 Fix a handful of 1.19.3 compile issues (#8615) 2022-12-07 22:36:56 +01:00
Nassim Jahnke
bbd997db62 More patchidy patched patches 2022-12-07 22:35:34 +01:00
Nassim Jahnke
810c0219d9 More patchy patched patches 2022-12-07 22:05:01 +01:00
Nassim Jahnke
00dec09758 Patching patched patched patches 2022-12-07 21:16:54 +01:00
Nassim Jahnke
eac356d807 Patching patched patches 2022-12-07 20:22:28 +01:00
Nassim Jahnke
d4e6ee3d12 Moar, fix API 2022-12-07 19:52:24 +01:00
Nassim Jahnke
ee75b5dc2d Patching patches 2022-12-07 19:32:25 +01:00
Nassim Jahnke
b748ab8e70 Patches 2022-12-07 18:53:34 +01:00
Nassim Jahnke
d0386f21e8 First server patches 2022-12-07 18:08:55 +01:00
Nassim Jahnke
b7dd55ce72 API patches 2022-12-07 17:46:46 +01:00
Jake Potrebic
bea0e28dc4 Add missing Fluid type (#8608) 2022-12-06 10:41:04 -08:00
Noah van der Aa
1ae3999c8f Limit pet look distance (#8612) 2022-12-06 19:10:58 +01:00
Shane Freeder
ec00900b8b Fix dumplisteners missing folder creation 2022-12-06 04:02:44 +00:00
Yannick Lamprecht
c57f86c7ab Player Entity Tracking Events (#4722) 2022-12-03 23:46:38 +01:00
Jake Potrebic
31ec776281 Updated Upstream (Bukkit/CraftBukkit) (#8604)
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
38866413 SPIGOT-6765: Pass WorldInfo, Random and coordinates to ChunkGenerator should methods

CraftBukkit Changes:
f3dab3a48 SPIGOT-7191: TNT minecart explosions crash the server
b5aa0bed9 SPIGOT-7184: ExplosionPrimeEvent not called for ExplosiveMinecart
e7aab5493 SPIGOT-6765: Pass WorldInfo, Random and coordinates to ChunkGenerator should methods
2022-12-03 10:19:09 -08:00
Bjarne Koll
ce991b96eb Fully deserialise persistent anger post async load (#8560)
The modified patch prevents entity loading off the main thread when
entities are initially loaded.

However, the initial loading of an entity is not the only time the
Entity#readAdditionalSaveData method is called. Commands like /data also
invoke the method (through Entity#load) to update an entities data
without completely re-creating it.

This however breaks with the current patch, as the patch moves parts of
the entity lookup for persistent anger deserialisation into the first
tick of an entity (which obviously is only called once and hence not
re-run when an already ticking entity is modified as laid out above).

This change actively runs the now split logic for deserialisation again
if the entity has already ticked its first tick. This way, initial
deserialisation is still split into one off thread and the first tick
parts, but following main thread deserialisations can happen completely
inside Entity#readAdditionalSaveData is called.
2022-12-02 18:09:41 +01:00
Jake Potrebic
b9401e6d3c Sync offhand slot in menus (#7341) 2022-12-01 13:01:49 -08:00
Jason Penilla
5756691b5a Fix whitespace error in recent patch 2022-11-28 11:10:26 -07:00
Lulu13022002
08bcef4859 Handle legacy quirk in the console formatter (#8434) 2022-11-28 14:41:29 +01:00
Denery
2402c125aa Fix preemptive connection dropping during shutdown process (#8546) 2022-11-27 20:20:31 +03:00
sandtechnology
e9b9c0b332 Fix packet duplicating at some points (#8566)
Due to the weakly consistent of ConcurrentLinkedQueue iterator, at some points, packet will be resent twice times or more, causing some weird behaviors (e.g. kicked for illegal movement since the same ClientboundPlayerPositionPacket was sent two times). This changes for the patch add a flag for marking if the packet was consumed to prevent such issue and ensure consistently of the packet queue.
2022-11-28 00:36:35 +08:00
Jason Penilla
59d8df6cba Add /paper dumplisteners tofile and increase detail of command output (#8592) 2022-11-26 10:36:11 -07:00
Ján Villim
25196237b1 Added ability to control player's insomnia and phantoms spawning (#6500) 2022-11-26 17:59:04 +01:00
Owen1212055
91869b8753 Schoolable Fish API (#7089) 2022-11-25 21:21:40 -05:00
SoSeDiK
c30dcbbc4c Allow using degrees for ArmorStand rotations (#7847) 2022-11-26 03:42:30 +02:00
Noah van der Aa
0d81f1e394 Friction API (#6611) 2022-11-26 01:23:12 +01:00
Kezz
898dd9224a Add Tick TemporalUnit (#5445) 2022-11-25 21:05:42 +00:00
Jake Potrebic
06be0d0b4d Add displayName methods for advancements (#8584) 2022-11-24 23:05:48 -08:00
Jake Potrebic
26993f7801 ItemStack damage API (#7801) 2022-11-24 22:52:00 -08:00
Jake Potrebic
59db8e8bc9 Fix async entity add due to fungus trees (#7626) 2022-11-24 22:32:29 -08:00
Jake Potrebic
86b0932a3b Fixes potential issues arising from optimizing getPlayerByUUID (#8585) 2022-11-24 22:22:19 -08:00
Amy
9cbb983d0d Fix chest relooting mechanics (#8580) 2022-11-24 23:21:40 +00:00
Warrior
7f4f5f8f3b Add /paper dumplisteners command (#8507)
Co-authored-by: Jason Penilla <11360596+jpenilla@users.noreply.github.com>
Co-authored-by: TwoLeggedCat <80929284+TwoLeggedCat@users.noreply.github.com>
2022-11-23 23:28:38 +01:00
Lulu13022002
3375abab49 More vanilla friendly methods to update trades (#8478) 2022-11-23 22:38:49 +01:00
Jake Potrebic
48d31a56e9 Add api to resolve components (#7648) 2022-11-22 20:53:50 -08:00
Shane Freeder
3c0aa837c1 Fix Varint21FrameDecoder cached length buf usage 2022-11-22 17:50:31 +00:00
Lulu13022002
944be7b031 Avoid a cubed max search distance for POIs (#8576)
The max search distance used to get the closest Poi data on X/Z axis is cubed
instead of squared (one time in the parameter and another time in the function)
for almost all search.
Generally this has been hidden by another check that already does a pre
distance check between the poi pos and the source pos for individual
component but the issue still happens for diagonal distance search.
Discovered by Samsuik
2022-11-21 16:02:21 +01:00
Jakub Žáček
b36d2af7d5 Add Player Warden Warning API (#8470) 2022-11-20 19:53:58 +01:00
Jake Potrebic
b121c04895 Moving ATs from the at file to individual patches (#8573) 2022-11-19 15:53:20 -08:00
Noah van der Aa
14d69488ad Strip coordinates from lodestone compasses (#8561) 2022-11-19 22:41:09 +01:00
Owen1212055
0bb4b6ead5 Add more collision code skipping logic (#7581) 2022-11-19 16:14:19 -05:00
Lulu13022002
f07cda9bb9 Sync chunk load command improvements (#8554) 2022-11-19 20:10:13 +01:00
William Blake Galbreath
7ad5dcb810 Fix MC-179072 (#8421) 2022-11-19 12:23:31 -06:00
Melncat
da7eb6b942 Fix MC-121048 (#8429)
This moves the setHealth call to below the recordDamage call to prevent
recordDamage from clearing the CombatTracker, since recordDamage will
clear the CombatTracker if the entity is dead. This fixes death messages
such as the "doomed to fall" messages.
2022-11-18 20:04:52 -08:00
Lulu13022002
72369d4f40 Reorder bukkit damage source entity for explosion (#8553) 2022-11-19 03:14:52 +01:00
Jake Potrebic
a81c97eafe Fix/improve Affects Spawning API (#7329) 2022-11-15 11:15:01 -08:00
Jake Potrebic
f93eb6e135 update yarn param mappings (#8563) 2022-11-12 12:57:41 -08:00
braindead
97cb10205d fix MC-252817 (green map markers do not dissappear) (#8545) 2022-11-12 14:16:25 -05:00
Jake Potrebic
1221fdbc95 ensure reset EnderDragon boss event name (#8562) 2022-11-12 10:34:14 -08:00
Owen1212055
af85b6071c Cleanup reputation API + back with an EnumMap instead of array (#8258)
Resolves: #7142
2022-11-12 12:41:22 -05:00
Noah van der Aa
da071ba78f Show exception when headless JRE detection is triggered (#8559) 2022-11-12 13:09:54 +01:00
Owen1212055
36d8f327e8 Add PrePlayerAttackEntityEvent (#8369)
Allows you to cancel player event attacking, preventing things like attack sounds from being played.
2022-11-09 22:05:58 -05:00
Jake Potrebic
ac7f94e4cf Updated Upstream (CraftBukkit) (#8548) 2022-11-09 16:05:46 -08:00
Shane Freeder
435cc8ebd8 Cleanup misc import from last commit 2022-11-06 22:46:23 +00:00
Shane Freeder
f5e9a14a25 Prevent compass from loading chunks 2022-11-06 22:37:34 +00:00
Owen1212055
0ea0d39edf Properly resend entities (#7041) 2022-11-05 14:50:16 -04:00
Jason Penilla
d8be0e795b Update Commodore modifications (#8542)
* Handle ldc insn for getOriginalOrRewrite in Commodore

* Remove fastutil rewrite

It's no longer relocated upstream
2022-11-04 22:16:57 -07:00
Jake Potrebic
2f0e0c5f2b Fix Advancement#getDisplay() api break (#8541) 2022-11-04 15:59:15 -07:00
Astro Angelfish
bf532ab0fb [ci-skip] Rename Paper stop tp Paper end. (#8539) 2022-11-05 00:08:01 +08:00
Jake Potrebic
a5e916fc00 Remove old redundant fix (#8530) 2022-11-03 14:03:31 -07:00
Lulu13022002
4400eb6600 Call PlayerLaunchProjectileEvent for trident (#8027) 2022-11-03 19:43:50 +01:00
Shane Freeder
857ece0812 Fix setting difficulity inside of API (Fixes #8533)
Vanilla moved some logic around setting the world difficulty which
was not adopted for inside of upstream properly, this addresses another
such case
2022-11-01 18:29:52 +00:00
Jason Penilla
bfdafa934b Build updates 2022-10-31 15:25:30 -07:00
Denery
ffceefa32f Fix EntityCombustEvent cancellation issues (#8529) 2022-10-31 19:31:40 +03:00
Jake Potrebic
13442cd5c9 Updated Upstream (Bukkit/CraftBukkit/Spigot) (#8515)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
9a4de097 SPIGOT-7171: Ability to get the IP/hostname players are requesting status of

CraftBukkit Changes:
f43634ae4 SPIGOT-7170: Cannot set slots in custom smithing inventory
48f3a2258 SPIGOT-7171: Ability to get the IP/hostname players are requesting status of
30e31b4d1 SPIGOT-7177: Certain blocks don't call BlockCanBuildEvent
982364797 SPIGOT-7174: Avoid adding air to CraftMetaBundle

Spigot Changes:
6198b5ae PR-122: Add missing parentheses to pumpkin and melon growth modifier
1aec3fc1 Rebuild patches
2022-10-30 19:44:25 -07:00
Noah van der Aa
f40ba18fd0 Fix pumpkin growth modifier (#8517) 2022-10-30 13:27:37 +01:00
Owen1212055
4fad96576f Deprecate unused VehicleEntityCollisionEvent methods (#8498) 2022-10-29 13:18:17 -04:00
William Blake Galbreath
d786bfda5c Fix MC-147659 (#8423) 2022-10-27 19:53:16 -05:00
Hannes Greule
878600ebbc Fix wrong descriptor in ASMEventExecutorGenerator (#8506) 2022-10-28 02:27:33 +02:00
Jason Penilla
3b7ad4bb6f Make CommandSyntaxException implement ComponentMessageThrowable (#8513) 2022-10-27 10:10:28 -07:00
Jason Penilla
731f32f889 Fix EntityArgument suggestion permissions to align with EntitySelector#checkPermissions (#8511) 2022-10-26 18:31:55 -07:00
Jake Potrebic
f8cf06b774 Track projectile source for fireworks from dispensers (#8044) 2022-10-26 17:44:28 -07:00
Jake Potrebic
219d159e4d Fix a bunch more forceDrops for dropping items (#8095) 2022-10-26 17:32:03 -07:00
Noah van der Aa
f84fb32dc5 Add allow server listing & text filtering client options (#7595) 2022-10-27 01:09:03 +02:00
Lulu13022002
0af5c64201 Fix new block data in EntityChangeBlockEvent for silverfish when mobGriefing isn't enabled (#8099) 2022-10-27 00:05:15 +02:00
Spottedleaf
1e44e31be7 Add dirty flag to chunk tick lists
For whatever reason, vanilla does not mark the chunk as
dirty when changing its tick lists.

We also have it return dirty if the time since the last
save has changed, since it would affect the tick offsets
in the ticklist.
2022-10-24 19:48:19 -07:00
Spottedleaf
11bb97e66c Fix incorrect handling of mustNotSave
CB used the dirty flag to construct the chunk unload event,
but then sets mustNotSave to the inverted value of the event
after calling the event without considering that the chunk may
actually be brought up to loaded status again later. Then, CB
overrides the isUnsaved method of LevelChunk to additionally
use mustNotSave.

Thus, if the chunk is not marked dirty when unloading, the
mustNotSave value will be set to true. Then, once the chunk
is reloaded and edited the dirty flag will be set. However,
when unloading the chunk finally, the isUnsaved method
will return false due to mustNotSave being true. Thus, the
chunk will never be saved.

To fix these issues, no longer make mustNotSave override
isUnsaved and always set the save flag for the chunk unload
event.

This issue started popping up recently due to the recent
change to mark chunks as not dirty after saving them, which
increased the chance of the save issue occurring in the first
place.
2022-10-24 19:23:46 -07:00
Jason Penilla
b9481cae74 Move classes added to net.minecraft.server to paper packages (#8500) 2022-10-24 12:43:46 -07:00
evan
95bd943ca3 Only limit global sounds to same world if limiting radius (#8499) 2022-10-23 13:52:40 -05:00
Jake Potrebic
bac7ba4c5a Updated Upstream (Bukkit/Spigot) (#8445) 2022-10-23 10:41:34 -07:00
Spottedleaf
0aa7d1a07f Mark chunks as saved after saving them
Prevents re-saving them again later.
2022-10-23 09:09:18 -07:00
Owen1212055
646d59a575 Ignore impossible spawn tick (#8493)
Co-authored-by: dannyball710 <dannyball710@gmail.com>
2022-10-23 00:45:07 -04:00
Owen1212055
c1aac9ca35 Don't fire EntityToggleSitEvent on deserialization & reorder some api patches (#8495) 2022-10-22 22:55:28 -04:00
Owen1212055
fc19cbd800 Add Moving Piston API (#7019) 2022-10-22 20:37:37 -04:00
SoSeDiK
e7b3fba8e6 Add EquipmentSlot convenience methods (#8477) 2022-10-23 02:50:12 +03:00
uku
9e743bccff Add config setting for grindstone overstacking (#8156) 2022-10-23 01:25:17 +02:00
vytskalt
201ba4d328 Add fire-tick-delay option (#8037) 2022-10-23 01:57:09 +03:00
IEatBeans
634f212bd5 Added EntityToggleSitEvent (#7579)
* Added EntityToggleSitEvent Patches

* Updated event phrasing, fixed Boolean not being primitive, pandas now fire event, and event is defined and called in 1 line

* Updated event phrasing, fixed Boolean not being primitive, pandas now fire event, and event is defined and called in 1 line

* Added EntityToggleSitEvent Patches

* Added EntityToggleSitEvent Patches

* Added EntityToggleSitEvent Patches
2022-10-22 15:20:52 -07:00
thelooter
28e6d9fd86 Add MaterialTags for the different Types of Tools (#8049)
* Add MaterialTags for the different Types of Tools

* Add Netherite Tools Tag
2022-10-22 23:51:34 +02:00
Lukas Alt
6ffb491076 Optimized dirt and snow spreading (#5124)
* Optimized dirt and snow spreading

* Add optimization to bukkit event call

* Clarify var names

Co-authored-by: Owen1212055 <23108066+Owen1212055@users.noreply.github.com>
2022-10-22 20:13:59 +02:00
Lukas Alt
d68e096dd8 fixed entity vehicle collision event not called (#5053) 2022-10-22 19:09:45 +02:00
Noah van der Aa
95e37fca48 Detect headless JREs (#8491)
Crashes caused by the missing AWT dependency come up in the support channels fairly often.
This patch detects the missing dependency and stops the server with a clear error message,
containing a link to instructions on how to install a non-headless JRE.
2022-10-22 18:57:21 +02:00
Noah van der Aa
ddc8e1fd7c Load Allay duplication cooldown as a long (#8410)
It is saved as a long, and the API exposes a long, so loading it as an int may cause issues like overflows.
2022-10-22 16:16:24 +02:00
Jason Penilla
13f7207665 Add stacktrace deobfuscation in more places (#8484) 2022-10-18 19:21:07 -07:00
Spottedleaf
03245caed0 Fix inconsistent isChunkLoaded calls
When we update the chunk state to border, it should be
the case that isChunkLoaded returns true and that
getChunkIfLoadedImmediately returns a non-null value.
Now add the chunk to the loaded map before making any
callbacks after updating to border state.
2022-10-18 08:11:23 -07:00
Nassim Jahnke
2f1aaaa85c Fix another case of missing chat headers 2022-10-18 10:20:35 +02:00
Melncat
cd71f3c427 Add LivingEntity knockback API (#8479) 2022-10-18 00:33:58 -07:00
Jakub Žáček
154762a316 Add converted Slot number to PlayerInventorySlotChangeEvent (#8482) 2022-10-18 09:32:22 +02:00
SoSeDiK
50c3dccb29 Add LivingEntity#swingHand(EquipmentSlot) convenience method (#8456) 2022-10-16 14:49:56 +03:00
Jakub Žáček
fc419cfa50 Fix package for PlayerInventorySlotChangeEvent (#8475)
Co-authored-by: Jakub Zacek <dawon@dawon.eu>
2022-10-16 09:49:47 +02:00
19MisterX98
a35758c72d FIx bedrock patterns (#8474) 2022-10-16 00:34:10 +02:00
Lexi
11281d0789 Avoid usages of RecipeChoice#getItemStack() (#8453)
Replaces some internal usages of this method with RecipeChoice#test(ItemStack) and deprecates every other method still utilizing this legacy method.
2022-10-15 15:20:12 -04:00
SoSeDiK
254a07415d Allow changing bed's 'occupied' property (#8458) 2022-10-14 11:37:01 +03:00
Lulu13022002
c0e86f0599 Avoid cycle deprecation (#8466) 2022-10-13 13:52:04 +02:00
Lulu13022002
e827d176c4 Update settings directory path in exceptions (#7968) 2022-10-13 13:38:06 +02:00
SoSeDiK
683149f9a1 Elder Guardian appearance API (#8455) 2022-10-13 13:26:51 +03:00
Shane Freeder
c0e803bfd2 Make CraftMinecartTNT public
adding the getHandle method causes some issues with things like ProtocolLib
due to the expectation that all classes which provide a getHandle method
are public.
2022-10-12 16:10:52 +01:00
Jake Potrebic
c8d979234f Fix a classloading issue in tests (#8459) 2022-10-11 20:05:28 -07:00
Jason Penilla
420e6ac365 Fix stacktrace in server tests 2022-10-11 16:52:49 -07:00
Jakub Žáček
07f0c9755b Add PlayerInventorySlotChangeEvent (#7321) 2022-10-11 23:49:10 +02:00
Owen1212055
e7535118d9 Add missing Entity + Projectile API (#7632) 2022-10-11 17:04:26 -04:00
SoSeDiK
9ff21585db Expose isUnderWater to Entity (#8454) 2022-10-11 15:43:10 +03:00
Jake Potrebic
5afab91756 Add missing structure set seed configs (#8030) 2022-10-09 13:19:35 -07:00
Jake Potrebic
5eb4ada324 Fix configs that relied on outdated min/max y levels (#6986) 2022-10-08 23:52:09 -07:00
Jake Potrebic
68ca16f075 Add Unmodifiable annotations to getDrops methods (#8440) 2022-10-07 11:51:54 -07:00
Warrior
3ef916da77 Exempt players in creative/spectator from nether ceiling damage (#8427) 2022-10-07 20:43:26 +02:00
Jake Potrebic
9e43d68e57 Correctly handle interactions with items on cooldown (#8008) 2022-10-07 08:22:45 -07:00
Jake Potrebic
365d10556b EntityPickupItemEvent fixes (#8096) 2022-10-04 21:38:39 -07:00
Jake Potrebic
6e4207e2d9 Fix custom piglin interest items (#8097) 2022-10-04 20:28:46 -07:00
Nassim Jahnke
bf82a75a52 Remove unnecessary onTrackingStart during nav warning
Closes #8396
2022-10-03 20:50:53 +02:00
Gero
bb41ef89ff Avoid resizing of ArrayList in ChunkMap#getPlayers (#8416) 2022-10-03 19:22:01 +02:00
Nassim Jahnke
ad03c22822 [ci skip] Minor patch cleanup 2022-10-03 19:07:03 +02:00
Friwi
b483d1d056 Fix nothing mlg (#8432) 2022-10-03 18:44:19 +02:00
Nassim Jahnke
0254c46a8b Updated Upstream (Bukkit/CraftBukkit) (#8430)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
09943450 Update SnakeYAML version
5515734f SPIGOT-7162: Incorrect description for Entity#getVehicle javadoc
6f82b381 PR-788: Add getHand() to all relevant events

CraftBukkit Changes:
aaf484f6f SPIGOT-7163: CraftMerchantRecipe doesn't copy demand and specialPrice from BukkitMerchantRecipe
5329dd6fd PR-1107: Add getHand() to all relevant events
93061706e SPIGOT-7045: Ocelots never spawn with babies with spawn reason OCELOT_BABY
2022-10-02 09:56:36 +02:00
TetraTheta
1fc4118bd8 Only create paper.yml-README.txt on config conversion (#8334) 2022-10-02 16:29:09 +09:00
Jake Potrebic
88d5b59398 Fix a handful of vanilla bugs (#8187) 2022-10-01 10:39:42 -07:00
Melncat
4a28b308a5 Add getDrops to BlockState and isPreferredTool to BlockData (#8284) 2022-10-01 03:30:00 -07:00
Nassim Jahnke
18149f8cb2 Add system property to dump stack on bad plugin class access (#8417) 2022-10-01 11:49:27 +02:00
Remynfv
f064550583 Fix other jigsaw related disconnect bug (#8414) 2022-10-01 01:08:07 -07:00
Nassim Jahnke
bcbb7dae76 Don't print full packages in new chunk system classes
Closes #8391, #8412
2022-09-30 23:19:51 +02:00
Pasqual Koschmieder
99a00c8e1c Fix wrong yaw and pitch of CommandSourceStack#getBukkitLocation (#8411) 2022-09-30 21:03:42 +02:00
Remynfv
1fe1b8b78e use BlockFormEvent for mud converting into clay (#8398)
Co-authored-by: Legitimoose <legitimoose@gmail.com>
2022-09-30 03:33:31 -07:00
Ilari Suhonen
87abd1cde2 Reduce allocation rate for checkBlock
Use ObjectOpenHashSet instead of HashSet
Remove unnecessary chunkToSave modification
2022-09-29 09:04:52 -07:00
Spottedleaf
3acabf7aa9 Do not log throwable for duplicate entity adds 2022-09-29 08:53:33 -07:00
Bjarne Koll
f044bd9e6c Mark parsed PoiChunks with data as not loaded (#8405)
Previously, PoiChunk#empty would create a new empty poi chunk with
loaded already set to true, as no data was contained in the chunk.
This allowed the poi chunk to skip expensive trips to the main thread.

However, PoiChunk#parse used #empty to create the initial PoiChunk
instance that is then filled with data.
This leads to PoiChunks returned from #parse to already be marked as
loaded, preventing the then needed trip to the tick thread to update
things like the village distance tracker.

To fix this, this commit now marks the PoiChunks loaded state as false
if the parse logic actually read and parsed any data.
This allows the PoiChunk#load method to properly run its callbacks when
called for the first time.
2022-09-29 17:54:47 +02:00
F1rsi
b1d359f247 [ci skip] Added the missing "d" character (#8267) 2022-09-29 17:36:01 +03:00
Remynfv
484512facb Fix jigsaw block kicking user (#8404) 2022-09-29 04:37:56 -07:00
Jason Penilla
79f4c49afc Update Velocity natives (#8387) 2022-09-29 04:18:20 -07:00
Shane Freeder
bf718e5334 [ci skip] shuffle patches and rebuild 2022-09-28 04:27:26 +01:00
Nassim Jahnke
60161bb02c Fix user auth thread pool queue 2022-09-27 18:00:46 +02:00
Jake Potrebic
f7c05166ab Fixes a couple issues with entity spawn reasons (#8390) 2022-09-26 17:24:56 -07:00
Nassim Jahnke
9fdc8516b8 Update snekyaml 2022-09-26 19:47:22 +02:00
Spottedleaf
0f1a8717e8 Rewrite chunk system (#8177)
Patch documentation to come

Issues with the old system that are fixed now:
- World generation does not scale with cpu cores effectively.
- Relies on the main thread for scheduling and maintaining chunk state, dropping chunk load/generate rates at lower tps.
- Unreliable prioritisation of chunk gen/load calls that block the main thread.
- Shutdown logic is utterly unreliable, as it has to wait for all chunks to unload - is it guaranteed that the chunk system is in a state on shutdown that it can reliably do this? Watchdog shutdown also typically failed due to thread checks, which is now resolved.
- Saving of data is not unified (i.e can save chunk data without saving entity data, poses problems for desync if shutdown is really abnormal.
- Entities are not loaded with chunks. This caused quite a bit of headache for Chunk#getEntities API, but now the new chunk system loads entities with chunks so that they are ready whenever the chunk loads in. Effectively brings the behavior back to 1.16 era, but still storing entities in their own separate regionfiles.

The above list is not complete. The patch documentation will complete it.

New chunk system hard relies on starlight and dataconverter, and most importantly the new concurrent utilities in ConcurrentUtil.

Some of the old async chunk i/o interface (i.e the old file io thread reroutes _some_ calls to the new file io thread) is kept for plugin compat reasons. It will be removed in the next major version of minecraft.

The old legacy chunk system patches have been moved to the removed folder in case we need them again.
2022-09-26 01:02:51 -07:00
Bjarne Koll
614f528234 Fix typos in isTickingWorlds API javadocs (#8382) 2022-09-25 02:01:17 +02:00
Lulu13022002
f059f8fce5 Fix setEggCount method from TurtleLayEggEvent (#8385) 2022-09-24 18:34:20 +02:00
Owen1212055
aba5839fde Fix player desync on dimension change (#8253) 2022-09-24 01:45:13 -04:00
Lulu13022002
2e51143433 Avoid item meta usage for itemstack enchantment getter (#8373) 2022-09-24 07:19:51 +02:00
willkroboth
28f9b1a3cb Add method isTickingWorlds to Bukkit (#8316)
Co-authored-by: Shane Freeder <theboyetronic@gmail.com>

Also, restores un/loading worlds mid tick. This will not be officially supported API contract that such a routine is safe, and these restrictions may be restored in the future.
2022-09-24 01:19:05 -04:00
Shane Freeder
fb6addf9e6 Fix mangled patch 2022-09-24 05:48:42 +01:00
willkroboth
60fa7be5b1 Avoid potential place where the world map could be modified after its iterator is created (#8315) 2022-09-24 00:33:20 -04:00
Shane Freeder
8e18842fbc Updated Upstream (Bukkit/CraftBukkit/Spigot)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
c7c11188 SPIGOT-2620: Add Player#sendBlockChanges()
f63d2b44 Improve annotation test on parameters
3372e7b4 SPIGOT-1244, SPIGOT-6860, SPIGOT-6874: Various Javadoc and formatting fixes
a1e8a9ab PR-793: Ignore .checkstyle file generated by Eclipse IDE

CraftBukkit Changes:
c2c39089e SPIGOT-2620: Add Player#sendBlockChanges()
8209158db PR-1113: Ignore .checkstyle file generated by Eclipse IDE

Spigot Changes:
4aa5ead2 Rebuild patches
2022-09-24 02:38:12 +01:00
Jake Potrebic
d885450b81 Correct javadocs on PlayerArmorStandManipulateEvent (#7719) 2022-09-22 22:55:02 -07:00
Lulu13022002
2277da6ec5 Call BlockPhysicsEvent more often (#8264) 2022-09-23 07:35:15 +02:00
Lulu13022002
6d4edceb20 Call EntityChangeBlockEvent for frogs egg (#8136) 2022-09-23 07:32:32 +02:00
Shane Freeder
eb3f66c6da Updated Upstream (Bukkit/CraftBukkit) (#8378) 2022-09-23 06:08:43 +01:00
Jake Potrebic
99640f47f1 Fix ground pathfinding (#7683) 2022-09-20 14:06:11 -07:00
ChristopheG
bb10a5d633 Copper clear on lightning strike calls EntityChangeBlockEvent (#8126) 2022-09-20 04:35:38 +02:00
Owen1212055
d56d06cb3c Respect preventMovingIntoUnloadedChunks for optimized collision checking (#8259) 2022-09-19 22:02:52 -04:00
tahmid-23
72772baccf Fix Pathfinding After World Has Changed (#8068) 2022-09-19 21:39:46 -04:00
Nick Hensel
ad4ca0a429 Also load resources from LibraryLoader (#8335) 2022-09-20 03:07:03 +02:00
Shane Freeder
ede4468516 Make WorldCreator#keepSpawnLoaded return the WorldCreator (Fixes #8321) (#8371)
* Make WorldCreator#keepSpawnLoaded return the WorldCreator (Fixes #8321)

Thought that I fixed this before push/merge, apparently not, hence, fix
the return type and add mitigation for this.

* Fix patch/build

* Rebuild patches
2022-09-20 01:28:22 +01:00
Shane Freeder
e14a2a0cce Configurable chat thread limit (#7878) 2022-09-20 01:16:23 +01:00
Melncat
d2239c40a5 Add a consumer parameter to ProjectileSource#launchProjectile (#8374)
Co-authored-by: MelnCat <melncatuwu@gmail.com>
2022-09-19 17:03:59 -07:00
Nex
d843d7659e Added byte array serialization/deserialization for PersistentDataContainers (#7505) 2022-09-18 04:06:53 +00:00
Lulu13022002
661b30a785 Missing some effect cause (#8307) 2022-09-18 05:46:20 +02:00
Lulu13022002
d146ab42bd Missing eating regain reason (#8244) 2022-09-18 05:24:28 +02:00
Jake Potrebic
7e1f4ba55c fire EntityChangeBlockEvent in more places (#6371)
* fire EntityChangeBlockEvent in more places

* Rebuild patches

Co-authored-by: Shane Freeder <theboyetronic@gmail.com>
2022-09-17 20:03:54 -07:00
elmital
fb4e4f7a34 EndDragonFight killed statuses should be false for newly created worlds (#8354) 2022-09-18 03:44:06 +02:00
Peter Crawley
44c7404b51 Limit size of Authenticator Cache Thread Pool (#8360) 2022-09-17 22:58:51 +01:00
Fruxz
d92d75fb7b Add custom destroyerIdentity parameter to the sendBlockBreak function (#5840) 2022-09-17 23:27:46 +02:00
Bjarne Koll
0ed6315664 Properly close section storage managed files (#8364) 2022-09-17 20:50:01 +02:00
Jaren
5666320311 Stop large look changes from crashing the server (#8326) 2022-09-16 23:30:00 -04:00
karthanistyr
24d3f7bb49 Restore no-crash behaviour when read-only config file(s) (#8318) 2022-09-17 05:22:17 +02:00
Nassim Jahnke
39ae9b75e9 Updated Upstream (Bukkit/CraftBukkit/Spigot)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
9ae3f10f SPIGOT-3842: Add Player#fireworkBoost() and expand Firework API
48c0c547 PR-786: Add methods to get sounds from entities

CraftBukkit Changes:
5cc9c022a SPIGOT-7152: Handle hand item changing during air interact event
4ffa1acf6 SPIGOT-7154: Players get kicked when interacting with a conversation
4daa21123 SPIGOT-3842: Add Player#fireworkBoost() and expand Firework API
e5d6a9bbf PR-1100: Add methods to get sounds from entities
b7e9f1c8b SPIGOT-7146: Reduce use of Material switch in ItemMeta

Spigot Changes:
4c157bb4 Rebuild patches
2022-09-12 13:31:45 +02:00
Jake Potrebic
d1129b0ded Fix console completer/highlighter having invalid source stack (#8346) 2022-09-09 14:25:54 -07:00
Jake Potrebic
328360359a Updated Upstream (Bukkit/CraftBukkit/Spigot) (#8347) 2022-09-09 11:54:00 -07:00
okx-code
2cb0061b0a Allow preventing BlockDestroyEvent from dropping items (#8349) 2022-09-08 16:13:50 +01:00
Spottedleaf
a2df674cc0 Re-add legacy getChunkAtAsynchronously to ChunkProviderServer
Apparently some plugins use it
2022-09-02 04:41:08 -07:00
Spottedleaf
0ee53db50a Fix World#refreshChunk not working for chunks in no-tick range
The chunk would not be marked as ticking in this case, so
retrieving the ticking chunk would not work.
2022-09-01 15:39:24 -07:00
Spottedleaf
90da9124c5 Re-arrange most chunk system patches to front (#8338)
* Re-arrange most chunk system patches to front

Co-authored-by: Spottedleaf <Spottedleaf@users.noreply.github.com>
2022-09-01 09:51:59 -07:00
Spottedleaf
61a8488806 Ensure players are removed from pendingLogin
Looks like they would not have been removed if they disconnected
during the chunk load, preventing the world from being unloaded.
2022-08-29 06:21:45 -07:00
Spottedleaf
9760e8f86a Prevent unloading worlds with pending player logins
Logging into an unloaded world isn't going to end well.
This may fix the cases of people seeing errors about regionfiles
being closed, as loading chunks in an unloaded world will cause this
as the regionfile cache is closed but not cleared.
2022-08-26 21:56:55 -07:00
Nassim Jahnke
b81ec3b8b5 Fix client lag spikes due to client light recalc 2022-08-25 12:59:08 +02:00
José Miguel Moreno
df753f9b3f Fix plugin loggers on shutdown (#5592)
Potentially this should be merged back into the original logging changes patches
2022-08-21 04:57:17 +02:00
Nassim Jahnke
0446f518f4 Updated Upstream (Bukkit/CraftBukkit)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
0b32cbaa PR-782: ThrownPotion now extends ThrowableProjectile
474238ca SPIGOT-7138: Can't retrieve pixel color from map

CraftBukkit Changes:
cdef8fc72 PR-1097: CraftThrownPotion now extends CraftThrowableProjectile
419010b13 SPIGOT-7112: Mobs added 1.17 and after do not create an EntityTargetEvent properly
e71426201 SPIGOT-7079: Allays don't call EntityTargetEvent on ground items
f80adb8b9 SPIGOT-7138: Can't retrieve pixel color from map
2022-08-17 13:02:35 +02:00
petersv5
53102645d2 Grant temporary immunity to hopper minecarts while actively pulling (fixes #8281) (#8282)
Reduce the impact from EAR on hopper minecart based unloaders by making them immune to
EAR while pulling objects. The EAR is still active outside misc activation range when
the hopper minecart is idle, keeping lag low.
2022-08-14 19:41:15 +02:00
Nassim Jahnke
1e9ec27588 More ThrownPotion API 2022-08-14 16:53:36 +02:00
Josh Roy
89ee9379b2 Add NamespacedKey biome methods
Co-authored-by: Thonk <30448663+ExcessiveAmountsOfZombies@users.noreply.github.com>
2022-08-14 12:23:57 -04:00
Pedro
a16e146a5b [ci skip] Show @org.bukkit.UndefinedNullability in javadocs (#8291) 2022-08-14 12:18:39 -04:00
Nassim Jahnke
e8d9f65042 Add method to get highest anger level of warden 2022-08-14 10:25:28 +02:00
Nassim Jahnke
4c6f66a6a3 Updated Upstream (CraftBukkit/Spigot)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

CraftBukkit Changes:
ead719a65 SPIGOT-7136: Cancelling PlayerInteractEntityEvent with the Allay desyncs
8468e167e SPIGOT-7137: StructureGrowEvent isFromBonemeal and getPlayer have incorrect values
d45057c59 SPIGOT-7089: Crash when command blocks attempt to load worlds

Spigot Changes:
450dcaa8 Rebuild patches
2022-08-14 10:03:13 +02:00