4218 Commits

Author SHA1 Message Date
Flo0
dfaa89bbe3
#1369: Add World#getIntersectingChunks(BoundingBox) 2024-04-01 09:43:49 +11:00
md_5
51bbab2b9f
Move getItemInUse up to LivingEntity 2024-03-30 12:54:26 +11:00
gIsForGravity
668e09602c
#1331: Add access to current item's remaining ticks 2024-03-30 12:54:20 +11:00
md_5
a639406d1e
SPIGOT-7601: Add AbstractArrow#getItem 2024-03-30 12:17:57 +11:00
md_5
0398930fc7
SPIGOT-7602: Allow opening in-world horse and related inventories 2024-03-30 12:08:32 +11:00
Bjarne Koll
ffd15611c7
SPIGOT-7608: Allow empty lists to morph to any PDT list
The minecraft serialisation logic for ListTag updates the type byte of
the list tag during writing to match either the first element in the
list or 0, if said list tag is empty.
As such, list content type information cannot be carried through a
write/read process, e.g. chunk load/unload or a creative client updating
the item.

The recently introduced persistent data type collections for lists hence
can also not enforce a specific list content type if the found list is
empty, which it currently attempts to do.
As such, a call to PersistentDataContainer#has would also yield false
for any empty list as the lists type byte would be 0.

The faulty behaviour has been fixed by considering an empty list in the
persistent data container to match any list type.
This change, while technically breaking the #has check, is needed and
reasonable as the #has check for this is currently broken in the first
place as described above.
2024-03-30 10:46:03 +11:00
md_5
2188dcfa91
Add support for Java 22 2024-03-29 21:23:37 +11:00
Miles Holder
ca3bc37075
#1361: Add more translation keys 2024-03-17 10:26:55 +11:00
2008Choco
45c2608e4d
#1366: Expose riptide velocity to PlayerRiptideEvent 2024-03-10 09:27:44 +11:00
md_5
176c0ad39f
Fix copying BlockStates with fields (eg, Banner) 2024-03-06 06:57:15 +11:00
md_5
619936d4bb
Increase outdated build delay 2024-02-29 06:49:54 +11:00
DerFrZocker
a2736ddb06
SPIGOT-336, SPIGOT-3366, SPIGOT-5768, SPIGOT-6409, SPIGOT-6861, #1008: Add EntityRemoveEvent 2024-02-21 20:55:34 +11:00
DerFrZocker
5bf12cb89d
SPIGOT-7565: Throw a more descriptive error message when a developer tries to spawn an entity from a CraftBukkit class 2024-02-17 14:04:58 +11:00
Jishuna
76d95fe7ed
SPIGOT-7417, #1343: Add Sign#getTargetSide and Sign#getAllowedEditor 2024-02-17 14:02:38 +11:00
Doc
80f0ce4be6
SPIGOT-7300, #1180: Add new DamageSource API providing enhanced information about entity damage 2024-02-11 09:54:25 +11:00
Doc
ea14b7d901
SPIGOT-7576, #1347: Add methods in MushroomCow to change stew effects 2024-02-08 22:54:51 +11:00
Doc
4c687f2433
#1259: Add Server#isLoggingIPs to get log-ips configuration 2024-02-07 07:09:34 +11:00
md_5
22a541a29f
Improve support for per-world game rules 2024-02-04 10:54:20 +11:00
Jishuna
cb7dccce27
#1348: Add Player methods for client-side potion effects 2024-02-04 10:10:30 +11:00
coll1234567
b8d6109f0c
#1335: Add API for in-world structures 2024-02-04 10:04:35 +11:00
Doc
4398a1b5b9
SPIGOT-7577: Make CraftWindCharge#explode discard the entity 2024-02-04 09:57:17 +11:00
md_5
0bb0f4f6a0
SPIGOT-7530, #1314: Improve Resource Pack API with new 1.20.3 functionality 2024-01-31 22:02:45 +11:00
DerFrZocker
4949f556d9
SPIGOT-3071, #1345: Add entity spawn method with spawn reason 2024-01-31 20:08:05 +11:00
DerFrZocker
3c1b778713
SPIGOT-6911, #1349: Change max book length in CraftMetaBook 2024-01-31 19:59:28 +11:00
DerFrZocker
333701839f
SPIGOT-7572: Bee nests generated without bees 2024-01-27 14:59:22 +11:00
Jishuna
f48f4174c3
SPIGOT-5553, #1336: Add EntityKnockbackEvent 2024-01-27 14:53:41 +11:00
Doc
b44bf5aa87
SPIGOT-7575: SuspiciousStewMeta creates invalid PotionEffect data 2024-01-24 21:45:52 +11:00
DerFrZocker
161784713a
#1340: Centralize the conversion from and to Minecraft / Bukkit registry items even more and add a test case for them 2024-01-22 20:36:36 +11:00
Nothixal
b93c5a30d2
#1338: Introduce getRespawnLocation as a replacement for getBedSpawnLocation 2024-01-22 20:27:09 +11:00
md_5
fb973486c2
SPIGOT-7570: PrepareItemCraftEvent#isRepair() always returns false 2024-01-18 22:19:05 +11:00
DaFeist
c9c24535ef
#1337: Add DragonBattle#setPreviouslyKilled 2024-01-17 18:23:36 +11:00
Nothixal
c8b4da803d
SPIGOT-6921, #1330: Add methods to remove all enchantments on an ItemStack 2024-01-16 07:38:55 +11:00
Jishuna
95bc1c4f52
#1333: Add BlockData#copyTo 2024-01-15 20:33:17 +11:00
Nothixal
36e2f9ce1e
#1329: Add method to get an offline player's location 2024-01-15 20:30:41 +11:00
Jishuna
771182f70c
#1327: Add methods to place structures with block/entity transformers 2024-01-10 18:44:31 +11:00
md_5
76931e8bd4
Add EntityMountEvent and EntityDismount Event
Adapted from Spigot commit ab1e1a2a5ae1e6cc42afe8bf48832721407365fd.
2024-01-07 08:59:55 +11:00
DerFrZocker
9b29b21c76
#1183: Better handle lambda expression and renaming of classes in Commodore 2024-01-06 16:15:23 +11:00
md_5
1462ebe85d
Reformat Commodore.java 2024-01-06 16:15:21 +11:00
Miles Holder
9fde4c037c
#1324: Improve ItemFactory#enchantItem consistency 2024-01-06 16:07:58 +11:00
Bjarne Koll
4e419c774c
#1295: Define native persistent data types for lists 2024-01-06 16:03:58 +11:00
md_5
dd8cca3882
SPIGOT-7562: Fix Score#getScore and Score#isScoreSet 2024-01-05 14:18:13 +11:00
Maxim Van de Wynckel
6902782005
Only fetch an online UUID in online mode
The previous code would get an online UUID even in offline mode that
breaks plugins if the player joins.

Example: You want to store data for player "Test" who never joined. An
online UUID is created and you save it using that UUID.

The player Test joins with an offline UUID but that will not match the
online UUID of the saved data.

Adapted from Spigot commit 25b673fd7e418e21eb445a9e39d51baa0c0ab8b6
2023-12-31 10:46:30 +11:00
DerFrZocker
2e88514ad3
#1325: Use CraftBlockType and CraftItemType instead of CraftMagicNumbers to convert between minecraft and bukkit block / item representation 2023-12-29 08:36:38 +11:00
BlackHole
53ebb05e39
SPIGOT-7554, #1323: Add DecoratedPotInventory 2023-12-28 08:07:06 +11:00
blablubbabc
7df18510f6
SPIGOT-7555: Don't cast ItemFlags to byte
This fixes an issue with the HIDE_ARMOR_TRIM flag being lost during item
deserialization.
2023-12-27 11:15:24 +11:00
DerFrZocker
bcf56171a6
#1321: Clean up some stuff which got missed during previous PRs
- Add missing CraftBukkit comment to CommandGive
- Remove no longer needed IRegistryCustom from CraftStructure conversion
- Use setBasePotionType instead of deprecated setBasePotionData
2023-12-26 07:44:21 +11:00
md_5
752aac6697
Implement APIs for per world view and simulation distances 2023-12-23 14:32:49 +11:00
drXor
57d7ef433c
Preserve empty enchantment tags for glow effect
Adapted from Spigot commit cc9a1a417f1ac95a7957db8636e31c8fc2baf4e9.
2023-12-23 12:50:04 +11:00
md_5
465ec3fb42
Remove connected check on setScoreboard
No other API uses such a check and it has been removed in Spigot since f7086eb96d9977d717af75c0dd2eb38349b2df2b in 2013.
2023-12-23 08:39:28 +11:00
md_5
f90ce621ef
Use one PermissibleBase for all command blocks
Inspired by Spigot commit 4bd27f7d0f8dcffab0062741416a612ea258dc68 by FrozenBrain.
2023-12-23 08:28:06 +11:00