Commit Graph

3031 Commits

Author SHA1 Message Date
Spottedleaf
2df432f6af Re-add chunk system debug commands
Re-adds the 'chunkinfo', 'holderinfo' and 'debug chunks' commands.

Additionally, this re-adds chunk debug dumping during watchdog
long timeouts.
2024-06-19 12:11:21 -07:00
Spottedleaf
e0d9d6028c Add debug for chunk system unload crash
Somehow, a chunkholder is present in the unload queue after
it has been unloaded. It is likely that this is a result of
adding the chunk holder to the unload queue while it is
unloading. However, that should not be possible.

To find out where it is being added to the unload queue, track
the last stacktrace which adds to the unload queue and check
on chunk holder remove if the holder is present in the unload queue
and log the stacktrace.
2024-06-19 10:55:04 -07:00
Spottedleaf
f4ddd4ac24 Fix ChunkHolder#getFullChunkNow returning non-null when it should not
In the new chunk system, the chunk is only at FULL when either
the FULL callbacks have been invoked or during the FULL callbacks.
2024-06-19 10:42:48 -07:00
Spottedleaf
38428c0d6c Cleanup MCUtils patch for chunk system
Remove utilities that are unused, as well as replacing
the full chunk map with a concurrentutil implementation.

Additionally, fix the addition/removal of chunks to/from the
full chunk map so that getChunkIfLoaded correctly returns a
non-null chunk when calling the load or unload events.
2024-06-19 10:29:03 -07:00
Spottedleaf
c0268ca86e Copy missing diff from old chunk system patch
Fixes:
- EntitiesLoadEvent/EntitiesUnloadEvent not firing
- Chunks not saving properly in a lot of cases
2024-06-19 09:27:15 -07:00
Spottedleaf
250e78c42a Re-add fixlight command 2024-06-19 08:41:24 -07:00
Jason Penilla
4ea696ffe4
Add ticket for chunk load in isChunkGenerated 2024-06-18 21:15:20 -07:00
Jason Penilla
3b1c85b3a2
Execute chunk tasks while waiting for chunk load in isChunkGenerated
this shouldn't be needed as we are requesting EMPTY status, however there is a deeper issue that we will just work around for now

fixes #10916
2024-06-18 21:04:35 -07:00
Jason Penilla
d23825aa56
Add missing null check to getFullChunkIfLoaded
fixes #10915
2024-06-18 18:27:50 -07:00
Jason Penilla
126f6d7dc1
Remove getUnloadingChunkHolder check
It always returns null now. So it could NPE and is not useful.
2024-06-18 12:51:40 -07:00
Jason Penilla
7bbe6820c2
Fix CraftWorld#isChunkGenerated
The upstream implementation is returning true for non-full chunks.

This fix is not ideal since the new chunk system doesn't have a region file/chunk status patch. May want to be revisited before a non-experimental release.
2024-06-18 12:44:07 -07:00
Bjarne Koll
4514f41ffa
Correct duplicate attribute check (#10901)
Brackets got lost during the update, leading to an incorrect
precondition call.
2024-06-18 11:11:14 +02:00
Jake Potrebic
b4b820851f
Fix NPE for Jukebox#setRecord
Fallback to the global registry if no level exists
Fixes #10899
2024-06-17 17:44:04 -07:00
Nassim Jahnke
21c9a7c79d
Rebuild patches 2024-06-17 21:21:06 +02:00
willkroboth
b3e072a625
Fix hasFiredAsync parameter when AsyncPlayerSendCommandsEvent is called (#10896) 2024-06-17 21:17:51 +02:00
Jake Potrebic
bf8552f0f0
Delegate ItemStack (#10852) 2024-06-17 21:12:42 +02:00
Nassim Jahnke
13992b17c7
Make chunk system loggers calm down a bit 2024-06-17 13:43:21 +02:00
Nassim Jahnke
152f4feff3
Add back improved watchdog support patch 2024-06-17 13:36:43 +02:00
Jake Potrebic
a7f6633362
make EntityPortalReadyEvent#setTargetWorld work again 2024-06-16 15:48:38 -07:00
Jake Potrebic
fb762cf368
remove remaining reference to 'pgive' 2024-06-16 15:38:59 -07:00
Jake Potrebic
8dfb85c173
Enchantment and GameEvent Registry builders (#10889)
Co-authored-by: Bjarne Koll <lynxplay101@gmail.com>
2024-06-17 00:00:12 +02:00
Nassim Jahnke
61b85e4cbf
Fix legacy cb version in remapper 2024-06-16 23:23:50 +02:00
Spottedleaf
f8ee0a06c5 Fix implementations of ChunkHolder#getChunkIfPresent
Implementations for ChunkStatuses below FULL are supposed to always
return ProtoChunk instances. However, since we used the last completed
status, it could return LevelChunk.

To resolve this, follow Vanilla behavior of tracking chunk
completions by status and replace old ProtoChunk statuses with
ImposterProtoChunk when the chunk generates to FULL.

Additionally, implement an optimisation for retrieving full chunks
by storing a map of pos -> LevelChunk. This requires only a simple
map lookup to occur for full chunks which are loaded.
2024-06-16 14:09:44 -07:00
Jake Potrebic
d9111ccec2
Registry Modification API (#10893)
* Registry Modification API

* some fixes

* even more fixes
2024-06-16 12:39:59 -07:00
Nassim Jahnke
106dbae220
Fix getAddress connection check 2024-06-16 21:31:39 +02:00
Jake Potrebic
167961e744
call EntityDamageItemEvent for thorns 2024-06-16 09:47:53 -07:00
Bjarne Koll
fbc2a55cde
Update Wither#canTravelThroughPortals 2024-06-16 18:04:11 +02:00
Bjarne Koll
e1c0033552
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:
2b4b6d14 PR-1023: Convert InventoryView to interface

CraftBukkit Changes:
68603b1c1 Use expanded interaction ranges for traced interact events
eae9f760c PR-1414: Convert InventoryView to interface
ee9eafe67 Fix Implementation for DamageSource#isIndirect for internal custom causing entity
2024-06-16 17:23:42 +02:00
Jake Potrebic
ec4c712efa
update 'improve mass craft perf' patch 2024-06-16 08:08:06 -07:00
Jakub Zacek
d8c298007f
Add Adventure API to ServerLinks (#10891) 2024-06-16 13:54:38 +02:00
Nassim Jahnke
dc684c60d1
Remove bad server.scheduleOnMain disconnect calls from old patches
The new behavior of disconnect to block the current thread until the disconnect succeeded is better than throwing it off to happen at some point
2024-06-16 12:56:00 +02:00
Nassim Jahnke
752f957e12
Add back more patches 2024-06-16 12:47:57 +02:00
Bjarne Koll
60f3bd8d0c
De-deprecate BlockData#getDestroySpeed 2024-06-16 12:44:22 +02:00
Yannick Lamprecht
1f8e7a7b09
address compile and test issue (#10890) 2024-06-16 11:47:44 +02:00
Spottedleaf
f873bcee24 Fix NPE in V3808
The armor items may not exist, so we need to null check it.
2024-06-15 22:59:15 -07:00
Owen1212055
7240d9d81c
Restore functionality to sand dupe setting 2024-06-15 22:04:02 -04:00
Spottedleaf
b090c65fe0 Remove unnecessary changes from chunk status fix 2024-06-15 15:31:04 -07:00
Bjarne Koll
e339ec27b4
Deprecate BlockData#getDestroySpeed for removal
The method sadly is not usable in 1.21 without a player as all of an
enchantments attribtue modifiers rely on a base value supplied by a
player. The method could only offer a rough estimate based on some
default values, however a better method for this should be added down
the line rather than trying to force such logic into the existing one.
2024-06-16 00:19:10 +02:00
Bjarne Koll
3555a7776e
Properly forward DispenseEvent #getItem to saddle
Correctly use the DispenseEvent's #getItem ItemStack when placing the
saddle on entities during a dispense behaviour instead of the original
stack.
2024-06-16 00:01:55 +02:00
Bjarne Koll
7df472527f
Configurable damage tick when blocking with shield (#10877)
A long standing bug in spigot and its derivatives was the fact that
players taking damage while blocking with a shield would not receive
invulnerability, while they do in vanilla.

This enabled the pvp technique of disabling a shield and immediately
attacking again to knock a player into the air.
While upstream fixed this and properly aligned itself with vanilla
damage logic (in this specific case) changing such long standing
behaviour has some downsides.

To allow players used to this specific bug to still use it, this patch
introduces a configuration option to re-introduce said bug.
As there is no easy way to *only* re-add this bug, the option is found
in the unsupported section as it may introduce other damage related
disparity from vanilla.
2024-06-15 23:17:51 +02:00
Aya
d41636f445
Add back RecipeIterator fixes patch (#10887) 2024-06-15 21:53:46 +02:00
Jake Potrebic
c1aefeecc6
correctly change enchantment registry to a 'delayed' version 2024-06-15 12:04:06 -07:00
Nassim Jahnke
56b5b7d452
Fix max chunk status checks 2024-06-15 19:57:59 +02:00
Nassim Jahnke
0008fa17e9
Add back more optimization patches 2024-06-15 19:24:11 +02:00
Bjarne Koll
04dad71064
Improve enchantWithLevels logic
Previously would stream and optionally filter out all entries in the
enchantment registry.
Moves it to using the empty optional if treasure is allowed, leaving the
logic to EnchantmentHelper.
2024-06-15 19:08:11 +02:00
Nassim Jahnke
a835ad1076
Merge remote-tracking branch 'origin/dev/1.21' into dev/1.21 2024-06-15 18:52:19 +02:00
Ghast
b420038799
Fix ItemMeta#removeEnchantments (#10886) 2024-06-15 18:52:01 +02:00
Jake Potrebic
fb511c698e
Fix Player#sendBlockState (#10855) 2024-06-15 18:52:00 +02:00
Jake Potrebic
5bd7f4e8ae
Update AbstractArrow item method implementations for 1.20.6 (#10885) 2024-06-15 18:48:27 +02:00
Bjarne Koll
0b6701da5a
Revert DamageSource#getCausingEntity to vanilla 2024-06-15 18:39:55 +02:00
Nassim Jahnke
4bc15f13aa
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:
e2160a18 Make MapCursor#type not depends on deprecated values

CraftBukkit Changes:
6ce172642 SPIGOT-7761: Ender pearl does not damage or spawn endermites
f5a63f734 SPIGOT-7759: Chunk not there when requested in ChunkUnloadEvent
28287259c Remove unused import
eb9a7dde0 SPIGOT-7757: Cannot set item in Stonecutter Inventory
f8be9d752 Move deserialized removed unhandled tags to dedicated removedTags
a7e576186 Fix potential mutability issue with CraftMetaItem copy constructor
995885452 SPIGOT-7741: Vanilla ItemComponent in commands can't remove components
9ef69aa0b PR-1284: Move ItemType <-> ItemMeta linking to a centralized place
3e82eafbe PR-1420: Fix DirectEntity and CausingEntity Damager for Creepers ignited by Player
c23daa71f SPIGOT-7751: Fix crash caused by arrows from trial spawners
Make MapCursor#type not depends on deprecated values
SPIGOT-7761: Ender pearl does not damage or spawn endermites
2024-06-15 18:31:58 +02:00
Jake Potrebic
5d834b1b71
rebuild patches 2024-06-15 06:22:06 -07:00
Nassim Jahnke
ee9b820fbe
Update more optimization patches 2024-06-15 14:12:22 +02:00
Spottedleaf
730882fca9 Chunk System and Starlight WIP
Chunk system patch was refactored to take advantage of
newer ConcurrentUtil's concurrent long hash table (which
fixes hash collisions caused by chaining fastutil's long hash
and CHM's hash) plus some other minor improvements.

The chunk system was also merged with Starlight, which mostly
provides a small improvement to ThreadedLevelLightEngine#checkBlock
as the scheduling was rewritten.
2024-06-14 17:39:15 -07:00
Jake Potrebic
ffe310a8e1
remove api that was scheduled for removal 2024-06-14 14:07:44 -07:00
Spottedleaf
f5693896c5 Update ConcurrentUtil
Mostly for the primitive long to reference hashtable impl
2024-06-14 10:47:33 -07:00
Spottedleaf
df633e5ffa DataConverter 1.21 2024-06-14 10:34:45 -07:00
Spottedleaf
38b3182a90 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:
befcf86d SPIGOT-7740: Fix using new map cursor types
09229095 Add EntityDamageEvent.DamageCause#CAMPFIRE

CraftBukkit Changes:
a1d2cd152 SPIGOT-7747: Mob head is not dropped when mob was blown up by a charged creeper
8078294bc SPIGOT-7746: Server Crashing when Players Getting into End Portals
8d842e250 SPIGOT-7744: Fix exception for shooting projectiles with flame enchantment
64e0ad129 SPIGOT-7744: Fix crash when shooting arrows in creative mode
819f7a10a Fix player items not dropping on death
0a0229bb5 Implement DamageCause#CAMPFIRE and minor improvement in exception for Unhandled block damage
2024-06-14 10:15:52 -07:00
Nassim Jahnke
66f7b672ed
Fix body equipmentslot and effect enum 2024-06-14 18:53:32 +02:00
Nassim Jahnke
038f8d915e
Fixup and deprecate player profiles in ping event
The player sample uses game profile internally, but discards everything but the name and uuid and does not follow player profile restrictions, so it doesn't make sense to use that in the event.
2024-06-14 18:17:26 +02:00
Nassim Jahnke
5442bffab5
Make it compile 2024-06-14 18:02:15 +02:00
Bjarne Koll
547f09dfa0
Some work on the ItemMend events 2024-06-14 16:01:00 +02:00
Bjarne Koll
69d1d0a4f4
Pretend to fix compile errors 2024-06-14 15:16:29 +02:00
Nassim Jahnke
a308c7c8d7
Fix more compile issues 2024-06-14 14:28:06 +02:00
Nassim Jahnke
0d3ce2d704
Fix more compile issues 2024-06-14 14:11:52 +02:00
Nassim Jahnke
3c04f9f668
Fix a few compile errors 2024-06-14 13:07:50 +02:00
Bjarne Koll
6d4e235784
988 2024-06-14 11:59:44 +02:00
Bjarne Koll
4140de28eb
960 2024-06-14 11:07:50 +02:00
Bjarne Koll
a399f23903
956 2024-06-14 10:56:28 +02:00
Bjarne Koll
14c03366ed
922 2024-06-14 10:17:11 +02:00
Jason Penilla
33b36cde31
update some patches 2024-06-13 20:41:44 -07:00
Jake Potrebic
52b49fbcc8
788/1053 2024-06-13 18:30:23 -07:00
Jake Potrebic
8731266275
650/1053 2024-06-13 17:08:12 -07:00
Jake Potrebic
ba163e10bb
585/1053 2024-06-13 16:32:45 -07:00
Bjarne Koll
ed2ea4538e
538 2024-06-14 00:44:26 +02:00
Jake Potrebic
083bd9e75c
531/1053 2024-06-13 14:42:02 -07:00
Jake Potrebic
27e29ccaf2
487/1053 2024-06-13 13:57:13 -07:00
Jake Potrebic
0bc9aeef26
385 2024-06-13 13:14:13 -07:00
Jake Potrebic
ec05cb8b38
279 2024-06-13 12:04:27 -07:00
Jake Potrebic
0b7552272a
194 2024-06-13 11:09:28 -07:00
Jake Potrebic
2055809b1e
117 2024-06-13 10:30:39 -07:00
Jake Potrebic
8a37f93925
62 2024-06-13 10:12:48 -07:00
Jake Potrebic
7fbb8278e7
Finish API patches 2024-06-13 08:45:43 -07:00
Bjarne Koll
79e2cb620e
Update upstream (Bukkit/CraftBukkit/Spigot) (#10875)
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:
376e37db SPIGOT-7677: Update which entities are marked as spawnable
06c4add3 SPIGOT-7737: Add separate TreeType.MEGA_PINE
19b7caaa SPIGOT-7731: Spawn eggs cannot have damage
e585297e PR-1022: Add force option to Player#spawnParticle
d26e0094 PR-1018: Add methods to get players seeing specific chunks
8df1ed18 PR-978: Add Material#isCompostable and Material#getCompostChance
4b9b59c7 SPIGOT-7676: Enforce locale parameter in toLowerCase and toUpperCase method calls and always use root locale
8d1e700a PR-1020: Cast instead of using #typed when getting BlockType and ItemType to better work with testing / mocks
fa28607a PR-1016: Fix incorrect assumption of Fireball having constant speed
4c6c8586 PR-1015: Add a tool component to ItemMeta
6f6b2123 PR-1014: Add PotionEffectTypeCategory to distinguish between beneficial and harmful effects
f511cfe1 PR-1013, SPIGOT-4288, SPIGOT-6202: Add material rerouting in preparation for the switch to ItemType and BlockType
def44cbf SPIGOT-7669: Fix typo in ProjectileHitEvent#getHitBlockFace documentation
53fa4f72 PR-1011: Throw an exception if a RecipeChoice is ever supplied air

CraftBukkit Changes:
ee95e171a SPIGOT-7737: Add separate TreeType.MEGA_PINE
0dae4c62c Fix spawn egg equality check and copy constructor
ab59e847c Fix spawn eggs with no entity creating invalid stacks and disconnect creative clients
3b6093b28 SPIGOT-7736: Creative spawn egg use loses components
c6b4d5a87 SPIGOT-7731: Spawn eggs cannot have damage
340ccd57f SPIGOT-7735: Fix serialization of player heads with note block sound
fd2f41834 SPIGOT-7734: Can't register a custom advancement using unsafe()
02456e2a5 PR-1413: Add force option to Player#spawnParticle
6a61f38b2 SPIGOT-7680: Per-world weather command
58c41cebb PR-1409: Add methods to get players seeing specific chunks
16c976797 PR-1412: Fix shipwreck loot tables not being set for BlockTransformers
7189ba636 PR-1360: Add Material#isCompostable and Material#getCompostChance
900384556 SPIGOT-7676: Enforce locale parameter in toLowerCase and toUpperCase method calls and always use root locale
bdb40c5f1 Increase outdated build delay
d6607c7dd SPIGOT-7675: Fix FoodComponent config deserialization
b148ed332 PR-1406: Fix incorrect assumption of Fireball having constant speed
3ec31ca75 PR-1405: Add a tool component to ItemMeta
5d7d675b9 PR-1404: Add PotionEffectTypeCategory to distinguish between beneficial and harmful effects
960827981 PR-1403, SPIGOT-4288, SPIGOT-6202: Add material rerouting in preparation for the switch to ItemType and BlockType
94e44ec93 PR-1401: Add a config option to accept old keys in registry get calls
a43701920 PR-1402: Fix ChunkSnapshot#isSectionEmpty() is always false
87d0a3368 SPIGOT-7668: Move NONE Registry updater to FieldRename to avoid some class loader issues
2ea1e7ac2 PR-1399: Fix regression preventing positive .setDamage value from causing knockback for 0 damage events
ba2d49d21 Increase outdated build delay

Spigot Changes:
fcd94e21 Rebuild patches
342f4939 SPIGOT-7661: Add experimental unload-frozen-chunks option
2024-06-13 16:45:27 +02:00
Bjarne Koll
906df69f05
Prevent internal NPE on ItemStack#damage (#10836)
ItemStack#damage internally uses ItemStack#hurtAndBreak, which
previously would call a Consumer in case the item broke.
Since 1.20.5 the break game event logic however resides in said method
and was using the equipment slot passed, which is null in the case of
the API ItemStack#damage method.

This commit prevents the NPE by first null checking the slot.
Addittionally, hurtAndBreak also now checks if the player has infinite
materials, e.g. is in creative mode, to prevent damaging the item.

As such as filter is undesirable for API calls, this commit also skips
this logic in case of an API invocation.
2024-06-10 08:24:52 +02:00
Lulu13022002
bd5867a96f
Handle alpha channel from potion_contents component (#10808) 2024-06-04 16:55:29 -04:00
Jake Potrebic
88d76d9fe5
Make Bogged implement Shearable (#10844) 2024-06-04 16:26:40 -04:00
Spottedleaf
4f13be937e Do not perform chunk existance check for I/O scheduling
In order to check if a chunk exists, the RegionFile lock
(if the RegionFile is opened) will be acquired. However,
the RegionFile may be performing I/O operations, in which
case will stall the acquire operation.

To ensure that threads scheduling loads do not incur a stall,
we can avoid this check entirely - the RegionFile I/O
thread(s) will eventually perform the exist check itself.
2024-06-03 13:31:41 -07:00
Bjarne Koll
b8f2101c36
Only assign blockstate data if super ctor did not (#10841)
The CraftBlockStateMeta constructor CraftBlockStateMeta(Map) invokes its
parent constructor, which itself invokes deserializeInternal, which is
implemented on CraftBlockStateMeta to read the components and block
entity tag from the passed map.

Field initialization happens after the call to the super constructor,
meaning the current code overwrites the parsed internal data with the
EMPTY defaults.

This is prevented by moving the initialization into its own code block
that can null check the fields prior to defaulting their value to EMPTY.
2024-06-03 10:39:20 -07:00
Jake Potrebic
ac647513b2
Use RegistryOps in the correct places (#10843) 2024-06-02 15:19:17 -07:00
Bjarne Koll
5d8e53d78d
Fix CommandSourceStack#bypassSelectorPermissions (#10837)
The previous implementation would throw a command exception if the
CommandSourceStack had its bypassSelectorPermissions flag set to true,
which is the incorrect behaviour.

Instead, it should only throw an exception if the flag is set to false
and all its other checks "fail" too.
2024-06-01 16:26:11 +02:00
Jake Potrebic
0513374b1f
Fire TabCompleteEvent for legacy commands (#10834) 2024-05-31 17:46:42 +02:00
TotalledZebra
3181470ad7
Add entity heal API (#10267) 2024-05-30 22:31:45 +02:00
Jake Potrebic
a47e11d464
fix knockback events (#10831)
* fix knockback events

* squash

* handle cancelled event for explosions
2024-05-30 13:17:16 -07:00
Shane Freeder
8e6554a80a
Fix sending disconnect packet in phases where it doesn't exist 2024-05-30 19:05:39 +01:00
Jake Potrebic
0fcf3e347f
Deprecate InvAction#HOTBAR_MOVE_AND_READD (#10784) 2024-05-29 14:56:14 -07:00
SoSeDiK
27d2ed84f4
Extend fishing API (#10634)
Adds a missing fishing state when the fish is lured and fires an event for it.
Also adds a way to control the fish swimming time towards the bobber.
2024-05-29 23:45:01 +02:00
Jake Potrebic
efd91e52a6
Add registry-related argument types (#10770)
* Add registry-related argument types

* fix tests
2024-05-29 14:11:52 -07:00
Jake Potrebic
a31dc90741
Several fixes and new api for experience merging/stacking (#9242) 2024-05-29 22:58:57 +02:00
Bjarne Koll
ed85aac53c
Flatten namespaced vanilla command alias redirects (#10821)
The brigadier command dispatcher is not capable of executing commands
that redirect more than one.
The exemplary alias 'minecraft:tp' may hence not redirect to 'tp' it
instead has to redirect to 'teleport' as 'tp' itself is merely a
redirect.
2024-05-29 21:47:07 +02:00
Jake Potrebic
7e2b682e54
Fix skipping custom block entity tag (#10812) 2024-05-29 21:22:51 +02:00
Jake Potrebic
716b868b08
Use RegistryOps for loadAdvancement (#10799) 2024-05-29 20:27:29 +02:00
Jake Potrebic
672c07728f
handle BODY slot for non-mobs (#10822) 2024-05-29 11:23:51 -07:00
Lulu13022002
84f6e6e0b1
Fix max temper API for llama (#10823) 2024-05-29 11:17:56 -07:00
Bjarne Koll
9d6f2cced7
[ci skip] Rebuild patches (#10803) 2024-05-28 14:19:41 +02:00
Bjarne Koll
b0c9b9c4d8
Only remove worldgen block entity on changed block (#10794) 2024-05-28 11:45:03 +02:00
Shane Freeder
23fe1166d4
Fix missing debug trace 2024-05-27 18:33:34 +01:00
Tamion
347bbe3897
Fix Cancelling BlockPlaceEvent calling onRemove (#10773) 2024-05-27 00:03:48 +02:00
Jake Potrebic
b0e3ca43b8
Prevent NPE if hooked entity was cleared (#10712) 2024-05-26 23:41:30 +02:00
Lulu13022002
841ab4134d
Fix more item desync when an event is cancelled (#10654) 2024-05-26 23:30:45 +02:00
Cross
1b8cdc6d82
Extend Player Interact cancellation to cover Jigsaw blocks (#10719) 2024-05-26 22:54:55 +02:00
Jake Potrebic
6649a171dc
Fix BlockStateMeta equals (#10795) 2024-05-26 22:49:00 +02:00
Lulu13022002
ac4ee06c01
Fix integer overflow for lag compensating eating check (#10797) 2024-05-26 22:35:58 +02:00
Jake Potrebic
9774a52d11
fix and cleanup loot table patches (#10100)
* fix and cleanup loot table patches

* fixes
2024-05-26 12:51:15 -07:00
Lulu13022002
ca50b87947
Clear firework item properly (#10793) 2024-05-26 19:57:38 +02:00
Jake Potrebic
a7ae966530
readd itemstack data sanitization (#10454)
* readd itemstack data sanitization

* use autocloseable
2024-05-26 10:56:33 -07:00
Jake Potrebic
4e10fadfdc
reset meta block state on BlockStateMeta#setBlockState 2024-05-25 22:36:55 -07:00
Jake Potrebic
41bee55b53
Fix NPE for color-related metas
Fixes #10789
2024-05-25 19:55:51 -07:00
Janet Blackquill
f0bd0cca8f
Expose anvil cost in the API (#10682) 2024-05-26 01:47:14 +02:00
Jake Potrebic
26e90b9ffb
Fix CraftMetaBlockState for data components (#10731)
This will go on forever...
2024-05-25 16:37:35 -07:00
Lulu13022002
535dca56c2
Fix a few issues with ItemMeta (#10740) 2024-05-26 00:58:56 +02:00
TonytheMacaroni
377733d44c
Use getter/setter on Mob for equipment drop chances (#10780) 2024-05-24 19:52:54 +02:00
Shane Freeder
3004717b0e
Do not re-wrap vanilla goals (#10751)
There is no need to rewrap vanilla goals when they're being reregistered,
this breaks some expectations around behavior outside of general
wasting of resources.

Resolves: #10743
2024-05-24 16:22:41 +02:00
Jason Penilla
5e7b65a9a9
Allow using PluginLoader classpath API from Bukkit plugins (#10758)
Allows using the PluginLoader API without any of the other changes imposed by switching to a paper-plugin.yml.

Used by setting paper-plugin-loader in plugin.yml to the class name of your PluginLoader.

Also allows skipping the libraries field by setting paper-skip-libraries to true (by default both libraries and jars provided by the PluginLoader are added to the classpath).
2024-05-23 13:13:02 -07:00
Jake Potrebic
2a90732677
Remove incorrect logic for Fireball#setVelocity (#10764) 2024-05-23 12:48:11 -07:00
Jake Potrebic
6de7a1f052
Improve default item attributes API (#10765) 2024-05-23 11:44:07 -07:00
Jake Potrebic
3de408ee3e
Fix equipment slot and group API (#10767) 2024-05-23 10:39:44 -07:00
Jake Potrebic
a9201d4a7d
[ci skip] Move logic in our patches to ItemType/BlockType (#10772) 2024-05-23 10:32:02 -07:00
Jake Potrebic
b14958485d
Always show command exception stack traces in logs (#10766) 2024-05-22 10:24:09 -07:00
Jake Potrebic
d3ffa62b7f
fix default item attributes 2024-05-22 07:16:50 -07:00
Spottedleaf
980cff9f29 Fix compile 2024-05-21 08:41:36 -07:00
Spottedleaf
66cb880754 Remove ThreadedWorldUpgrader patch
The patch does not implement Vanilla forceUpgrade behavior.
Specifically, poi/entity conversion and regionfile recreation.

The Vanilla force upgrader is also no longer broken by CB, so the
bug fixes from this patch are not relevant anymore.
2024-05-21 08:21:28 -07:00
Jake Potrebic
7d2e5c33ea
Add an 'empty' RecipeChoice for certain ingredient slots (#10710) 2024-05-20 07:20:47 -07:00
Jake Potrebic
591521e697
Check for more correct profile validation (#10730) 2024-05-19 17:45:43 -07:00
Jake Potrebic
b3b340617e
fix CompassMeta not being correct (#10737) 2024-05-19 17:15:44 -07:00
Shane Freeder
0ad09de75b
Make PaperSimplePluginClassLoader show class which is not found 2024-05-18 21:17:54 +01:00
Jake Potrebic
5a9afbee65
Fixes issues in the suppress dismount cancellation patch (#10735) 2024-05-17 14:37:16 -07:00
Jake Potrebic
d8d59e0cde
Fix NPE sending resource pack without prompt
Fixes KyoriPowered/adventure#1075
2024-05-17 14:22:45 -07:00
Riley Park
f17519338b
Expose server build information (#10729)
* Expose server build information

* squash patches

* final tweaks

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
Co-authored-by: masmc05 <masmc05@gmail.com>
2024-05-15 17:06:59 -07:00
Jason Penilla
3fc93581bb
Show stacktrace when modifyItemStack fails 2024-05-13 22:58:50 -07:00
Jason Penilla
2faa3b2f44 Correctly copy alias requirements in command upgrader
Fixes NPE when converting namespaced commands.

Since the brigadier command api, more aliased commands
(namespaced variants) are registered in the vanilla dispatcher,
which made this issue more apparent.
2024-05-13 15:55:15 -07:00
Spottedleaf
bebcc9cc93 Make exception during command conversion non-fatal
Instead of allowing chunks to fail to convert completely,
simply log the exception and the offending command. Command
conversion failure should never result in chunk data deletion,
as commands are not critical chunk data.
2024-05-13 14:40:02 -07:00
Jake Potrebic
0688f212f5
Better way to keep paper datapack enabled 2024-05-12 21:48:07 -07:00
Bjarne Koll
f041f48458
Prevent infinite recursion on cyclic brig redirect (#10705)
Prevent infinite recursion when declaring a cyclic relation between
command nodes via child nodes redirecting to an nth parent by marking a
command node as unwrapped before unwrapping its children.
2024-05-12 17:41:21 +02:00
Owen
7e48f66c05
Properly pass requirement on namespaced redirects (#10701) 2024-05-11 23:46:42 -07:00
Jason Penilla
711f82e01e
Fix signed book page serialization (#10696) 2024-05-12 00:13:18 +02:00
Jake Potrebic
ac554ad46d
Updated Upstream (Bukkit/CraftBukkit) (#10691)
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:
fa99e752 PR-1007: Add ItemMeta#getAsComponentString()
94a91782 Fix copy-pasted BlockType.Typed documentation
9b34ac8c Largely restore deprecated PotionData API
51a6449b PR-1008: Deprecate ITEMS_TOOLS, removed in 1.20.5
702d15fe Fix Javadoc reference
42f6cdf4 PR-919: Add internal ItemType and BlockType, delegate Material methods to them
237bb37b SPIGOT-1166, SPIGOT-7647: Expose Damager BlockState in EntityDamageByBlockEvent
035ea146 SPIGOT-6993: Allow #setVelocity to change the speed of a fireball and add a note to #setDirection about it
8c7880fb PR-1004: Improve field rename handling and centralize conversion between bukkit and string more
87c90e93 SPIGOT-7650: Add DamageSource for EntityDeathEvent and PlayerDeathEvent

CraftBukkit Changes:
4af0f22e8 SPIGOT-7664: Item meta should prevail over block states
c2ccc46ec SPIGOT-7666: Fix access to llama and horse special slot
124ac66d7 SPIGOT-7665: Fix ThrownPotion#getEffects() implementation only bringing custom effects
66f1f439a Restore null page behaviour of signed books even though not strictly allowed by API
6118e5398 Fix regression listening to minecraft:brand custom payloads
c1a26b366 Fix unnecessary and potential not thread-safe chat visibility check
12360a7ec Remove unused imports
147b098b4 PR-1397: Add ItemMeta#getAsComponentString()
428aefe0e Largely restore deprecated PotionData API
afe5b5ee9 PR-1275: Add internal ItemType and BlockType, delegate Material methods to them
8afeafa7d SPIGOT-1166, SPIGOT-7647: Expose Damager BlockState in EntityDamageByBlockEvent
4e7d749d4 SPIGOT-6993: Allow #setVelocity to change the speed of a fireball and add a note to #setDirection about it
441880757 Support both entity_data and bucket_entity_data on axolotl/fish buckets
0e22fdd1e Fix custom direct BlockState being not correctly set in DamageSource
f2182ed47 SPIGOT-7659: TropicalFishBucketMeta should use BUCKET_ENTITY_DATA
2a6207fe1 PR-1393: Improve field rename handling and centralize conversion between bukkit and string more
c024a5039 SPIGOT-7650: Add DamageSource for EntityDeathEvent and PlayerDeathEvent
741b84480 PR-1390: Improve internal handling of damage sources
0364df4e1 SPIGOT-7657: Error when loading angry entities
2024-05-11 23:48:37 +02:00
Owen
b98d20a8ac
Brigadier Command Support (#8235)
Adds the ability for plugins to register their own brigadier commands 

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
Co-authored-by: Jason Penilla <11360596+jpenilla@users.noreply.github.com>
Co-authored-by: Bjarne Koll <lynxplay101@gmail.com>
2024-05-11 16:30:30 -04:00
Jake Potrebic
6c02dbcfa1
handle recent ItemMeta changes in serialization logic 2024-05-11 09:14:23 -07:00
Jake Potrebic
a61d58d467
adjust ItemMeta to distinguish null and empty modifiers
Fixes #10686 (again)
2024-05-11 07:16:23 -07:00
Jake Potrebic
cdb6ba8ef1
Fix keepalive time interval (#10690) 2024-05-10 17:23:58 -07:00
Jake Potrebic
39532a1f8c
Fix stacks losing empty attr modifiers
Fixes #10686
2024-05-10 12:05:07 -07:00
Jason Penilla
4fd58a1b8f
Add conversion for summon command 2024-05-10 12:57:07 +02:00
Nassim Jahnke
7f1a154d15
Add validation to player profile and properties (#10680) 2024-05-10 12:52:03 +02:00
Spottedleaf
8748ae16ac Use MCDataConverter instead of raw convert call for cmd converter
MCDataConverter uses the breakpoint system, which for future
updates may be neccesary (probably not).

Also, add the 1.20.6 version field.
2024-05-10 00:34:37 -07:00
Joseph Burton
2df1dace32 Fix DataConverter ConverterParticleToNBT.parseProperties
- The old code was using `StringReader.peek()` in a place where it meant to be `StringReader.skip()`.
- The vanilla code allows a trailing comma, but only if there is no whitespace between it and the closing bracket, which is a bit weird. I think that's a bug and it shouldn't allow trailing commas, but if you disagree then only the first issue needs to be fixed.
2024-05-10 00:32:31 -07:00
Spottedleaf
b56e92f3d4 Fix chunk data version check not running in chunk system
The old read() method should just redirect to the new
chunk system method, however due to an error in moving
the chunk system patch around the data version check was
left in the old (UNUSED) read() method.
2024-05-09 23:47:13 -07:00
Spottedleaf
cc29d2b7d5 Invalidate PathTypeCache when pathfinding updates are disabled
The configuration should not allow the cache to break. Additionally,
invalidating the cache is cheap and as such there is no gain to avoid
invalidating it.
2024-05-09 23:07:32 -07:00
Spottedleaf
1b67e02385 Fix entity tracker desync when new players are added to the tracker
The delta position packet instructs the client to update
the entity position by a position difference. However, this position
difference is relative to the last position in the entity tracker
state, not the last position which has been sent to the player. As
a result, if the last position the player has recorded is different
than the one stored in the entity tracker (which occurs when a new
player is added to an existing entity tracker state) then the sent
position difference will cause a position desync for the client.

We can resolve this problem by either tracking the last position
sent per-player, or by simply resetting the last sent position
in the entity tracker state every time a new player is added.
Resetting the last sent position every time a new player is
added to the tracker is just easier to do, so that is what
this patch does.
2024-05-09 17:08:59 -07:00
Nassim Jahnke
f2512b1238
Print data component type on encoding error 2024-05-09 15:12:12 +02:00
Shane Freeder
5729b294ee
Update Adventure to 4.17.0 Release 2024-05-08 15:48:45 +01:00
Bjarne Koll
eee55d019f
Correctly compare holders in BeaconMenu (#10673) 2024-05-07 18:18:57 -07:00
Lulu13022002
89ad61fd00
Fix hopper pull event being skipped after the first call (#10667) 2024-05-07 14:28:45 +02:00
Jason Penilla
9e51f94941
Fix ping event always receiving protocol version 0 (#10671) 2024-05-07 14:24:45 +02:00
Jake Potrebic
ac3a5471c8
Fix BlockStateMeta (#10647)
* Fixes CraftMetaBlockState block entity data components

* rebase and merge into general item meta fix

* Add javadoc notice

* Update message

---------

Co-authored-by: Bjarne Koll <lynxplay101@gmail.com>
2024-05-05 12:56:46 -07:00
SoSeDiK
2a6a5fef59
Add a way to check whether the chest is blocked (#10635)
* More Chest Block API

* rebased and slight logic fixes
2024-05-05 10:57:28 -07:00
Bridge
21d91ce634
Prevent profile lookups when unnecessary (#10651) 2024-05-05 19:07:30 +02:00
Tamion
716dfd8698
Fix EntityLoadCrossbowEvent (#10645)
* fix

* hehe
2024-05-05 09:54:04 -07:00
NonSwag
54c5ecb4e4
Add missing SpigotConfig logCommands check (#10659) 2024-05-05 18:41:02 +02:00
Nostal Yuu
0e43d3c103
Added API to get player's proxy address (#10400) 2024-05-05 18:39:32 +02:00
Jake Potrebic
9d8d38d137
Updated Upstream (CraftBukkit) (#10646)
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:
66fd94322 SPIGOT-7652: Remove remap for SPELL_MOB_AMBIENT which no longer exists
ecfa4f973 SPIGOT-7654: ItemStack#isSimilar does not work with empty BlockStateMeta
4460ecc49 SPIGOT-7655: ItemMeta#addItemFlags(ItemFlag.HIDE_ATTRIBUTES) not working when no attribute modifiers set
5d84f48a4 SPIGOT-7653: Update ApiVersion.CURRENT with latest version and include tests
2024-05-05 18:08:55 +02:00
Lulu13022002
b13c7dbe36
Add missing experimental field and annotations (#10653) 2024-05-05 09:00:54 -07:00
Bjarne Koll
7ae2c671c6
Keep components using single items in creative (#10664)
The craftbukkit implementation stores the old and new data patch of an
item during ItemStack#useOn(UseOnContext) to properly cancel events via
comparison and change detection of the component patch.

However, it uses #getComponentsPatch to fetch the new stack component
patch, which always yields an empty patch set if an itemstack is
considered empty by the game.
As the restoration of an itemstack's count to its previous state is
handled after the entire ItemStack#useOn method, items used in creative
mode temporarily have a count of zero, which causes craftbukkit to
consider their new component patch as EMPTY even tho said item may have
data.
The new patch is applied and, after useOn completes, the count is reset
if the player is in creative mode, leading to lost data.

This commit fixes said inconsistency by directly accessing the
components of the item via components#asPatch, storing the proper
component patch even for an item that temporarily has a count of zero.
2024-05-05 11:40:36 +02:00
Jake Potrebic
7401313e16
fix shear drops for wolf and bogged
Fixes #10661
2024-05-04 22:48:10 -07:00
Nassim Jahnke
6fcca46674
Add missing step in V3818 2024-05-04 22:50:20 +02:00
Jake Potrebic
5632210f10
add RegistryAccess for managing registries (#10154)
* add RegistryAccess for managing registries

* add missing types to key data generator

* fix some stuff

* Add RegistryKeys for all other non-server-backed registries

* fix tests

* remove Experimental annotations
2024-05-04 11:22:35 -07:00
Joseph Burton
156675c773
Fix lodestone compass target conversion 2024-05-04 12:58:06 +02:00
Joseph Burton
0db72ac19e
Fix can_place_on conversion and size check for item containers 2024-05-02 20:23:15 +02:00
Shane Freeder
59fe7ccc3b
default save-empty-scoreboard-teams to vanilla
The primary environmental factor which caused this feature to be implemented
is no longer much of a factor within the community
2024-05-02 09:53:43 +01:00
SoSeDiK
544ce20e01
Expose #hasColor to leather armor (#10638) 2024-05-01 19:14:42 +02:00
Nassim Jahnke
310b47bb96
Update Java version references, add note on var usages 2024-05-01 18:44:39 +02:00
Andrew Teeter
b8c454c2ba
Add damage check for mending (#10631) 2024-05-01 12:01:48 +02:00
SoSeDiK
4cfd9e25fa
Expose canReach to mob pathfinding API (#10636) 2024-05-01 12:00:11 +02:00
Jake Potrebic
fa6013d83b
Fixes beds not exploding in the nether
Also correctly marks the captured BlockState as "unplaced"
Fixes #10629
2024-04-30 16:42:43 -07:00
Nassim Jahnke
937a67a651
Add initial size cap to component map 2024-04-30 11:14:35 +02:00
Jason Penilla
3fdd0948b7
Fix sealed package check in BytecodeModifyingURLClassLoader (#10627) 2024-04-30 01:21:16 -07:00
Jake Potrebic
25e44bc63b
fix dumpitem command nbt format
use the snbt visitor instead of plain string
2024-04-29 18:49:19 -07:00
Jake Potrebic
812ccb96a4
fix spawnChunkRadius gamerule resetting
Fixes #10622
2024-04-29 15:22:29 -07:00
Noah van der Aa
44ee092878
1.20.6 (#10623) 2024-04-30 00:16:07 +02:00
Bjarne Koll
8f7ac62905
Validate manifest provided mapping namespace (#10612)
With plugins adopting paperweights mapping namespaces in their manifest
file in and after paper 1.20.5, incorrectly spelled namespaces
previously were simply implied as the spigot namespace.

This commit properly ensures plugin authors are using a known mapping
namespace in their manifest, avoiding down the line confusion on
incorrect remapping behaviour.

The commit also fixes two incorrect log parameters.
2024-04-28 20:43:50 -07:00
Jake Potrebic
f9397e108e
Fix incorrect Commodore mapping of sweeping enchant 2024-04-28 17:25:21 -07:00
Jake Potrebic
69a971a35c
Reset component prototype on itemtype change 2024-04-28 17:13:30 -07:00
Jason Penilla
05308fc299
Remap plugin libraries with namespace set to spigot (#10610)
* Remap plugin libraries with namespace set to spigot

* Remap plugin libraries with namespace set to spigot
2024-04-28 14:55:10 -07:00
Jason Penilla
7f2d5315fd
Rewrite reflection in library loader jars (#10608)
* Rewrite reflection in library loader jars

* Address todos
2024-04-28 13:14:10 -07:00
Jake Potrebic
61c9c07e95
Fix CraftMetaBlockState adding extra tags 2024-04-28 12:34:16 -07:00
Shane Freeder
52ff3b7382
Add itemName components (Resolves #10467) (#10471)
* Add itemName components (Resolves ##10467)

* improve javadocs and formatting

* rebased

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
2024-04-28 10:08:59 -07:00
Jake Potrebic
0f4d328fc1
final missing validation for data components 2024-04-28 09:46:33 -07:00
Nassim Jahnke
aed7dcab98
Fix overly strong name validation in player heads
Closes #10477
2024-04-28 18:25:32 +02:00
Jake Potrebic
4491ac05d1
respect hard list size limits in ItemMeta 2024-04-28 09:06:14 -07:00
Nassim Jahnke
9d6e7e3df0
Don't hard fail on plugin remap error
Closes #10474
2024-04-28 17:25:44 +02:00
Jake Potrebic
c4a1cd137a
Fix issue with empty lists in adventure predicates
Fixes #10473
2024-04-28 08:22:16 -07:00
Shane Freeder
37b3891032
Fix another missing book meta tag 2024-04-28 13:48:20 +01:00
Shane Freeder
6e31f385e3
Fix book meta lacking resolved tag from older versions (Fixes #10470) 2024-04-28 13:22:54 +01:00
Nassim Jahnke
1a03cc9b60
Fix test compilation 2024-04-28 14:20:52 +02:00
Jake Potrebic
306b203c2d
more fixes for ItemMeta relating to components 2024-04-27 22:27:51 -07:00
Jake Potrebic
e16263c39f
Fix firework meta NPE
Fixes #10466
2024-04-27 20:57:42 -07:00
caramel
a3c4dc95e3
Fix the incorrect codec usage in the Style convert (#10465) 2024-04-27 20:32:11 -07:00
Jason Penilla
f187fd696a
Only scan org.bukkit.craftbukkit.inventory in MetaHandledTagsTest
fixes tests OOMing
2024-04-27 18:25:15 -07:00
Jake Potrebic
d93c6f91f7
remove calls to DoNotUse methods 2024-04-27 18:18:20 -07:00
Jake Potrebic
3e90a19183
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:
304e83eb PR-1002: Improve documentation and implementation of getMaxStackSize
e8215ea2 SPIGOT-7638: Library loader does not seem to resolve every dependency
79c595c0 SPIGOT-7637: Bad logic in checking nullability of AttributeModifier slots

CraftBukkit Changes:
91b1fc3f1 SPIGOT-7644: Fix ItemMeta#getAsString
4e77a81e1 SPIGOT-7615: PlayerLeashEntityEvent cancelled eats lead
996f660f3 Do not remove leash knot if leasing to an existing leash knot gets cancelled
f70367d42 SPIGOT-7643: Fix inverted leash event cancelled usage and remove leash knot if no entity gets leashed
7ddb48294 SPIGOT-7640: Abnormal jumping height of wind charge
080c8711e SPIGOT-7639: Incoming plugin channels not working
ad549847e Open a direct connection instead of pinging mojang server to check if it is reachable
38e2926c5 SPIGOT-7365: DamageCause blocked by shield should trigger invulnerableTime
2024-04-27 18:00:01 -07:00
Jake Potrebic
d964c15e15
fix last test issue 2024-04-27 17:45:37 -07:00
Jake Potrebic
8ce62b3492
Fix issue with hopppers
Fixes #10464
2024-04-27 17:33:25 -07:00
Jake Potrebic
4ad6022ee3
improve checking handled tags in itemmeta (#9470) 2024-04-27 17:33:17 -07:00
Jason Penilla
83767f9544
Use JetBrains runtime for run tasks
allows for better runtime class redefinition

closes #10459
2024-04-27 17:28:40 -07:00
Jake Potrebic
d02bb811de
proper migration to gamerules for keep spawn loaded distance 2024-04-27 15:50:38 -07:00
Nassim Jahnke
dd571d89f2
Fix bad diff in build gradle file 2024-04-28 00:43:17 +02:00
Jake Potrebic
a771940776
Revert to vanilla handling of LivingEntity#actuallyHurt (#10463) 2024-04-27 14:35:53 -07:00
Jake Potrebic
b3ea907b77
more ItemFlag fixes 2024-04-27 14:32:34 -07:00
Jason Penilla
20af7a753c
remove funny diff 2024-04-27 14:11:35 -07:00
Jason Penilla
a390119b04
Move cb version definition to gradle patch 2024-04-27 14:02:33 -07:00
Jason Penilla
b7e148a107
Move obfhelper/stack deobf diff into original patch 2024-04-27 13:54:09 -07:00
Lulu13022002
af97400701
update generator 2024-04-27 22:32:16 +02:00
Jason Penilla
711dbd74ea
Bump adventure ansi serializer 2024-04-27 13:31:37 -07:00
Jason Penilla
e2552eea24
Start cleaning up plugin remapping patches 2024-04-27 13:27:01 -07:00
Lulu13022002
0b1b1fe067
fix helmet damage reduction inconsistencies
See: https://github.com/PaperMC/Paper/issues/9555#issuecomment-1681120506
2024-04-27 21:56:29 +02:00
Lulu13022002
55b1a8740d
fix PotionEffectType#getEffectAttributes 2024-04-27 21:48:14 +02:00
Spottedleaf
f933c35700 Update DataConverter to 1.20.6-rc1
Fixes trader llama inventory incorrectly converting
2024-04-27 12:41:47 -07:00
Jake Potrebic
c82766d436
fix item flags 2024-04-27 12:18:01 -07:00
Jason Penilla
f037f08035
Unify plugin remapping debug flags 2024-04-27 11:41:56 -07:00
Shane Freeder
5731f346e2
Restore Handle Large Packets Disconnecting Client Patch 2024-04-27 15:06:52 +01:00
Jake Potrebic
f85d423535
improve dumpitem and pgive commands 2024-04-26 23:57:49 -07:00
Jake Potrebic
91b5de66bf
bunch of fixes and improvements 2024-04-26 23:17:58 -07:00
Jake Potrebic
81f4405e26
add back hunk to async SavedData IO 2024-04-26 19:33:30 -07:00
Jake Potrebic
9bac3894e1
more fixes 2024-04-26 19:09:42 -07:00
Jake Potrebic
68e23db25d
add back missing call to profile fill events 2024-04-26 18:41:54 -07:00
Jake Potrebic
80bd01527f
fix adventure converters not using RegistryOps 2024-04-26 18:16:31 -07:00
Jake Potrebic
2f19f0fb7b
fix enchantment order issue 2024-04-26 18:06:41 -07:00
Jake Potrebic
f1fc1b30be
readd old UUID format patch 2024-04-26 17:41:36 -07:00
Jake Potrebic
c38f96b0e5
deprecate our ItemRarity API 2024-04-26 17:00:40 -07:00
Jake Potrebic
464cc81633
fix custom potion mixes 2024-04-26 16:17:14 -07:00
Jake Potrebic
4c53acedce
fix exact choice recipes 2024-04-26 15:25:20 -07:00
Jake Potrebic
882ea0a430
fix adventure translations 2024-04-26 15:08:39 -07:00
Jason Penilla
e856d17ec5
Update paper plugin check in PluginRemapper 2024-04-26 14:31:53 -07:00
Jake Potrebic
19ac9d43ce
remove no longer needed patches and fix tests 2024-04-26 14:29:21 -07:00
Jason Penilla
1bc278b125
Update patched spigot decompiler to fix inconsistency based on processing order 2024-04-26 11:45:56 -07:00
Jake Potrebic
44e68c301a
fix some more issues 2024-04-26 11:39:20 -07:00
Jake Potrebic
cc81668863
fix some issues on the todo list 2024-04-26 09:22:55 -07:00
Jake Potrebic
f6fae41cdf
fix chat_type issue 2024-04-26 08:33:00 -07:00
Owen1212055
00dac83d67
Drop old decompile fix 2024-04-26 08:39:10 -04:00
Nassim Jahnke
8b28f9f564
Fix accumulated total ticking chunks not being updated 2024-04-26 11:55:56 +02:00
Nassim Jahnke
478a971a7b
Fix light setting in protochunk 2024-04-26 11:18:15 +02:00
Nassim Jahnke
813cfbf2b0
Fix compile issues 2024-04-26 10:45:00 +02:00
Jake Potrebic
7e9da43b33
support patch versions in api-version 2024-04-25 23:29:16 -07:00
Jason Penilla
2997fd6459
plugin manager updates 2024-04-25 23:18:04 -07:00
Jake Potrebic
43d110e9a9
fix issue with item default attribute API 2024-04-25 23:10:38 -07:00
Jake Potrebic
bcdf1f96b8
fixup loom pattern select event patch 2024-04-25 22:44:49 -07:00
Jason Penilla
c5c2a5fe13
hunk system fixes 2024-04-25 22:25:02 -07:00
Jason Penilla
62b96c520f
compile fixes 2024-04-25 21:58:13 -07:00
Jason Penilla
867eb9054b
compile fixes 2024-04-25 20:15:07 -07:00
Jason Penilla
7c6411b930
compile fixes 2024-04-25 19:54:07 -07:00
Jake Potrebic
31ad90b018
some more compile fixes 2024-04-25 18:51:31 -07:00
Jake Potrebic
10e6143499
fixup adventure's book meta handling 2024-04-25 17:46:17 -07:00
Jake Potrebic
e85e1ec4a6
fixup sus effect entry patches 2024-04-25 17:10:12 -07:00
Jake Potrebic
3062eb208d
address my own comments 2024-04-25 16:24:08 -07:00
Nassim Jahnke
68aea43526
Fixup damage source change 2024-04-25 23:28:56 +02:00
Nassim Jahnke
2641c02193
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:
69fa4695 Add some missing deprecation annotations
f850da2e Update Maven plugins/versions
8d8400db Use regular compiler seeing as ECJ doesn't support Java 21 JRE
c29e1688 Revert "BUILDTOOLS-676: Downgrade Maven compiler version"
07bce714 SPIGOT-7355: More field renames and fixes
6a8ea764 Fix bad merge in penultimate commit
50a7920c Fix imports in previous commit
83640dd1 PR-995: Add required feature to MinecraftExperimental for easy lookups
fc1f96cf BUILDTOOLS-676: Downgrade Maven compiler version

CraftBukkit Changes:
90f1059ba Fix item placement
661afb43c SPIGOT-7633: Clearer error message for missing particle data
807b465b3 SPIGOT-7634: Armadillo updates infrequently
590cf09a8 Fix unit tests always seeing Mojang server as unavailable
7c7ac5eb2 SPIGOT-7636: Fix clearing ItemMeta
4a72905cf SPIGOT-7635: Fix Player#transfer and cookie methods
ebb50e136 Fix incorrect Vault implementation
b33fed8b7 Update Maven plugins/versions
6f00f0608 SPIGOT-7632: Control middle clicking chest does not copy contents
db821f405 Use regular compiler seeing as ECJ doesn't support Java 21 JRE
8a2976737 Revert "BUILDTOOLS-676: Downgrade Maven compiler version"
0297f87bb SPIGOT-7355: More field renames and fixes
2d03bdf6a SPIGOT-7629: Fix loading banner patterns
e77951fac Fix equality of deserialized display names
c66f3e4fd SPIGOT-7631: Fix deserialisation of BlockStateMeta
9c2c7be8d SPIGOT-7630: Fix crash saving unticked leashed entities
8c1e7c841 PR-1384: Disable certain PlayerProfile tests, if Mojang's services or internet are not available
ced93d572 SPIGOT-7626: sendSignChange() has no effect
c77362cae SPIGOT-7625: ItemStack with lore cannot be serialized in 1.20.5
ff2004387 SPIGOT-7620: Fix server crash when hoppers transfer items to double chests
8b4abeb03 BUILDTOOLS-676: Downgrade Maven compiler version
2024-04-25 23:23:57 +02:00
Nassim Jahnke
ed790385ed
More compile fixes 2024-04-25 22:47:32 +02:00
Nassim Jahnke
8d3759d4a5
More more compile fixes 2024-04-25 22:34:46 +02:00
Nassim Jahnke
d01f6b2fd2
Fix more compile issues 2024-04-25 21:57:59 +02:00
Jason Penilla
ca9001a936
compile fixes 2024-04-25 12:16:00 -07:00
Jason Penilla
820f999ba4
Fixes for cb pkg ver 2024-04-25 11:16:53 -07:00
Noah van der Aa
04a25c2813
Fix WorldCreator#keepSpawnLoaded 2024-04-25 19:57:27 +02:00
Bjarne Koll
b984f66d13
Missing FQN in CraftPotionBrewer getter 2024-04-25 19:45:17 +02:00
Bjarne Koll
9c580566b9
Some more compilation fixes 2024-04-25 19:42:24 +02:00
Noah van der Aa
f4c7639986
Un-jankify root user detection 2024-04-25 19:13:12 +02:00
Bjarne Koll
bab31b6f55
Update Enchantment damage increase API
The Enchantment damage increase API added previously used the
EntityCategory enum as a parameter. These values are now however
determined by tags instead of the categories themselves.

Deprecated the outdated api method, create a new overload that takes
EntityType instead and implement deprecated method by guessing an entity
type from the builtin registry based on the category passed.
This method allows
a) the tags to still be modified and the legacy
   method still respecting such.
b) potential cursed implementations of enchantments of plugins to not
   break that override the getDamageBonus method on Enchantment.
2024-04-25 18:42:50 +02:00
Jake Potrebic
653f0432b5
readd fix bee aging patch 2024-04-25 09:06:13 -07:00
Jake Potrebic
ccf158a817
update smithing recipe copy data components API 2024-04-25 08:13:36 -07:00
Owen1212055
457e2c8a5a
pass more stuff 2024-04-25 09:01:54 -04:00
Owen1212055
45900385cd
Fix properly resend patches 2024-04-25 08:42:47 -04:00
Owen1212055
345b5c1c4c
Patches!!!!!!! (we are done) 2024-04-25 08:36:48 -04:00
Nassim Jahnke
6da0d8cc91
(Almost) all patches applied 2024-04-25 14:23:55 +02:00
Nassim Jahnke
2debcaff9d
More more patches, including hopper optimization patch 2024-04-25 14:07:39 +02:00
Nassim Jahnke
c9907c650f
More patches 2024-04-25 13:02:27 +02:00
Nassim Jahnke
ec4ada852e
Apply and move up non-optimization patches 2024-04-25 12:27:57 +02:00
Nassim Jahnke
f6ea3736a7
Patches 2024-04-25 11:42:10 +02:00
Spottedleaf
e9eec78fc7 chunk system 2024-04-25 01:52:52 -07:00
Spottedleaf
ec9f7e3850 starlight 2024-04-25 00:14:22 -07:00
Spottedleaf
6a87d141f3 dataconverter 2024-04-24 23:49:13 -07:00
Jason Penilla
b673721d77
compile fixes 2024-04-24 22:29:18 -07:00
Jason Penilla
690b1cd321
compile fixes 2024-04-24 22:16:04 -07:00
Jason Penilla
25f7c68e6b
compile fixes 2024-04-24 21:38:28 -07:00
Jason Penilla
ce0e78c103
compile fixes
compile fixes

compile fixes
2024-04-24 21:18:42 -07:00
Jake Potrebic
1444b3632e
work on adventure 2024-04-24 20:14:51 -07:00
Jason Penilla
bb1351cb8d
some work on adventure 2024-04-24 18:10:18 -07:00
Jason Penilla
c95db4fcaa
adventure 4.17.0-SNAPSHOT 2024-04-24 17:46:57 -07:00
Jason Penilla
b7338094a5
Drop conduit api patch (upstream implemented same api with same method signatures) 2024-04-24 17:40:30 -07:00
Jason Penilla
1df7e21459
Apply more API-implementing patches 2024-04-24 17:36:24 -07:00
Jake Potrebic
11044315fd
955 2024-04-24 16:25:57 -07:00
Owen1212055
e0a245d2ea
Patches!!!!!!! 2024-04-24 18:36:55 -04:00
Jason Penilla
051855997e
Update reflection rewriter to 0.0.1 release 2024-04-24 15:02:37 -07:00
Noah van der Aa
961782982b
Restore original formatting for MC-252817 patch 2024-04-24 23:26:18 +02:00
Noah van der Aa
4d9e824a44
more more work (806) 2024-04-24 23:23:56 +02:00
Noah van der Aa
22227ccf26
more more work (757) 2024-04-24 22:32:38 +02:00
Noah van der Aa
71ae391eb3
more work (721) 2024-04-24 22:05:42 +02:00
Jason Penilla
90095cd7c4
694 2024-04-24 11:03:59 -07:00
Jason Penilla
fc5c0dae7f
683 2024-04-24 10:59:51 -07:00
Nassim Jahnke
4e654f2a3a
More patch work 2024-04-24 19:27:48 +02:00
Nassim Jahnke
1de0dc8828
666 plus 1 2024-04-24 17:35:46 +02:00
Owen1212055
21afc0a2e2
Patches!!!!!!! 2024-04-24 10:30:32 -04:00
Owen1212055
a403a8d085
Patches!!!!!!! 2024-04-24 10:29:12 -04:00
Owen1212055
2d9d0d8b1d
Patches! 2024-04-24 09:46:45 -04:00
Owen1212055
5be858e9b7
Patches! 2024-04-24 08:11:27 -04:00
Jake Potrebic
cc4614854a
405 2024-04-23 23:44:48 -07:00
Jake Potrebic
9079c90d22
354 2024-04-23 23:05:14 -07:00
Jake Potrebic
1d7d7e92f2
301 2024-04-23 22:43:09 -07:00
Jake Potrebic
309ebc13fc
253 2024-04-23 19:46:06 -07:00
Jake Potrebic
8244815161
221 2024-04-23 19:21:40 -07:00
Owen1212055
906f906089
Patches! 2024-04-23 18:25:14 -07:00
Owen1212055
0225537fd1
Update upstream 2024-04-23 21:13:33 -04:00
Owen1212055
487555b627
update 2024-04-23 21:13:33 -04:00
Jason Penilla
d07c487d4d
Don't use defaultToolchain method for run tasks 2024-04-23 14:39:36 -07:00
Jason Penilla
2eeed9e6fa
41 2024-04-23 14:31:37 -07:00
Jason Penilla
9cac5b6f4f
Fix continueServerUpdate with 2-line subjects 2024-04-23 14:26:28 -07:00
Jason Penilla
eb41348d39
33 2024-04-23 14:12:24 -07:00
Jason Penilla
ffccfd5488
Apply timings 2024-04-23 14:04:59 -07:00
Jason Penilla
598a1cb947
Apply shadow removal patch 2024-04-23 13:41:25 -07:00
Jason Penilla
dd6ce09922
Fix reflection diff and order wrt commodore diff 2024-04-23 13:36:31 -07:00
Nassim Jahnke
7cdf804392
Work 2024-04-23 22:13:16 +02:00
Jake Potrebic
ef057bba7d
work on Adventure patch 2024-04-23 11:32:19 -07:00
Jake Potrebic
f2c45ed1d3
do some work 2024-04-23 11:03:16 -07:00
Jake Potrebic
abc49bf069
Begin update to 1.20.5 2024-04-23 10:02:08 -07:00
Jake Potrebic
a6b6ecdd22
More Raid API (#7537) 2024-04-20 15:57:51 -04:00
Tamion
fc53ff5a71
Add Configuration for finding Structures outside World Border (#10437) 2024-04-20 15:29:32 -04:00
Janet Blackquill
c5f68ff9be
Add CartographyItemEvent and get/setResult for CartographyInventory (#10396) 2024-04-20 14:10:35 -04:00
Florian Beck
a033033b7a
Added chunk view API (#10398) 2024-04-20 13:56:59 -04:00
Nassim Jahnke
3af1346520
Allow setting player list name early 2024-04-20 15:24:42 +02:00
Tamion
908b8141c9
Fix inventory desync with PlayerLeashEntityEvent (#10436) 2024-04-19 20:23:32 -07:00
Jake Potrebic
3b078f822a
Add API for ticking fluids (#10435)
* Add API for ticking fluids

* update javadocs
2024-04-19 13:03:32 -07:00
brickmonster
9e886c4310
Remove dead code (LegacyResult) (#10411)
* Stop firing AsyncPlayerChatPreviewEvent as chat preview was removed in 1.19.3. This is in parity with upstream

* formatting and small tweaks

* correctly set MESSAGE_CHANGED flag for modern modifications

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
2024-04-19 12:47:24 -07:00
Jason Penilla
862299b6a6
"Downgrade" Vineflower to 1.10.1 release (#10423)
* "Downgrade" Vineflower to 1.10.1 release

The main thing we lose from the 1.11 snapshots is a recent fix for redundant casts.

* Thanks intellij

* a
2024-04-16 12:44:59 -07:00
Owen
4445d23544
Deprecate ItemStack#setType & add ItemStack#withType (#10290) 2024-04-12 17:16:22 -04:00
Cross
f061e76e1f
Fix hit criteria advancement triggered before changing state (#10409)
* Fix hit criteria advancement being triggered before changing block state.

* Rebase

---------

Co-authored-by: Bjarne Koll <lynxplay101@gmail.com>
2024-04-12 12:42:00 -07:00
Shane Freeder
46d462b83e
Fix StackOverflowException thrown on shutdown (Fixes #10404) (#10408)
paper previously migrated away from using executeIfPossible as this throws a
RejectedExecutionException when the server is shutting down, which is then picked
up by the Connection handler object and causes the player to be kicked without
the intended disconnection message that comes from commands such as /stop, /restart

This was fine, because previously changes made in spigot would just prevent these
packets from being executed anyways. Instead, we'll just use a marker exception
to try to detect this specific state.
2024-04-12 12:37:00 -07:00
Jake Potrebic
526795bacd
Update patches to handle vineflower decompiler (#10406)
* Update patches to handle vineflower decompiler

* update patches again to handle inlined simple lambdas

* update vf again and re-apply/rebuild patches

* update patches after removal of verify-merges flag

* fix compile issue

* remove maven local

* fix some issues

* address more issues

* fix collision patch

* use paperweight release

* more fixes

* update fineflower and fix patches again

* add missing comment descriptor

---------

Co-authored-by: Jason Penilla <11360596+jpenilla@users.noreply.github.com>
2024-04-12 12:14:06 -07:00
gecko10000
a7f1dc6a07
Change online mode default for Velocity configuration (#10413) 2024-04-12 18:21:31 +01:00
Shane Freeder
1207162055
Allow player-list API to self un/list (#10358) 2024-04-06 20:45:43 -04:00
Joseph Burton
241d8e26fb
Ignore minecart in activation range (#10359) 2024-04-06 19:50:43 -04:00
Noah van der Aa
8e75001cb8
Disable vertical air friction when item entities have friction disabled (#10369) 2024-04-06 19:36:59 -04:00
Evan
3d31e45e7e
Add BlockBreakProgressUpdateEvent (#10300) 2024-04-06 18:28:17 -04:00
Lulu13022002
acf838f535
Backport some stuff from the generators branch (#10365) 2024-04-06 14:51:47 -07:00
Tamion
182e79bce1
Add more item use API (#10304) 2024-04-06 17:44:27 -04:00
Lulu13022002
d8456ee65b
Don't throw NPE for unplaced blockstate on #getDrops (#10366) 2024-04-06 17:26:56 -04:00
Pierpaolo Coletta
06361fa662
Fix invalid block entities created during world gen (#10375) 2024-04-06 17:16:54 -04:00
Bridge
a774fbaca8
feat: Entity#teleportAsync method with TeleportFlags (#10371)
* feat: Entity#teleportAsync method with TeleportFlags

* use method-local class

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
2024-04-06 13:38:37 -07:00
Jake Potrebic
bd38e0318a
Updated Upstream (Bukkit/CraftBukkit) (#10379)
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:
f02baa38 PR-988: Add World#getIntersectingChunks(BoundingBox)
9321d665 Move getItemInUse up to LivingEntity
819eef73 PR-959: Add access to current item's remaining ticks
c4fdadb0 SPIGOT-7601: Add AbstractArrow#getItem
be8261ca Add support for Java 22
26119676 PR-979: Add more translation keys
66753362 PR-985: Correct book maximum pages and characters per page documentation
c8be92fa PR-980: Improve getArmorContents() documentation
f1120ee2 PR-983: Expose riptide velocity to PlayerRiptideEvent

CraftBukkit Changes:
dfaa89bbe PR-1369: Add World#getIntersectingChunks(BoundingBox)
51bbab2b9 Move getItemInUse up to LivingEntity
668e09602 PR-1331: Add access to current item's remaining ticks
a639406d1 SPIGOT-7601: Add AbstractArrow#getItem
0398930fc SPIGOT-7602: Allow opening in-world horse and related inventories
ffd15611c SPIGOT-7608: Allow empty lists to morph to any PDT list
2188dcfa9 Add support for Java 22
45d6a609f SPIGOT-7604: Revert "SPIGOT-7365: DamageCause blocked by shield should trigger invulnerableTime"
06d915943 SPIGOT-7365: DamageCause blocked by shield should trigger invulnerableTime
ca3bc3707 PR-1361: Add more translation keys
366c3ca80 SPIGOT-7600: EntityChangeBlockEvent is not fired for frog eggs
06d0f9ba8 SPIGOT-7593: Fix sapling growth physics / client-side updates
45c2608e4 PR-1366: Expose riptide velocity to PlayerRiptideEvent
29b6bb79b SPIGOT-7587: Remove fixes for now-resolved MC-142590 and MC-109346
2024-04-06 12:53:39 -07:00
Jason Penilla
a2035440cf
build: Compile against and shade the filtered jar (#9747)
* Compile against & shade the filtered jar

* Move check for if the paper asset root needs to be pushed

* Don't disable incremental compilation

* Remove mavenLocal

* use paperweight release
2024-04-04 17:12:05 -07:00
DungeonDev
e709245b55
Add config option for tripwire disarming fix
Fixes #10382

Co-authored-by: Tamion <70228790+notTamion@users.noreply.github.com>
2024-04-02 12:18:22 +02:00
Jason Penilla
45d1486fec
build: Update paperweight to 1.5.12 and Gradle Wrapper to 8.7 (#10361) 2024-03-29 10:43:36 -07:00
Jake Potrebic
710dced8b7
[ci skip] move custom brig exception to paper package 2024-03-26 08:38:26 -07:00
Nassim Jahnke
00fd87a10f
Return dummy string instead of empty optional 2024-03-25 13:26:01 +01:00
maxcom1
b6001403e9
Add methods to change entity physics (#10334) 2024-03-23 17:26:17 -04:00
FireInstall
9ec7dfcbc4
Move invisible setting up to entities (#10346) 2024-03-23 20:27:30 +01:00
Shane Freeder
88419b2075
Do not copy profile data if profiles are the same (#10259) 2024-03-20 22:47:50 +01:00
TonytheMacaroni
41ffa0cf8c
Expose power on fireballs (#10302) 2024-03-20 22:33:34 +01:00
maxcom1
05fe15e0fc
Fire EntityChangeBlockEvent on beehive nectar deposit (#10306)
* Add BeehiveNectarDepositEvent

* Fire EntityChangeBlockEvent instead of a separate event
2024-03-20 12:35:10 -07:00
Nassim Jahnke
55ffcb1111
Fix tripwire disarming not working as intended 2024-03-19 20:09:02 +01:00
viciscat
99a641690a
Expand Hopper BlockState API (#10328) 2024-03-16 20:28:50 +01:00
Jake Potrebic
d361a7f609
Fix DamageSource API (#10307)
Uses the correct entity in the EntityDamageByEntity event
Returns the correct entity for API's DamageSource#getCausingEntity
2024-03-16 11:51:22 -07:00
leguan
e6034867ba
Add onboarding message for initial server start (#10312) 2024-03-16 19:10:26 +01:00
Suppergerrie2
ab1afb0ed8
Fix missing profiler.pop() in PathFinder::findPath (#10320) 2024-03-15 11:09:47 +00:00
Bjarne Koll
62b220a87f
Allow passenger retaining teleport via end gateway (#10283)
Previously paper disabled the abilities for entities to teleport via end
gateways if they were being used as a vehicle.

While the behaviour generally worked fine for entities riding other
entities, players would quickly end up in an invalid state, not seeing
their passenger anymore.

This commit removes the paper introduced limitation by now properly
updating the passengers location of a player when they are teleporting
through an end gateway.
2024-03-10 01:08:44 +01:00
Jake Potrebic
80e1a45959
Add param to overrides to the correct method is called (#10308) 2024-03-09 18:16:27 -05:00
Jake Potrebic
a0931f4864
Updated Upstream (Bukkit/CraftBukkit) (#10301)
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:
7ca2b46c SPIGOT-7594: Fix typo and include missing MinecraftExperimental annotation in Loot Table enum

CraftBukkit Changes:
176c0ad39 Fix copying BlockStates with fields (eg, Banner)
ee685bd2a Fix Camel not standing up when hurt
619936d4b Increase outdated build delay
2024-03-08 15:52:00 -08:00
Jake Potrebic
6ad63fba30
Per world ticks per spawn settings (#6891) 2024-03-03 17:53:58 -05:00
Owen
89d51d5f29
Allow enabling sand duping (#10191)
Because this exploit has been widely known for years and has not been fixed by Mojang, we decided that it was worth allowing people to toggle it on/off due to how easy it is to make it configurable.

It should be noted that this decision does not promise all future exploits will be configurable.
2024-03-03 17:05:34 -05:00
Yannick Lamprecht
b21eb4d9a4
add overloads to use suspicious effect entry to mushroom cow and suspicious stew meta (#10245)
The existing method with PotionEffect suggests that all attributes are used. In fact, only the PotionEffectType and the duration are used.



---------

Co-authored-by: Bjarne Koll <lynxplay101@gmail.com>
2024-03-03 16:40:18 -05:00
Shane Freeder
60218cd207
Don't tick empty worlds (#9025) 2024-03-03 16:10:45 -05:00
Gero
ce5c8dd379
Configurable max block/fluid ticks (#10266) 2024-03-03 15:43:00 -05:00
Yannick Lamprecht
bbc03d8116
improve BanList types (#10239) 2024-03-03 12:36:17 -08:00
Rodney
8870d22bc7
Fire EntityDamageByEntityEvent for unowned wither skulls patch (#10244) 2024-03-03 14:35:50 -05:00
granny
54a23403da
check if itemstack is stackable first (#10285) 2024-03-03 10:37:00 -08:00
Nassim Jahnke
681bbff110
Fix spawnreason saving 2024-02-23 23:15:11 +01:00
Bjarne Koll
d0ebfbbd15
Fix corrupted plugin.yml breaking plugin loading (#10279)
Fix corrupted plugin.yml file in one plugin not loading any plugins by
the server.

Co-authored-by: Aleksander Jagiello <themolkapl@gmail.com>
2024-02-23 18:54:44 +01:00
Shane Freeder
e3bc4c4107
Make debug mode print current configuration phase 2024-02-23 13:54:52 +00:00
Nassim Jahnke
71c84c8132
Updated Upstream (Bukkit/CraftBukkit/Spigot) (#10277)
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:
9a80d38c SPIGOT-336, SPIGOT-3366, SPIGOT-5768, SPIGOT-6409, SPIGOT-6861, PR-722: Add EntityRemoveEvent
258086d9 SPIGOT-7417, PR-967: Add Sign#getTargetSide and Sign#getAllowedEditor
ffaba051 SPIGOT-7584: Add missing Tag.ITEMS_NON_FLAMMABLE_WOOD

CraftBukkit Changes:
98b6c1ac7 SPIGOT-7589 Fix NullPointerException when bans expire
a2736ddb0 SPIGOT-336, SPIGOT-3366, SPIGOT-5768, SPIGOT-6409, SPIGOT-6861, PR-1008: Add EntityRemoveEvent
5bf12cb89 SPIGOT-7565: Throw a more descriptive error message when a developer tries to spawn an entity from a CraftBukkit class
76d95fe7e SPIGOT-7417, PR-1343: Add Sign#getTargetSide and Sign#getAllowedEditor

Spigot Changes:
e9ec5485 Rebuild patches
f1b62e0c Rebuild patches
2024-02-23 14:37:33 +01:00
Shane Freeder
3ea95efdeb
Do not access world state to see if we can see a Player
Thrown into the adventure patch because I don't see the justification of a patch existing
for something like this.
2024-02-22 16:23:15 +00:00
Nassim Jahnke
4939f87118
Add more ResourceLocation checks, some cleanup 2024-02-18 13:52:12 +01:00
Jason Penilla
351923d17e
Run round-trip adventure codec tests with JSON, NBT, and Java ops. Use JavaOps for conversions. (#10031) 2024-02-17 16:58:56 -05:00
viciscat
d95341e44a
FluidState API (#9951)
* Add new FluidState API functionality
---------

Co-authored-by: Bjarne Koll <lynxplay101@gmail.com>
Co-authored-by: Owen1212055 <23108066+Owen1212055@users.noreply.github.com>
2024-02-17 15:44:03 -05:00
David Mayr
1964b22439
Scoreboard objective number format api (#10036)
* feat: number format api

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: make each individual score customizable

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* docs: fix incorrect descriptions

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: use access transformers

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: use adventure codecs

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* test: test for matching styles

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: convert number formats to interfaces

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: add style conversion to adventure patch

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: use paper adventure method in PaperScoreboardFormat

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* chore: rename methods to avoid a method in records

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* fix: check if objective is still registered

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: improve style conversion

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: modify how the getter behaves in score

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: use fluent naming

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* docs: add spaces before the paper comments

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* chore: styling changes

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* chore: make constant final

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* feat: add methods for styled format instead of constants

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* fix: remove incorrect getTrackedPlayers check

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* docs: add . at the end of sentences

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* docs: explain null behaviour

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* docs: mention score creation

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>

* rebase and fix javadoc comments

* remove server implementation defaults

* fix format for PaperScoreboardFormat

---------

Signed-off-by: David Mayr <davidliebtkekse@gmail.com>
Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
2024-02-17 12:22:00 -08:00
Jake Potrebic
7ccefdcd6c
Fire entity knockback event for ownerless tnt (#7171) 2024-02-16 15:44:43 -08:00
Pedro
37df12143c
Fix BlockState being set to null for damage events (#10252) 2024-02-15 10:05:50 +01:00
Nassim Jahnke
31699ae9a8
Updated Upstream (Bukkit/CraftBukkit) (#10242)
* 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:
a6a9d2a4 Remove some old ApiStatus.Experimental annotations
be72314c SPIGOT-7300, PR-829: Add new DamageSource API providing enhanced information about entity damage
b252cf05 SPIGOT-7576, PR-970: Add methods in MushroomCow to change stew effects
b1c689bd PR-902: Add Server#isLoggingIPs to get log-ips configuration
08f86d1c PR-971: Add Player methods for client-side potion effects
2e3024a9 PR-963: Add API for in-world structures
a23292a7 SPIGOT-7530, PR-948: Improve Resource Pack API with new 1.20.3 functionality
1851857b SPIGOT-3071, PR-969: Add entity spawn method with spawn reason
cde4c52a SPIGOT-5553, PR-964: Add EntityKnockbackEvent

CraftBukkit Changes:
38fd4bd50 Fix accidentally renamed internal damage method
80f0ce4be SPIGOT-7300, PR-1180: Add new DamageSource API providing enhanced information about entity damage
7e43f3b16 SPIGOT-7581: Fix typo in BlockMushroom
ea14b7d90 SPIGOT-7576, PR-1347: Add methods in MushroomCow to change stew effects
4c687f243 PR-1259: Add Server#isLoggingIPs to get log-ips configuration
22a541a29 Improve support for per-world game rules
cb7dccce2 PR-1348: Add Player methods for client-side potion effects
b8d6109f0 PR-1335: Add API for in-world structures
4398a1b5b SPIGOT-7577: Make CraftWindCharge#explode discard the entity
e74107678 Fix Crafter maximum stack size
0bb0f4f6a SPIGOT-7530, PR-1314: Improve Resource Pack API with new 1.20.3 functionality
4949f556d SPIGOT-3071, PR-1345: Add entity spawn method with spawn reason
20ac73ca2 PR-1353: Fix Structure#place not working as documented with 0 palette
3c1b77871 SPIGOT-6911, PR-1349: Change max book length in CraftMetaBook
333701839 SPIGOT-7572: Bee nests generated without bees
f48f4174c SPIGOT-5553, PR-1336: Add EntityKnockbackEvent
2024-02-11 22:28:00 +01:00
Warrior
cde5587e58
Add getChunkSnapshot includeLightData parameter (#10234) 2024-02-10 22:28:56 +01:00
Emilia Kond
4b58a85158
Fire BlockPreDispenseEvent for droppers (#10226) 2024-02-10 22:19:22 +01:00
Jake Potrebic
e6a521514e
Properly track the changed item from dispense events (#8658) 2024-02-10 22:17:24 +01:00
Jake Potrebic
2fa2d32ceb
Fix possible StackOverflowError for some dispenser iteractions (#8524) 2024-02-10 21:17:40 +01:00
Lulu13022002
bf6e803c6c
Fix WaterBottleSplashEvent not forwarding hit result (#10203) 2024-02-10 20:27:29 +01:00
Warrior
99bae594c8
Propagate failed to bind to port error (#10235) 2024-02-10 20:23:50 +01:00