3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-19 04:50:06 +01:00
Commit graph

3175 Commits

Autor SHA1 Nachricht Datum
md_5
095239d4c5 SPIGOT-4159: Fix Player.launchProjectile(Trident.class) 2018-07-27 14:29:02 +10:00
md_5
1ef1ffd664 SPIGOT-4137: Fix World.regenerateChunk 2018-07-25 19:32:06 +10:00
Senmori
3599dbe3c2 SPIGOT-3981: Make custom inventories return specialised types where practical. 2018-07-25 18:03:37 +10:00
Senmori
9646d8d780 SPIGOT-4147: Fix ItemFrames not able to be placed UP or DOWN 2018-07-25 14:17:03 +10:00
md_5
9cfb0090d8 SPIGOT-4135: Fix DOLPHINS_GRACE PotionEffectType Wrapper. 2018-07-24 22:17:20 +10:00
md_5
46e5eeb67e SPIGOT-4128: Skip hopeless entity conversion 2018-07-24 20:46:49 +10:00
md_5
2100017016 SPIGOT-4132: Fix missing break in RedstoneWire.setFace 2018-07-24 12:46:21 +10:00
md_5
ca75fead2c SPIGOT-4131: Fix typo affecting setting BlockData 2018-07-24 12:04:34 +10:00
md_5
19ff43d9e1 SPIGOT-4128: Greatly improve spawn egg deserialization 2018-07-24 10:49:48 +10:00
md_5
7357d7237a SPIGOT-4123: Fix display names cleared by plugins / serialization 2018-07-24 10:47:51 +10:00
md_5
f732acf24f Add map ID API 2018-07-24 10:18:06 +10:00
md_5
fbf903a1bc SPIGOT-4120: Store BlockData enum mappings per class 2018-07-24 10:08:34 +10:00
md_5
ea7b61290a SPIGOT-4122: Fix an instance of legacy item inequalities 2018-07-24 08:57:58 +10:00
md_5
6a109cf6bc SPIGOT-4124: Fix misplaced PISTON_HEAD 2018-07-24 08:25:13 +10:00
Articdive
30ab12cf4c SPIGOT-824: SpongeAbsorbEvent 2018-07-23 17:21:07 +10:00
md_5
155b17305b SPIGOT-4112: scoreboard display names are not nullable 2018-07-23 11:46:23 +10:00
md_5
d4297cbe2d Just throw section signs into components a la Mojang 2018-07-23 10:48:28 +10:00
md_5
4e2f571337 Fix Player.playNote 2018-07-22 14:40:48 +10:00
md_5
1a6b4f5392 Update to Minecraft 1.13 2018-07-22 12:00:00 +10:00
md_5
e5d6f6b596 SPIGOT-4024: Improve interactions of Vanilla tab completion, and also reloads 2018-07-21 11:23:11 +10:00
md_5
889e17f99d SPIGOT-4100: Ignore invalid item display names 2018-07-21 09:54:08 +10:00
md_5
7c0f69e449 CraftBlock.toString shouldn't make legacy call 2018-07-20 16:10:48 +10:00
kaenganxt
814c742554 SPIGOT-840, SPIGOT-2522: [Draft] Add EntityPotionEffectChangeEvent
Discussion ongoing in PR #449
2018-07-20 16:06:34 +10:00
md_5
66b62a63b5 Fix bad old API call in CraftBlockState 2018-07-20 10:32:17 +10:00
md_5
ca1af9368b Update EntityChangeBlockEvent to new BlockData API 2018-07-20 10:29:34 +10:00
md_5
49ac8a7446 SPIGOT-4074: Fix createBlockData succeeding on garbage 2018-07-20 10:20:15 +10:00
md_5
80fefcf5ef SPIGOT-4047: Ignore non-existent potions 2018-07-19 11:35:12 +10:00
md_5
fc1b107579 SPIGOT-4046: Fix selectors in tick functions 2018-07-19 10:59:16 +10:00
md_5
595ec64726 SPIGOT-4049: Books lose NBT data 2018-07-19 10:12:55 +10:00
md_5
92dceb827c Revert "SPIGOT-4035: Enforce case-sensitivity for chat format code matching."
Minecraft allows uppercase colour codes.

This reverts commit d480dc74e5.
2018-07-19 10:07:04 +10:00
md_5
65bc676ed0 SPIGOT-4041: Fix regressed item naming 2018-07-18 17:39:04 +10:00
md_5
6fa4ae693e SPIGOT-4040: Further increase team related limits 2018-07-18 17:11:44 +10:00
md_5
9c98002856 Fix Block.setType alone being treated as legacy 2018-07-18 16:59:41 +10:00
md_5
d48ecdeb45 Delete Block.setData byte methods from API 2018-07-18 16:55:44 +10:00
md_5
b9fd5c60e9 SPIGOT-4020: Fix DustOptions colouring 2018-07-18 16:40:31 +10:00
md_5
15036eb75b Fix changes that got lost late in development cycle 2018-07-18 14:13:20 +10:00
md_5
f18d78282d SPIGOT-4028: Improve legacy ItemStack conversion 2018-07-18 14:01:15 +10:00
md_5
3791cf947e SPIGOT-4037: Improve legacy BlockState.setData 2018-07-18 09:53:50 +10:00
md_5
404d6e776e SPIGOT-4036: Handle regular/uncoloured shulker boxes 2018-07-18 09:45:27 +10:00
md_5
a3b5ef2c3e Amend previous unit test to use JSON rather than toString for validation 2018-07-18 09:40:51 +10:00
Hex
d480dc74e5 SPIGOT-4035: Enforce case-sensitivity for chat format code matching.
This maintains case-insensitivity for URL matching, and adds a unit test to verify correct conversion via CraftChatMessage.
2018-07-18 09:36:16 +10:00
md_5
8c9dea83c3 SPIGOT-4030: Improve CraftItemStack.hasItemMeta 2018-07-17 17:13:55 +10:00
Hex
1526726b57 SPIGOT-4031: Improve bounds checking in CraftInventoryView. 2018-07-16 22:47:47 -06:00
md_5
b4bff6fc3d SPIGOT-4026: Clicking on command error suggestion should return verbatim input 2018-07-17 06:49:40 +10:00
md_5
fa1340f7a6 SPIGOT-4022: Improve utility of Entity.getName for non-players 2018-07-17 06:36:08 +10:00
md_5
1fccb89501 Fix completion of multiple arguments in Bukkit commands 2018-07-16 21:03:46 +10:00
md_5
926ea10459 SPIGOT-4017: Increase Team related length limits 2018-07-16 19:15:26 +10:00
md_5
22e5229238 Standardise empty string as null / not set 2018-07-16 16:20:26 +10:00
md_5
b6a757dec8 SPIGOT-4016: Fix clearing custom names 2018-07-16 14:39:01 +10:00
md_5
8fbc72b714 Add ignore-vanilla-permissions option to assist with disabling default commands 2018-07-16 12:06:06 +10:00
md_5
322f2f9518 CraftBanner also needs to use wool data 2018-07-16 10:37:56 +10:00
md_5
3890544e04 SPIGOT-4015: Make CraftTeam tie into backing prefix/suffix 2018-07-16 10:20:53 +10:00
md_5
ee3c26688e SPIGOT-4008: Fix server-icon loading 2018-07-16 10:08:07 +10:00
md_5
43eb8f312c SPIGOT-4011: Clear error for plugin misusing ChunkData 2018-07-16 09:01:23 +10:00
md_5
10261f31d7 Fish / Dolphin should be WaterMob, and WaterMob Creature 2018-07-16 08:51:34 +10:00
md_5
b8ea9ec844 SPIGOT-4004: Fix banner pattern colouring 2018-07-15 23:30:00 +10:00
md_5
60185a5616 Validate world in CraftServer.createChunkData 2018-07-15 19:52:26 +10:00
md_5
764b81ced2 SPIGOT-4003: Fix TropicalFish.getType 2018-07-15 18:52:21 +10:00
Senmori
cfc30bb382 Add javadocs to new CraftBlockData utility methods. 2018-07-15 16:36:02 +10:00
md_5
fe7db9d53b Add EntityToggleSwimEvent and isSwimming / setSwimming API 2018-07-15 16:17:35 +10:00
md_5
72cf620d47 SPIGOT-4002: Fix usage of default: statements in 1.13 plugins compiled w/ Eclipse 2018-07-15 15:00:35 +10:00
md_5
421c1728c8 Update to Minecraft 1.13-pre7 2018-07-15 10:00:00 +10:00
md_5
57ab4cfc6f Player metadata really should be keyed by UUID not name 2018-07-11 20:02:32 +10:00
md_5
ca6d2cf9dc Add validation checks to CraftPlayer.teleport 2018-07-11 09:06:48 +10:00
md_5
6103339c08 SPIGOT-3976: Add some additional toStrings to CraftEntity classes 2018-06-27 20:27:52 +10:00
blablubbabc
fbe3046435 SPIGOT-3619: Improve CraftScheduler#isCurrentlyRunning
* No longer returns opposite of what it should
* Works for sync tasks as well
2018-06-20 13:11:50 +10:00
md_5
2f3ed3b2d0 Remove outdated build delay. 2018-06-17 13:02:54 +10:00
Parker Hawke
d0a3620c2d Implement Arrow tile methods 2018-05-06 14:12:19 +10:00
md_5
61ca7d92c1 SPIGOT-3923: Defer PlayerInventory ItemStack change to 1.13 2018-05-05 08:22:40 +10:00
md_5
ca057a3457 SPIGOT-3920: Make player inventories consistently return null for empty stacks 2018-05-04 17:09:46 +10:00
md_5
21d5f75d6c SPIGOT-3908: Fix signed books incorrect defaulting to unresolved 2018-04-19 08:03:39 +10:00
md_5
bea5a842bc SPIGOT-3904: Consolidate book handling code 2018-04-16 19:19:38 +10:00
md_5
9060bfa9b9 SPIGOT-3886: Plugin exceptions in map rendering should not crash server 2018-04-08 20:03:12 +10:00
Senmori
9f49ad60e7 Remove magic values in scheduler package 2018-03-26 15:34:33 +11:00
Senmori
3a482bdd40 Add setTarget and getTarget to Slime. 2018-03-03 21:50:57 +11:00
md_5
fb414fe101 Add missing WEARABLE EnchantmentTarget 2018-02-19 20:48:27 +11:00
BlackHole
bacaf9274b SPIGOT-3824: Return the direct vehicle of an entity, not the root vehicle 2018-02-16 23:16:48 +01:00
md_5
fd702e4f44 Fix incorrect unit test name 2018-02-16 10:33:36 +11:00
md_5
f4ca1805d6 Fix bad usage of setter in previous commit 2018-02-12 10:38:09 +11:00
Senmori
f8411ea1e5 Expand Structure Block API 2018-02-12 10:33:19 +11:00
md_5
8bb4f6ccc1 SPIGOT-3813: Player.setHealth not reliable in conjunction with attribute API 2018-02-12 08:59:32 +11:00
md_5
49ecc7c7a2 SPIGOT-3812: Workbench from Bukkit.createInventory does not update 2018-02-12 08:43:11 +11:00
md_5
9ab298de7b SPIGOT-3807: Improve getEyeHeight 2018-02-10 12:17:00 +11:00
Senmori
1c40a81828 Expand EnderSignal API 2018-02-03 17:48:41 +11:00
md_5
015bda4b7d SPIGOT-2911: Implement AbstractHorseInventory 2018-01-28 09:56:55 +11:00
Senmori
c7656468e4 Expand CreatureSpawner API 2018-01-24 17:19:41 +11:00
md_5
bdcc7c7b02 Unit tests for Material.isItem 2018-01-16 09:57:47 +11:00
md_5
bd308430b5 SPIGOT-3751: BossBar flag methods reversed 2018-01-10 12:40:38 +11:00
md_5
67b763c5a7 Fix Block PistonMoveReaction 2018-01-10 10:47:26 +11:00
md_5
4119224efe Fix opening shulker inventories 2018-01-08 16:07:18 +11:00
md_5
ab09b27ef4 Remove a bunch of spurious _INVALID_ methods. 2018-01-05 13:04:18 +11:00
md_5
e40c9ef4b9 print -> println in world start region preparation 2018-01-02 20:24:33 +11:00
md_5
595eaaa8be SPIGOT-3724: Make CraftMetaSkull work reliably for player skulls 2018-01-01 12:32:48 +11:00
Senmori
950006003c SPIGOT-355: API for Villager careers 2017-12-31 21:21:03 +11:00
md_5
e1fb9cb640 Send title timings before sending titles 2017-12-30 13:39:54 +11:00
md_5
b5a10a9d6d Remove unused private static final variable 2017-12-28 14:47:57 +11:00
blablubbabc
45c83860e1 SPIGOT-3696: Clearing custom name of some blocks does not work 2017-12-17 11:41:56 +11:00
md_5
04595908e5 Allow unloading all worlds except the main one 2017-12-16 10:19:00 +11:00
md_5
fb4564cc37 SPIGOT-2892: Fix some clone implementations and add unit test 2017-12-16 10:18:34 +11:00
Antony Riley
6cb752ea08 Add ChunkDataTest from PR #157 2017-12-08 19:37:15 +11:00
md_5
e46898a5e8 SPIGOT-3684: Team#setColor does not trigger scoreboard update 2017-12-08 09:31:20 +11:00
md_5
cfd6933002 SPIGOT-3664: Add Material getter to ChunkSnapshot 2017-12-07 10:25:16 +11:00
Chris Cowan
558c5a348c SPIGOT-3663: Add plugin parameter to hidePlayer+showPlayer. 2017-12-05 09:37:47 +11:00
md_5
f46ccd7637 Fix some formatting in CraftEventFactory 2017-11-22 17:05:59 +11:00
Senmori
bdb8822625 SPIGOT-1505: PlayerItemMendEvent 2017-11-21 10:21:20 +11:00
md_5
dccd2763bd SPIGOT-690: Try to make force opened enchant tables work a bit better 2017-11-18 10:48:16 +11:00
Cory Redmond
74cd5fdfc4 Add setSpawnLocation(Location) 2017-11-18 10:27:24 +11:00
md_5
6e0b0a1b55 Don't special case 'invalid' usernames for UUIDs. 2017-11-18 10:12:27 +11:00
md_5
c15d869440 Use generics in health scaling methods 2017-11-17 11:08:26 +11:00
md_5
108fc362c0 CraftMetaFirework: AssertionError -> IllegalArgumentException 2017-11-17 10:23:20 +11:00
md_5
82f3b02c67 SPIGOT-1891: Player.playNote should use RECORDS category
This is what NoteBlock.play etc uses.
2017-11-14 09:57:46 +11:00
md_5
adbfc1f98a SPIGOT-3649: Backwards check in playEffect 2017-11-13 08:47:04 +11:00
md_5
25959fab20 Add Score.isScoreSet()Z API. 2017-11-10 10:50:58 +11:00
md_5
353964045a Catch all exceptions from plugin conversation handling 2017-11-10 10:46:46 +11:00
md_5
326c2e605f SPIGOT-3644: Fix missed yaw callsite update 2017-11-09 13:07:25 +11:00
Parker Hawke
305df9035f Implement max fuse tick & explosion radius methods to Creeper 2017-11-08 12:33:21 +11:00
md_5
c3047a5df7 SPIGOT-3629: Greatly expand entity effect API 2017-11-07 19:32:24 +11:00
md_5
2fae23c251 SPIGOT-3637: Adjust yaw yet again 2017-11-07 17:21:38 +11:00
md_5
1257322d1f SPIGOT-3622: Issue in some combinations of spawn protection 2017-10-28 16:00:15 +11:00
md_5
31d3159f04 SPIGOT-3613: Success count not reset for exceptions. 2017-10-17 21:08:43 +11:00
md_5
9ab758c7b6 SPIGOT-3605: Spawn eggs not saving internal data 2017-10-09 18:32:45 +11:00
md_5
30da15647f Fix zombie professions 2017-10-09 18:18:11 +11:00
md_5
59fa98bfb7 SPIGOT-3587: Set head rotation when spawning entity 2017-10-01 11:01:49 +11:00
md_5
a3b3a421ac SPIGOT-3565: Head yaw is "more accurate" for living entities 2017-09-28 16:23:14 +10:00
blablubbabc
ee91bce157 Fix active async tasks not cancelled by CraftScheduler#cancelTasks(Plugin) 2017-09-28 16:18:45 +10:00
md_5
9a1f5ee80a Update to Minecraft 1.12.2 2017-09-18 20:00:00 +10:00
md_5
8f472147b7 Remove outdated build delay. 2017-09-14 21:39:04 +10:00
md_5
876d22cd55 SPIGOT-3561: Fix selectors in SuccessCount 2017-09-09 12:51:18 +10:00
md_5
9e3636d82a SPIGOT-3553: Add OfflinePlayer based methods to SkullMeta 2017-09-06 16:14:37 +10:00
md_5
178caf9ac2 SPIGOT-3551: Recursively unrestrict advancements 2017-09-06 16:07:41 +10:00
blablubbabc
bde2a93cfe Add BukkitTask#isCancelled 2017-09-02 17:04:29 +10:00
Jannyboy11
79e55b6dcf SPIGOT-1107: Shift clicking and delegation for custom inventories
PR #398
2017-08-18 18:54:49 +10:00
Lukas Hennig
e1f296d115 Fix CraftBanner initialisation. 2017-08-07 17:55:47 +10:00
md_5
b5878783ad SPIGOT-3491: Add option to bypass permissions in advancements 2017-08-06 09:07:24 +10:00
Lukas Hennig
19507baf8b Improvements to BlockStates
* Actually capture all the data of TileEntities. This is done by creating a copy of the TileEntity. The methods of BlockState which currently directly access the TileEntity reference will modify the data of that TileEntity-snapshot instead.
* With the call to BlockState.update, the captured TileEntity data gets applied to the current TileEntity in the world.
* Methods which trigger block specific actions will use the current TileEntity from the world.
* CraftBlockState does not hand out the wrapped or the snapshot TileEntity directly. Instead, it provides an applyTo method to copy the data to a given TileEntity and a method to directly get a copy of the TileEntity NBT data represented by the BlockState. CraftMetaBlockState was updated to make use of that.
* Added #getSnapshotInventory() to bukkit which allows modifiying the captured inventory snapshots of containers.
* Tried to clarify which methods only work if the BlockState is placed, which methods require the block in the world to still be of the same type (methods which trigger actions), and that .getInventory() directly modifies the inventory of the block in the world if the BlockState is placed and becomes invalid if the block type is changed.

Backwards compatibility

* If the BlockState acts as InventoryHolder, getInventory() will still return the inventory directly backed by the TileEntity in the world (like before), and not the snapshot inventory. This compromise should reduce the potential of these changes to break existing plugins, or craftbukkit's own use of BlockState.
* The snapshot's inventory can be accessed by a new method getSnapshotInventory()
* In case the BlockState is not placed (if it was retrieved from the MetaBlockState of an item), the getInventory() method will however return the snapshot inventory. So that when the BlockState gets applied back to the item, the inventory changes are properly included.
* With the changes to CraftMetaBlockState it is no longer required to call the update method before passing a modified BlockState to the CraftMetaBlockState. For backwards compatibility the update method will simply return true for a non-placed BlockState, without actually doing anything.

Impact on plugins
* Restoring blocks now actually works as expected, properly restoring the TileEntity data, reglardless if the block changed its type in the meantime.
* Plugins are now consistently required to call the update method in order to apply changes to blocks. Though, regarding the Javadoc they should have been required to do so anyways.
* New feature: Plugins can take and modify inventory snapshots.
* Breaking change: If a plugin gets the BlockState of a block in the world, modifies the inventory returned by .getInventory(), and then tries to use the same BlockState to apply the TileEntity data to an ItemStack block meta, the ItemStack will use the snapshot inventory, disregarding the changes made to the inventory returned by .getInventory(). This is the compromise of .getInventory() returning the inventory directly backed by the TileEntity in the world.

Other fixes related to BlockState:
* TileEntityContainer#getLocation() will run into a NPE if the TileEntity is non-placed (ex. when getting the BlockState from a CraftMetaBlockState).
* Beacon.getEntitiesInRange() would previously throw a NPE if called for a non-placed BlockState. It was changed to now require to be placed and use the current TileEntity in the world. If the TileEntity in the world is no longer a beacon, it will return an empty list.
* EndGateway now supports setting and getting the exit location even for non-placed EndGateways (inside BlockStateMeta) by using / returning a location with world being null.
2017-08-05 14:37:19 +10:00
md_5
20ab5d3d10 Add build delay back 2017-08-04 16:09:17 +10:00
md_5
2a927e8638 Update to Minecraft 1.12.1 2017-08-03 23:00:00 +10:00
md_5
9a1fc1e2ee Remove outdated build delay. 2017-08-03 21:10:43 +10:00
md_5
b5dc294d32 SPIGOT-3485: Launch shulker bullets as projectiles 2017-08-03 08:23:27 +10:00
BillyGalbreath
d2aa6845f0 Implement BroadcastMessageEvent 2017-07-28 16:53:43 +10:00
md_5
b1b9ab0df9 SPIGOT-3461: Standardise plugin load timing 2017-07-26 13:20:29 +10:00
md_5
d35483b0e1 Correct scheduler behaviour with intervals of >= Integer.MAX_VALUE (circa 3 years). 2017-07-25 15:36:44 +10:00
md_5
4670a84bd9 SPIGOT-3432: Add playNote support for new sounds 2017-07-24 17:44:44 +10:00
md_5
5a12442f22 SPIGOT-3433: Improve AreaEffectCloud#getSource 2017-07-22 09:51:22 +10:00
md_5
9a82fa7785 SPIGOT-3428: Recover from invalid firework data 2017-07-19 09:56:35 +10:00
md_5
70be90e168 SPIGOT-3425: Correct slot type calculation 2017-07-16 11:03:19 +10:00
md_5
b5df1f59f7 SPIGOT-3423: Don't treat technical piston block as BlockStateMeta 2017-07-16 10:48:21 +10:00
md_5
e03b1a556d SPIGOT-3417: Event for shearing snowman 2017-07-15 09:53:22 +10:00
md_5
6659ddf11a SPIGOT-3416: Cap team prefix / suffix at correct value of 16 2017-07-13 12:42:45 +10:00
md_5
af1c0139f5 SPIGOT-3409: Improve performance of registering stupid amounts of permissions in plugin.yml 2017-07-10 21:05:47 +10:00