Commit graph

731 commits

Author SHA1 Message Date
Camotoy
62492c961a
Entity metadata refactor; remove some MagicValues usages 2021-11-15 14:51:03 -05:00
Camotoy
155a3eb8f0
Update sound enum 2021-11-14 21:02:23 -05:00
Camotoy
ff76494a65
Properly implement block entity IDs and add tests 2021-11-14 12:05:39 -05:00
RednedEpic
8b7386a46a Never mind, this is not referenced directly but still is used 2021-11-13 23:16:57 -06:00
RednedEpic
b18835d2f3 Remove unused ChunkSection class 2021-11-13 23:13:50 -06:00
RednedEpic
a9e24e7cce Merge remote-tracking branch 'origin/feature/1.18-protocol-changes' into feature/1.18 2021-11-13 23:04:58 -06:00
RednedEpic
9705ac5c9b Merge branch 'feature/codec-refactor' into feature/1.18 2021-11-13 22:51:04 -06:00
Camotoy
d527164d4c
Initial update to 1.18 protocol 2021-11-13 23:48:38 -05:00
RednedEpic
78b4763b86 Rename ClientboundLevelChunkPacket to ClientboundLevelChunkWithLightPacket & other minor tweaks 2021-11-13 22:41:28 -06:00
RednedEpic
747d5f5655 Fix wrong rename 2021-11-13 20:44:14 -06:00
RednedEpic
44c235c86a Update variable name to chunkSection 2021-11-13 20:28:08 -06:00
RednedEpic
5b4ba5b8d0 Merge branch 'feature/1.18' into feature/codec-refactor 2021-11-13 20:10:44 -06:00
RednedEpic
955986da96 More renames 2021-11-13 17:14:13 -06:00
RednedEpic
127f253a82 Remove test code 2021-11-13 16:47:45 -06:00
RednedEpic
64410dbe48 Implement packet codec system to remove expensive protocol state switches
With the way this lib used to previously work, any time the protocol state changed, all the packet maps got cleared and had new packets inserted into them depending on the protocol state. This was unnecessarily expensive and although called rarely, it was not ideal.

The packet codecs added are static, immutable and can be reused across sessions. The codec system also opens up the door for multi-version capability in the future.
2021-11-13 16:44:55 -06:00
Camotoy
b3fb245b5b
Merge branch 'feature/1.18' of https://github.com/Steveice10/MCProtocolLib into feature/1.18 2021-11-13 15:29:23 -05:00
RednedEpic
c18fa85120 Remove duplicate registration 2021-11-13 13:57:21 -06:00
RednedEpic
c5032fb425 Update to new packetlib changes 2021-11-13 13:52:39 -06:00
Camotoy
e65ddd5a16
Actually fix SetTitleText writing null components 2021-11-13 09:52:25 -05:00
Camotoy
b72c86049c
Move EAT_FOOD animation type to SWING_OFFHAND 2021-11-12 20:59:24 -05:00
Camotoy
3f2042a7e2
Correct SetTitleText nullability 2021-11-12 20:57:47 -05:00
Camotoy
fbc71cb566
Sound in StopSoundPacket is Nullable as of 1.17.1 2021-11-12 19:23:07 -05:00
Camotoy
87c0953d27
Set all fields as final; use constructor with NetInput
This allows all fields to be final, and prevents a setAccessible used on a no-args constructor.
2021-11-12 17:38:33 -05:00
D3ATHBRINGER13
8fcf4df994
Refactor to use Mojmap packet names (#662)
This allows packet name parity with Minecraft itself.
2021-11-12 12:59:12 -05:00
David Choo
dff7c0544c
Add missing Generic Statistics (#668) 2021-11-11 14:19:08 -05:00
Camotoy
f1ac2de294
Use identifiers for all Effect classes; don't use MagicValues
We can just use the ordinal plus or minus one to determine what we're looking for.
2021-10-11 20:55:22 -04:00
Extollite
72ba6f58af
Fix project formatting style (#663) 2021-10-11 09:51:41 -04:00
Camotoy
a0ce555787
Use Mojang mapped name for UnexpectedEncryptionException 2021-10-07 09:44:34 -04:00
Camotoy
d00d4f4dba
Throw specific error when encryption could not be initialized 2021-10-07 09:43:08 -04:00
Steven Smith
6472a45e95
Merge pull request #657 from GeyserMC/feature/1.17.1 2021-09-23 01:46:56 -07:00
Camotoy
55e13e588a
Remove ServerSetCompressionPacket
This packet isn't used anymore.
2021-09-22 19:42:41 -04:00
Jesse Donkervliet
f287b501b3 fix: fixes two incorrect (swapped) packet IDs 2021-09-21 20:40:31 +02:00
Steveice10
e09374ad9f Update adventure and add legacy hover event serializer to default serializer. 2021-08-23 11:23:35 -07:00
Steven Smith
4a6aaa6213
Merge pull request #643 from GeyserMC/feature/1.17.1 2021-08-16 11:39:40 -07:00
Camotoy
e17787abe2
Handle the Brigadier Long argument type
See https://github.com/GeyserMC/Geyser/issues/2476
2021-08-16 12:34:46 -04:00
Julian
df626fbe09
Do not use the deprecated method anymore. 2021-08-11 10:56:36 +02:00
Camotoy
e4272371e1
Fix negative Y position reading 2021-07-14 15:49:05 -04:00
Camotoy
4156f6277b
Implement vibration signal packet 2021-07-07 10:51:57 -04:00
Camotoy
6e318f5b53
Update to release protocol 2021-07-05 22:30:19 -04:00
Camotoy
24a3880bd4
Update to 1.17.1-rc1 2021-07-04 10:43:26 -04:00
Camotoy
4154397c6b
Merge branch 'feature/1.17' of https://github.com/GeyserMC/MCProtocolLib into feature/1.17.1 2021-07-04 09:53:27 -04:00
Camotoy
ea40e15aa7
Address suggestions and fix tests 2021-06-28 10:11:26 -04:00
Camotoy
9db4bbca57
Update to 1.17.1-pre1 2021-06-20 12:35:34 -04:00
Camotoy
7248769028
Add more new level events 2021-06-16 18:34:26 -04:00
Camotoy
dd606b4753
Add new level events 2021-06-09 19:39:47 -04:00
Camotoy
5b5334c2be
Fix dust particle data 2021-06-08 20:07:34 -04:00
Camotoy
e3169866ef
Update to 1.17 release 2021-06-07 23:38:22 -04:00
Camotoy
2bd966a4ef
Implement new entity statuses 2021-06-07 19:13:45 -04:00
Camotoy
bc06ae50b7
Update block values 2021-06-04 21:25:33 -04:00
Camotoy
3e56be709e
Update to 1.17-rc1; some optimizations 2021-06-04 20:47:54 -04:00
Camotoy
eb026883b2
Support HangingDirection for glow item frames, too 2021-06-03 18:59:39 -04:00
Camotoy
5f523d309c
Bump for 1.17-pre5 2021-06-03 16:58:08 -04:00
Camotoy
5ff383d27a
Update to 1.17-pre4 and fix particles 2021-06-02 22:00:26 -04:00
Camotoy
ba26c10558
Fix sound 2021-06-01 22:25:38 -04:00
Camotoy
9ba9d7e055
Fix protocol version 2021-06-01 19:30:56 -04:00
Camotoy
ac342b72cc
Update to 1.17-pre3 2021-06-01 18:47:44 -04:00
Camotoy
13bf22b60c
Merge branch 'master' of https://github.com/Steveice10/MCProtocolLib into feature/1.17 2021-05-23 21:30:59 -04:00
Camotoy
104dd603b1
21w20a support 2021-05-19 22:21:58 -04:00
Camotoy
cd187d4cbe
Update to 21w18a 2021-05-05 12:30:25 -04:00
Camotoy
46a417b37c
Fix tags serialization 2021-05-05 11:58:05 -04:00
Camotoy
9541ab9bff
Update for 21w17a 2021-05-01 19:46:02 -04:00
Steveice10
8c204eb4c5 Remove deprecated MinecraftProtocol constructors.
PacketLib 2.0 update will introduce breaking changes anyway, so might as
well get this done now.
2021-04-20 18:37:33 -07:00
Steveice10
893cc683cb Update to latest PacketLib commit. 2021-04-20 18:28:14 -07:00
Steveice10
19a928364a Update version string to 1.16.5 2021-04-05 17:42:22 -07:00
darbyjack
3aa215984a Fixed parsing of the MOTD as Component 2021-04-05 12:43:47 -05:00
Steveice10
afca99c039 Fix IDs for crafting book state and displayed recipe packets. 2021-03-30 11:24:05 -07:00
Steveice10
bcf5232781 Tidy up auth data handling. 2021-03-30 11:23:41 -07:00
Camotoy
c9e70b8f59
Merge branch 'master' of https://github.com/Steveice10/MCProtocolLib into feature/1.17 2021-03-25 16:05:53 -04:00
Steven Smith
6ba99d1dbe
Merge pull request #612 from MatteCarra/ms-auth
Removed client token from MinecraftProtocol
2021-03-24 02:10:14 -07:00
Steveice10
840c8e2483 Clean up some Lombok annotations. 2021-03-24 02:04:16 -07:00
Marius Metzger
43e4461360 Add @With annotation to packet classes 2021-03-24 03:00:46 +00:00
Camotoy
b0b83242ea
Fix write as well 2021-01-13 23:30:50 -05:00
Camotoy
bf0a6be8fe
Fix ServerWorldBorderPacket initialization
Seems like these two were flipped around.
2021-01-13 19:58:40 -05:00
MatteCarra
95ba884563 Removed client token from MinecraftProtocol 2020-12-16 15:22:36 +01:00
David Choo
3b76ee2d23 Fix magic values of PistonValue 2020-12-09 15:35:46 -05:00
DoctorMacc
f7647a93ff
Actually fix merge 2020-12-04 19:21:27 -05:00
DoctorMacc
5e526ff01a
Merge branch 'master' of https://github.com/Steveice10/MCProtocolLib into feature/1.17 2020-12-04 18:02:46 -05:00
DoctorMacc
0ddc3a8664
Initial 20w49a implementation 2020-12-04 17:56:27 -05:00
Steveice10
26201a49f0 Allow specifying a custom GsonComponentSerializer to use. 2020-11-21 13:56:49 -08:00
Steveice10
ccbd52dffd Replace Message API with Adventure component parsing. 2020-11-21 13:42:36 -08:00
D3ATHBRINGER13
5993241c70 20w46a 2020-11-17 19:43:27 +00:00
DoctorMacc
1b167e197a
Make all recipes nullable
Cookable recipes can have a nullable result too - I'm going to assume that all recipe types can too.
2020-11-11 16:15:44 -05:00
DoctorMacc
befbfbf0ed
Allow recipe data to be null
Using datapacks, this can end up being null. Example: https://www.planetminecraft.com/data-pack/true-survival-a-hardcore-minecraft-experience/ (used to set recipes as doing nothing)
2020-11-08 18:18:12 -05:00
DoctorMacc
ea3d99d0f9
Update for 20w45a
Notably: biome data is currently set to non-null as there is no full chunk indicator anymore.
2020-11-04 17:36:44 -05:00
DoctorMacc
7321e8f0d7 Update to 1.16.4 2020-11-02 12:31:24 -08:00
DoctorMacc
c363fc3cb5 Update to 1.16.4-pre2 2020-11-02 12:31:24 -08:00
DoctorMacc
37af0d3a39 Add support for 1.16.4 2020-11-02 12:31:24 -08:00
DoctorMacc
971f6eebf9
Accomodate for encoding bug 2020-10-21 20:46:44 -04:00
DoctorMacc
e408dd250d
Add full support for the UNKNOWN gamemode
Previously we correctly handled the unknown gamemode for 'previous gamemode'; however, this functionality can extend to the main gamemode. The gamemode writing we've been doing has been replaced with the UNKNOWN enum, so we aren't dealing with a null value.
2020-10-21 17:02:39 -04:00
DaPorkchop_
cdcfff5b10 allow duplicate entries in palette 2020-10-18 21:41:56 +02:00
DaPorkchop_
3685d6b580 palette does not always start with zero... 2020-10-17 17:38:14 +02:00
DaPorkchop_
a05abf0403 use a Netty IntObjectMap instead of a standard Map 2020-10-14 15:03:29 +02:00
DaPorkchop_
8a000ddf2e remove useless imports in ListPalette 2020-10-14 14:57:56 +02:00
DaPorkchop_
4cefa46df3 don't allocate needless array when resizing palette 2020-10-14 14:56:42 +02:00
DaPorkchop_
1a2197fcc7 make MapPalette's idToState Map into an array 2020-10-14 14:52:38 +02:00
DaPorkchop_
f9e27b29e6 make ListPalette be backed by an array rather than a List 2020-10-14 14:51:53 +02:00
Steveice10
2ac116a075 Revise chunk storage code based on latest logic. 2020-10-13 16:18:56 -07:00
rtm516
23d78d7620
Add COPY_TO_CLIPBOARD ClickAction 2020-10-13 18:39:25 +01:00
DoctorMacc
ec052d7704
Remove unused imports 2020-09-26 17:23:27 -04:00
DoctorMacc
fc905c8d76
Re-implement as a constant 2020-09-26 17:21:57 -04:00