Commit Graph

49 Commits

Author SHA1 Message Date
Nassim Jahnke
a8fbb000eb
Add ProtocolManager#hasLoadedMappings 2024-02-15 18:27:52 +01:00
Nassim Jahnke
35578372a1
Fix isWorkingPipe and cursed ProtocolVersion comparator 2024-02-14 22:45:34 +01:00
EnZaXD
35ceee1a47
Rename ProtocolVersion#v1_7_1 to v1_7_2 (#3696) 2024-02-14 20:14:17 +01:00
Nassim Jahnke
c124c1c809
Sort ProtocolVersions version list, fix base protocol registration 2024-02-14 17:57:00 +01:00
EnZaXD
302716054d
Port of internals and API to ProtocolVersion (#3694) 2024-02-14 17:56:28 +01:00
Nassim Jahnke
dcc0642af9
Replace more raw versions with ProtocolVersion 2024-02-13 22:48:08 +01:00
Nassim Jahnke
abb05ce902
Merge remote-tracking branch 'origin/master' into dev 2024-01-04 17:50:24 +01:00
Nassim Jahnke
bd2c4c8a16
Update license headers 2024-01-01 12:39:45 +01:00
Nassim Jahnke
90781c9d27
Start working on 23w51a 2023-12-18 15:58:49 +01:00
Nassim Jahnke
a0f8ab7bbb
Some cleanup 2023-11-20 19:56:48 +01:00
Nassim Jahnke
cb1b33b3e7
Start working on 23w40a 2023-10-05 18:22:13 +10:00
EnZaXD
00625be890
Move 1.9 backwards protocols to VB and move Chunk Types to the correct package (#3404) 2023-08-14 10:46:30 +10:00
Nassim Jahnke
7bea3142bc Fix baseprotocol registration 2023-08-04 12:26:07 +10:00
Nassim Jahnke
62c0ef360f More absolutely cursed WIP 2023-08-03 21:58:23 +10:00
Nassim Jahnke
6dfd4747ee Start working on 23w31a 2023-08-03 13:58:22 +10:00
Nassim Jahnke
364cfad9d8
23w12a 2023-03-22 18:49:18 +01:00
Nassim Jahnke
4e844a0095
Small startup time improvements 2023-03-16 12:48:39 +01:00
Nassim Jahnke
7c9c602cec
Support Folia (leaf's region threaded Paper fork) 2023-03-10 12:20:02 +01:00
Nassim Jahnke
3ced95903a
Cache identifiers files 2023-03-05 15:20:16 +01:00
Nassim Jahnke
51d4e11b5f
Minimize/optimize mapping data files 2023-03-04 00:08:08 +01:00
Nassim Jahnke
bf4e4d771f
Uncap mapping loader executor pool, less logging 2023-02-20 17:30:56 +01:00
Nassim Jahnke
cb2165eb93
Greatly reduce the number of (anonymous) inner classes
Reduces code complexity, and much more importantly, reduces the number of classes loaded at runtime by *hundreds*
2023-02-12 11:46:48 +01:00
Nassim Jahnke
50adff90f2
23w03a 2023-01-18 16:49:05 +01:00
Nassim Jahnke
4fb95581ce
Update copyright headers 2023-01-12 12:45:53 +01:00
Nassim Jahnke
14b11bdd10
Start working on 22w42a 2022-10-19 21:58:08 +02:00
Nassim Jahnke
e194d27bea
Allow for more control over max path distance delta increase 2022-07-28 11:29:02 +02:00
Nassim Jahnke
e3e85db02a
1.19.1-pre1 2022-06-21 21:01:24 +02:00
Nassim Jahnke
365b3a8a38
22w11a 2022-03-16 19:48:17 +01:00
Nassim Jahnke
a12dfa405f
1.19 Experimental Snapshot 1 2022-03-16 18:21:41 +01:00
Nassim Jahnke
60eda447b4
22w03a 2022-01-19 18:05:36 +01:00
Nassim Jahnke
d5a568b3fc
Update copyright header 2022-01-09 22:36:07 +01:00
Nassim Jahnke
b4301adb3b
WIP 21w37a 2021-09-15 23:00:14 +02:00
Nassim Jahnke
32a84f24ef
Nicer getters in Pair and Triple 2021-09-14 11:13:39 +02:00
Nassim Jahnke
f2147179c2
Small fixes, add majorVersion method, nicer getter names in some classes
None of the deprecated methods will be removed anytime soon.
2021-08-28 22:15:28 +02:00
kennytv
2094397bca
Allow bypassing of packet type restriction in Protocol, amend packet creator 2021-08-01 12:05:04 +02:00
kennytv
b81109f512
Semi force packet types in PacketWrapper at creation and transformation 2021-07-31 15:08:45 +02:00
kennytv
874dbafe26
More packet sending API
Allows for easy packet sending from a specific version to or from any client version supported by Via.
For example, you can send packets in the 1.17.1 format to both client and server, and it will be transformed accordingly if executed on another server version or sent to a different client version.
2021-07-30 12:26:15 +02:00
KennyTV
d32a4541a9
1.17.1-pre1 2021-06-20 16:16:07 +02:00
KennyTV
24efb48004
Add method to load extra tags from diff files 2021-06-06 17:17:51 +02:00
KennyTV
fc1450fe38
Slightly more OOP, move registerPackets out of Protocol constructor
registerPackets being called within the constructor made it impossible to create instance objects then used in registerPackets (vs. having to then create the objects in registerPackets).
2021-06-03 17:28:02 +02:00
KennyTV
104fa4e29f
Optimize protocol path finding
Not perfect, but better. This prevents the path checks from exponentially increasing (if it weren't for the maxProtocolPathSize fail safe).

By default, a path will never go to a protocol version that puts it farther from the desired server protocol version, even if a path existed.
Otherwise as well as previously, *all* possible paths will be checked until a fitting one is found.

Negative examples if the new boolean is set to true:
    A possible path from 3 to 5 in order of 3->10->5 will be dismissed.
    A possible path from 5 to 3 in order of 5->0->3 will be dismissed.

Negative examples if set to false:
    While searching for a path from 3 to 5, 3->2->1 could be checked first before 3->4->5 is found.
    While searching for a path from 5 to 3, 5->6->7 could be checked first before 5->4->3 is found.

Assuming custom platforms like Bedrock protocol use the normal registering methods, they will have to change the boolean to false to revert to previous behavior (tho still somewhat better optimized).
2021-06-01 18:54:36 +02:00
KennyTV
3618914ce9
Add method to get Protocol by supported versions, some cleanup 2021-05-29 22:21:29 +02:00
KennyTV
1538ff5201
Expand unsupported software checks 2021-05-14 16:59:12 +02:00
KennyTV
cad358322d
Rename outgoing->clientbound, incoming->serverbound
Via can both be used on servers and clients, making a direction like "incoming" ambiguous
2021-04-28 16:30:34 +02:00
KennyTV
cadb5ec64c
Rename abstract Protocol to AbstractProtocol
This prevents confusion around the previously equally named interface and abstract class
2021-04-27 18:21:51 +02:00
KennyTV
f1c8d271b1
Reformat imports
The package rename wasn't done through refactoring but through simple replaces to not make git choke on diffs
2021-04-27 13:42:36 +02:00
KennyTV
318c49cf30
More interfaces, keep ProtocolRegistry.SERVER_PROTOCOL legacy api 2021-04-27 13:25:18 +02:00
KennyTV
30d122e7fa
Create some fancy interfaces 2021-04-26 23:01:55 +02:00
KennyTV
deec4b521e
Move some packages and classes around 2021-04-26 21:27:59 +02:00