698 Commits

Author SHA1 Message Date
Auxilor
f1187a24c7
#778: Added get/set ItemStack methods to trident 2021-01-02 08:49:22 +11:00
md_5
72c5e7477a
SPIGOT-6273: Expose ItemFrame ItemDropChance through API 2020-12-28 08:58:39 +11:00
montlikadani
22d7fcc98f
SPIGOT-6256: Add method to check if the entity is in water 2020-12-21 18:20:54 +11:00
Martoph
424598d294
#752: Add the ability to retrieve hit, step, fall, and other sounds from blocks. 2020-11-26 09:36:57 +11:00
Phoenix616
167ff59173
#770: Send messages without sender with SYSTEM type again
This was the behaviour before the 1.16 update and made it so that any
 message sent by a plugin was treated as a system message allowing the
 player to disable chat messages while keeping access to commands.

After 1.16 disabling the chat also disabled any plugin output, this
 restores the original behaviour.
2020-11-19 10:16:26 +11:00
Airtheon
009f0ba0ef
#769: Fix FishHook.maxWaitTime 2020-11-09 18:21:10 +11:00
Airtheon
bc6a175eff
#767: Add wait time modification for FishHook 2020-11-06 18:51:48 +11:00
md_5
3af81c7179
Update to Minecraft 1.16.4 2020-11-03 07:00:00 +11:00
Jakub Zacek
9da3b5bff8
#762: Add TNTPrimed#setSource method 2020-10-25 18:10:08 +11:00
Bjarne Koll
9e91bcabf2
SPIGOT-6194: Read correct nbt compound into chunk pdc
Previously spigots chunk pdc loading logic would read the entire chunk
nbt compound into the persistent data container of the chunk instead of
just reading the "BukkitValues".

Furthermore this commit also now correctly checks if the nbt compounds
of entities, tile entities and chunks actually have a value for the
"BukkitValues" key, as the previous 'getCompound' call would always
return an instance, the null check was useless. This commit now uses
'get', which returns null if no key exists and then runs an instanceof
check to both validate a non-null instance and an NBTTagCompound
instance.
2020-10-18 07:01:15 +11:00
Mariell Hoversholm
04639f5a2f
#759: Allow sending messages from specific UUIDs 2020-10-17 17:46:14 +11:00
Shane Bee
055870c4bc
#758: Item - add getters/setters for owner/thrower 2020-10-14 19:56:14 +11:00
Shane Bee
29dd68eb99
#757: PoweredMinecart - add getter/setter for fuel 2020-10-13 18:59:56 +11:00
md_5
1f4693a8c3
SPIGOT-6168: Fix error with Player.getBedSpawnLocation when world is unloaded while server running 2020-10-06 18:36:43 +11:00
Shane Bee
f8d4da08e1
#743: LivingEntity - add methods for getting/setting invisibility 2020-09-19 17:48:58 +10:00
md_5
bf3d720714
Update to Minecraft 1.16.3 2020-09-11 07:00:00 +10:00
Martoph
39806409e7
#697: Add ArrowBodyCountChangeEvent 2020-09-02 18:59:17 +10:00
Parker Hawke
7d31adb5f7
#734: Add EnderSignal ItemStack API 2020-08-28 12:35:14 +10:00
md_5
bfea455968
SPIGOT-6111: NPE in CraftHumanEntity#openWorkbench & CraftHumanEntity#openEnchanting 2020-08-27 18:32:52 +10:00
Parker Hawke
eae1594350
#721: Add EntityCategory API to LivingEntity 2020-08-27 11:42:39 +10:00
Martoph
850e7b1400
SPIGOT-974: Add ArmorStand locking API 2020-08-23 09:53:19 +10:00
Parker Hawke
8b52a7666e
SPIGOT-6092: Player#setBedSpawnLocation - NullPointerException 2020-08-22 17:42:15 +10:00
md_5
5a66916c08
Cleanup sendBlockChange 2020-08-16 17:55:55 +10:00
Shane Bee
13945b7687
#725: HumanEntity - add a method to make the entity drop the item they're holding 2020-08-16 09:32:47 +10:00
Parker Hawke
82542d01d8
#723: Implement EntitySpellCastEvent for spellcaster illager 2020-08-15 09:12:20 +10:00
Shane Bee
f26d8e84ce
SPIGOT-4705: Revamp Ageable interface and add Breedable interface 2020-08-13 11:18:47 +10:00
md_5
9c9fb593f5
Update to Minecraft 1.16.2 2020-08-12 07:00:00 +10:00
md_5
60f8a29d12
SPIGOT-5968: Killer rabbits can't be set to the non-killer rabbit behavior 2020-07-09 09:04:11 +10:00
md_5
dc7c3c61fa
SPIGOT-5921: Improve setNoDamageTicks for Players 2020-07-02 11:18:03 +10:00
Parker Hawke
8297676c20
#682: Add hasDiscoveredRecipe() and getDiscoveredRecipes() 2020-07-02 09:27:18 +10:00
md_5
3b9cf0f803
Improve code formatting 2020-07-01 14:17:48 +10:00
md_5
2fe6b4a320
SPIGOT-5899: Hoglins API similar to Piglins 2020-06-30 12:03:24 +10:00
Parker Hawke
32acc26217
#686: Expand Strider and Steerable entity API 2020-06-30 09:54:28 +10:00
ceezuns
44109b726b
SPIGOT-5803: Implement the missing methods for the Piglin API. 2020-06-29 09:58:04 +10:00
md_5
4ff609e60c
SPIGOT-5836: PotionEffect HEALTH_BOOST never expires 2020-06-26 19:14:15 +10:00
md_5
baadbf3f76
SPIGOT-5833: Player#setWalkSpeed not working 2020-06-26 17:56:49 +10:00
SydMontague
a1d23114fa
#687: Add visibility and fixed API for ItemFrames 2020-06-26 10:58:17 +10:00
md_5
174a2ee539
SPIGOT-5829: RGB hex colours not supported in several places 2020-06-26 09:40:21 +10:00
md_5
f7ff58c6c5
SPIGOT-5803: Add Piglin/Zoglin Baby API 2020-06-25 19:58:27 +10:00
md_5
b136f8430d
SPIGOT-5804: Cannot launch Entity Firework 2020-06-25 12:57:58 +10:00
Phoenix616
2b00831c95
SPIGOT-2106, SPIGOT-3942: Improve collidable API 2020-06-25 10:00:00 +10:00
md_5
7ea3c040bc
Update to Minecraft 1.16.1 2020-06-25 10:00:00 +10:00
md_5
be6aaf046e SPIGOT-5782: Set Arrow Launched From Crossbow 2020-06-24 10:05:39 +10:00
Aikar
1b2830a3b3 SPIGOT-4441: Fix serializing Components to and from Legacy
While cfeef75cd97 might of semi helped being able to save black text
lore, it actually took a fundamental problem with the legacy serialization
code and expanded it to break even more aspects of the server when dealing
with Component to Legacy conversion.

This is causing data loss in Spigot with cases such as setting an item name
to white gets stripped resulting in it being italic.

Additionally, things such as book pages have been returning black formatting
codes for the end of the line even when the user doesn't have colors in the book.

The root issue is that the "Default Color" system is fundamentally wrong.

Components do not and should not care about what element of the game they
are being used by, and that's what the default color system did.

It results in components that if obtained from 1 source such as a Book
where the default / rendered color is black, is then copied to another
source such as an Entity name, the black is carried forward and shown
in the Entity name, when in reality it should have been white.

This commit reverts cfeef75cd97 and fixes the underlying serialization
issues when it comes to Legacy to and From conversions.

There was quite a number of issues with this code overall, in how
it handles inserting color codes, new line parsing and such.

Books was using mojangs own "getLegacyString" which doesn't match behavior.
We also do not want to use Mojangs method as there is no guarantee they don't
remove that in future.
Plus, everything about books uses the CB implementation anyways, and it should
be consistent (this was mandatory to avoid serialization format changes on old vs new)

These changes as is results in Item Stacks already serialized will not
change contents when they go to component and back, so this won't impact
any existing data.

Newly created books though for example will change behavior in that they
will no longer insert black color codes in the serialized data and will
only represent intentional color changes by the creator of the book.
This will result in cleaner data on them, and books are the only thing
I'm aware of that has a behavioral shift due to the likelyhood of the
default color system kicking in on other parts of the string.

A unit test has been added to verify integrity of serialization to
ensure that any legacy string that is converted into Components will
always re-encode back in the same way when going back to Legacy.
2020-06-01 19:19:42 +10:00
DiamondDagger590
893ad93b3e #650: Add method to get player's attack cooldown 2020-04-23 11:13:40 +10:00
md_5
e0cfb34742 SPIGOT-5689: Fireball.setDirection increases velocity too much 2020-04-23 08:33:33 +10:00
md_5
94cb030fb5 SPIGOT-5673: swingHand API does not show to self 2020-04-22 12:06:24 +10:00
md_5
ce66f6937b Misc checkstyle fixes 2020-04-14 12:34:43 +10:00
md_5
e25a2272f8 Fix some formatting in CraftHumanEntity 2020-04-05 16:30:47 +10:00
Tim
b2de47d581 SPIGOT-5621: Add missing container types for opening InventoryView 2020-04-05 16:28:43 +10:00