3
0
Mirror von https://github.com/PaperMC/Velocity.git synchronisiert 2024-11-16 21:10:30 +01:00
Commit graph

1486 Commits

Autor SHA1 Nachricht Datum
powercas_gamer
5f27edf3c2
Fix "Add -haproxy-protocol startup parameter" (#1216)
This reverts commit b23c2c6e1a.
2024-01-21 15:25:34 -05:00
Adrian
b23c2c6e1a
Revert "Add -haproxy-protocol startup parameter" (#1214) 2024-01-21 11:11:02 -05:00
冰砚炽
363e3a7f94
Add -haproxy-protocol startup parameter (#1136) 2024-01-21 10:47:40 -05:00
Shane Freeder
283005c8bc
Fix fat finger 2024-01-21 11:48:37 +00:00
Shane Freeder
f6fbd25805
Downgrade severity of handling several incoming user input packet states 2024-01-21 11:47:14 +00:00
Andrew Steinborn
953ab6d8e7
Implement click callback provider (#1029) 2024-01-20 16:58:00 -05:00
Adrian
46d018c0f2
Pass the correct virtual host port during the handshake (#1205) 2024-01-20 07:27:41 -05:00
Adrian
d4a661870e
Fixed possible ConcurrentModificationException when iterating across TabList entries (#1204) 2024-01-20 10:12:29 +00:00
pop4959
523d750f2b
Implement some missing resource pack API (#1206) 2024-01-20 10:11:05 +00:00
Riley Park
0993ce2f86
Improve protocol version checking (#1203)
* Improve protocol version checking

* chore: since 3.3.0
2024-01-18 17:32:42 -08:00
Adrian
2ac8751337
Updated the packet classes to include the "Packet" suffix (#1202)
* Updated the packet classes to include the "Packet" suffix

* Fixed test checkstyle
2024-01-18 12:25:22 -08:00
ZoneTwelve
75e24a0c59
l10n: Traditional Chinese Support (#1158)
* update: zh_TW translation

* update: small unchanges

* Update messages_zh_TW.properties

Replace 兼容 with 相容
2024-01-18 10:13:23 -08:00
Aaron
eabff2020f
fix legacy console disconnect messages (#1197) 2024-01-18 10:10:30 +00:00
Adrian
c7c65e3339
Fixed unknown status code error (#1196) 2024-01-17 17:00:39 +00:00
Adrian
6d7335b21f
Fully replaced AsyncHttpClient (#1194) 2024-01-17 15:20:27 +00:00
Shane Freeder
b22b2dc458
Migrate to using built-in http client (#1192) 2024-01-17 15:02:36 +00:00
VelVeV
fe052e5163
Fix tablist header and footer desync (#1103) 2024-01-16 13:19:45 +00:00
Spongecade
f8cdf4fa1a
[ci skip] Update Minecraft wiki references (#1092)
The Minecraft Fandom wiki has been forked to a new domain: minecraft.wiki. Learn more here: https://minecraft.wiki/w/Minecraft_Wiki:Moving_from_Fandom. This PR updates all references accordingly.

Let me know if you want me to open this PR on other branches!
2024-01-16 13:07:14 +00:00
WonderfulPanic
dab64ebb59
Fix player list header/footer not sending translated version (#1186) 2024-01-16 13:06:05 +00:00
EpicPlayerA10
08c03aaea2
Fix chat race condition (#1042) 2024-01-11 11:44:16 +00:00
Mgazul
02c4d61fc6
Add ModernForgeConnectionType to supports Forge-1.20.2+ (#1176) 2024-01-11 11:24:11 +00:00
Adrian
a008464ede
Improved configuration migration (#1111) 2024-01-11 10:38:00 +00:00
Adrian
cc906000bc
Fixed Legacy Ping handling (#1180) 2024-01-11 06:57:03 +00:00
0xAda
408b420af7
Use System.nanoTime in place of System.currentTimeMillis when comparing timestamps. (#1174) 2024-01-04 12:35:03 -05:00
Alexander Städing
897ff81915
Clean up JavaPluginLoader and VelocityPluginModule (#1140) 2024-01-04 16:04:25 +00:00
Adrian
28acf9eac1
Removed console legacy color support (#1105)
Co-authored-by: Shane Freeder <1228900+electronicboy@users.noreply.github.com>
2024-01-04 15:40:11 +00:00
Pancake
de57563eab
Hide ip address in initial and legacy connections (#1025) 2024-01-04 13:50:47 +00:00
Timon
00ef92bc5c
Restore nullability for displayName in UpsertPlayerInfo (#1172)
This makes the UpsertPlayerInfo's displayName truly nullable as before the ComponentHolder was introduced.
2023-12-28 15:37:31 +00:00
Adrian
6fd03d6f5c
Added static methods to create ArgumentBuilders directly in the BrigadierCommand class (#1161) 2023-12-27 13:33:44 -05:00
Gero
9450e6600c Fix race condition when switching from config to play state 2023-12-23 10:58:32 +01:00
Spottedleaf
a3a6b3fd07 Correctly version component serialization
1.20.3+ has some additional options (EMIT_COMPACT_TEXT_COMPONENT,
EMIT_HOVER_SHOW_ENTITY_ID_AS_INT_ARRAY, VALIDATE_STRICT_EVENTS)
that should be disabled in older versions.

The OptionState is constructed manually due to
https://github.com/KyoriPowered/adventure/issues/1015,
which is a bug that makes JSONOptions.BY_DATA_VERSION
use incorrect options for 1.20.3+ options.

This also fixes incorrect building of the ping serializer, as
it should only use the component serializer to serialize
Component.class and nothing else.
2023-12-22 23:20:43 +00:00
Gero
a54d8c681f Support conversion of mixed json array components 2023-12-19 12:13:11 +01:00
Shane Freeder
79fe8c8005
[ci skip] Fix internal javadoc 2023-12-14 14:33:10 +00:00
Gero
e703e9d2b8 Fix SessionPlayerChat packet registration 2023-12-14 14:20:16 +00:00
Gero
b00d3bcf5b Fix TabCompleteResponse 2023-12-14 14:20:16 +00:00
Gero
32228e85ab fix disconnect decoding 2023-12-14 14:20:16 +00:00
Gero
8a6c20ee32 Fix NPE in ComponentHolder 2023-12-14 14:20:16 +00:00
Gero
5b8bba4b29 fix binary -> json component 2023-12-14 14:20:16 +00:00
Gero
702dad25c4 don't clear applied resource pack for 1.20.3 in config state 2023-12-14 14:20:16 +00:00
Gero
058aee259a fix resource pack status 2023-12-14 14:20:16 +00:00
Gero
519bf5ee04 Fix title and system chat packets 2023-12-14 14:20:16 +00:00
pkt77
eaa83378d7 Fix Disconnects 2023-12-14 14:20:16 +00:00
pkt77
eb03feebd9 Fix TabList NPE 2023-12-14 14:20:16 +00:00
pkt77
efcfeb3e53 1.20.3 working & checkstyle fixes 2023-12-14 14:20:16 +00:00
Gero
814b53f12c WIP 1.20.3 2023-12-14 14:20:16 +00:00
Adrian
a6d90105ec
Update Configurate to 4.1.2 and include Configurate 3 (#1157) 2023-12-11 15:16:44 +00:00
ishland
c8ca28cd30
fix: Respawn packet codec for 1.20.2+ (#1156) 2023-12-11 15:11:22 +00:00
Shane Freeder
07a525be7f
Correct writing of brand string 2023-11-30 23:02:43 +00:00
AoElite
e5176717a9
fix backend not receiving brands from 1.20.2 clients (#1147) 2023-11-30 20:18:40 +00:00
Andrew Steinborn
8dcc7ee37e Fix 2023-10-29 15:29:43 -04:00
Andrew Steinborn
2ec830f874 Apply some changes from 5.0.0 2023-10-29 14:54:50 -04:00
Adrian
2e8ef8b2ca
Fire PlayerSettingsChangedEvent event when PlayerSettings are provided in the Configuration phase (#1118) 2023-10-29 14:44:04 -04:00
Luccboy
f87b05a487
Allow sending all players from current server (#1133) 2023-10-29 14:42:40 -04:00
Andrew Steinborn
67d5e77b1f Revert bad bug fix 2023-10-29 00:56:30 -04:00
Luccboy
9b71564c5b
Improve tab completion of glist and send command (#1126) 2023-10-28 23:21:15 -04:00
Angelillo15
81145e45df
Add send command (#1073) 2023-10-28 20:14:19 -04:00
Andrew Steinborn
7f8edf8c77 Fix typo in VelocityRegisteredServer#ping() 2023-10-28 19:53:49 -04:00
Andrew Steinborn
74033addbe Fix bug in VelocityRegisteredServer#ping() 2023-10-28 19:53:29 -04:00
Andrew Steinborn
ae63da6836 Merge branch 'dev/3.0.0' of github.com:PaperMC/Velocity into dev/3.0.0 2023-10-27 21:57:44 -04:00
Andrew Steinborn
c6cc6098a6 Make EventTypeTracker actually thread-safe
Although I don't think anyone has actually triggered this bug in practice, we should still fix this.
2023-10-27 21:57:34 -04:00
JNNGL
b7853d648f
Add kqueue support (#996) 2023-10-27 17:32:22 -04:00
James58899
660160e858
Support plugin message in configuration stage (#1096) 2023-10-27 17:13:13 -04:00
Andrew Steinborn
bbdeb3ec58 Revert "Modify MinecraftCompressorAndLengthEncoder to handle 8MiB outgoing packets like vanilla supports now"
This reverts commit 7e932eaad4.

Yikes, I broke something. Need to rethink this approach.
2023-10-27 16:10:39 -04:00
Alexander Städing
3d20c3dd2d Migrate buildSrc plugins to build-logic 2023-10-27 16:03:15 -04:00
Andrew Steinborn
7e932eaad4 Modify MinecraftCompressorAndLengthEncoder to handle 8MiB outgoing packets like vanilla supports now 2023-10-27 15:35:04 -04:00
Andrew Steinborn
0b07456c89 Bump HARD_MAXIMUM_UNCOMPRESSED_SIZE to 128MiB 2023-10-27 15:17:32 -04:00
Owen
b33d18af2b
Allow closing active proxy listeners (#1109) 2023-10-27 01:39:03 -04:00
Adrian
f884e049c0
Log the protocol phase in case of trying to obtain a packet id not existing in the phase (#1107) 2023-10-12 21:29:04 +01:00
Adrian
eb594fc799
Implement ComponentLogger (#1022) 2023-10-12 18:44:10 +01:00
Shane Freeder
98163cb82c
acknowledge seen messages to server when running proxy commands (#1100) 2023-10-12 17:22:42 +01:00
Joo200
0d9a097a59
Fix unsigned commands detected as signed (#1082)
* fix: commands flagged as signed without signed arguments

* feat: improve error message for illegal protocol state.
2023-10-12 15:51:19 +01:00
Gero
1cc3f120ee
Several improvements and fixes for 1.20.2 (#1097)
* Send LoginAcknowledged immediately

* Resend player list header/footer after backend server switched to config state

* Fix clearHeaderAndFooter not clearing fields in ConnectedPlayer

* Clear boss bars, header/footer, tab list when switching client to config state

* Send client settings in config state
2023-10-12 11:11:47 +02:00
Joo200
9be0bca3c4
Catch throwables when loading plugins (#1098) 2023-10-11 16:24:35 +01:00
Shane Freeder
2bd2c692ea
Change packet decode logging prompt 2023-10-10 18:44:03 +01:00
Shane Freeder
05e5963660
appease checkstyle, move back to older fix placement 2023-10-10 18:21:02 +01:00
Shane Freeder
550ca58a09
Actually send plugin message registration to backend servers
I don't see where this was ever done, and don't see how plugin messaging
could of ever worked, at least within the confines of CB and co, given
the fact that we never seemed to be sending this to the backend?
2023-10-10 18:05:05 +01:00
Paul
768ecdb0c3
1.20.2 Support (#1088)
Co-authored-by: RednedEpic <redned235@gmail.com>
Co-authored-by: Gero <gecam59@gmail.com>
2023-10-10 12:44:16 +00:00
Andrew Steinborn
19abb9094e fix #1062 2023-08-20 02:13:55 -04:00
Andrew Steinborn
f62d759896
Do not track plugin channels registered per-player on the proxy (#591)
We don't need to track this information since Velocity uses the JoinGame packet, which is about as good of a server rejoin mechanism we're likely to get in vanilla Minecraft.
2023-08-17 23:51:34 -04:00
Aaron
be9ecf75b2
check if a plugin has a executor service (#1038)
* check if a plugin has an executor service

* checkstyle
2023-08-04 20:48:01 -04:00
Gero
5ef90c46e3 1.20 2023-06-06 17:13:48 +02:00
Adrian
e0cf2e211f
Updated Guice to 6.0.0 and manually include updated ASM (#1016) 2023-06-02 22:12:03 -04:00
Andrew Steinborn
40b76c6332 Fix flaky obtainTasksFromPlugin() test 2023-05-15 01:21:30 -04:00
Andrew Steinborn
92ae25b8ac Also make sure to use the latest ping serializer as well 2023-05-15 01:20:45 -04:00
Andrew Steinborn
12a05f6d75 When pinging the server with protocol version -1, return the latest version supported by the proxy
This matches BungeeCord's behavior and is in line with what clients specifying this meta-version would expect.
2023-05-15 01:15:49 -04:00
Andrew Steinborn
673af65078 fix 2023-05-14 03:18:20 -04:00
Andrew Steinborn
a29c753e39
Give each plugin its own executor service (#1010)
This is part of preparatory work for Velocity 5.0.0's revamped event system, but this change is safe to bring into the 3.x.x series. This affects the scheduler for now, but command execution will also be moved into the per-plugin thread pool, along with invocations of `EventTask.async()`.
2023-05-14 02:51:25 -04:00
Alexander Städing
1161482fce
Upgradle to v8.1 and remove now-redundant warnings (#1001) 2023-04-19 17:43:25 -04:00
Adrian
e364e2c7d1
feat: Warn if an attempt is made to register a command with multiple interfaces implemented instead of just ignoring it (#1000) 2023-04-09 12:23:39 -04:00
Andrew Steinborn
d438422d52 Get a bit more spotless 2023-04-09 12:19:50 -04:00
Andrew Steinborn
2fa9f37481 Delete copying temporary version of config.toml into temporary files
Fixes #999
2023-04-09 12:18:02 -04:00
Gero
93b6376b38
Remove registry decoding (#979) 2023-03-29 09:21:01 +02:00
Alexander Städing
7b5f010215
Forgot to migrate adventure bom declaration 2023-03-26 16:18:28 +02:00
Alexander Städing
e9526e0e23
Move dependencies to gradle version catalog and clean up buildscripts 2023-03-26 14:53:11 +02:00
Gero
c7ba5255e3
Add Player#hasSentPlayerSettings (#980) 2023-03-21 09:22:40 +01:00
EpicPlayerA10
01f1e1a94e
Fix header and footer desync (#928) 2023-03-16 02:32:09 -04:00
Andrew Steinborn
15cce53adf
Revert "Handle exceptions in ConnectionRequestBuilderImpl#fireAndForget (#875)" (#978)
This reverts commit b4e04204a9.
2023-03-16 02:14:22 -04:00
A248
b4e04204a9
Handle exceptions in ConnectionRequestBuilderImpl#fireAndForget (#875)
See #859
2023-03-15 23:02:02 -04:00
Andrew Steinborn
7e9a25209c Update various dependencies 2023-03-15 22:52:12 -04:00
Adrian
cc74cf855f
Added MiniMessage support to built-in motd (#666) 2023-03-15 19:27:20 -04:00
Adrian
65a84833d7
Expose Caffeine in the API module 2023-03-11 08:36:38 -05:00
Gero
43f6dd653b
1.19.4 (rc1) (#967) 2023-03-09 19:25:52 +01:00
Nassim Jahnke
5d03023679
Update ServerData reading 2023-03-09 19:25:51 +01:00
Nassim Jahnke
31e557c80b
Start working on 1.19.4 2023-03-09 19:25:51 +01:00
Nassim Jahnke
9122d70ffe
Update Gradle wrapper, add wrapper-validation-action to build workflow 2023-03-09 19:10:01 +01:00
Gero
cb1f336d14
Fix cancellation of PlayerChatEvent for key revision GENERIC_V1 (#941) 2023-03-09 18:56:09 +01:00
Corey Shupe
d733e88677 Add getEntry to TabList.java 2023-02-20 10:11:33 -05:00
Nassim Jahnke
e0e156a420
Fix task scheduler, reject tasks above cap
The ThreadPoolExecutor API is confusing with *very* common pitfalls, one of them being a setup like the one before completely blocking task execution while core task executors are working, not actually starting new threads.
2023-02-19 14:47:38 +01:00
Andrew Steinborn
b0988bc50a Add a hard cap of 200 threads to VelocityScheduler
This is a more realistic (generalized) solution for #943. Fundamentally, a plugin should not be spawning an unbounded number of asynchronous task execution units on demand from the user - an invariant Velocity itself enforces. However, since this practice is so commonplace, it makes sense that we would need to have some upper cap to at least make the practice safer than it currently is.
2023-02-18 16:20:12 -05:00
DEv0on
cd35e8f8a9
Fix for edgecase FML|HS packet desynchronization (#948)
* Fix for edgecase FML|HS packet desynchronization

* Change approach for FML packet desynchronization edge case
2023-02-15 01:00:11 -05:00
Adrian
8761d02def
feat: Implement RegisteredServer#ping(PingOptions) (#938) 2023-01-26 00:33:07 -05:00
Andrew Steinborn
f744b37ad5 Merge remote-tracking branch 'origin/dev/3.0.0' into dev/3.0.0 2023-01-21 18:22:04 -05:00
4drian3d
d6c0b71648 Add /velocity heap command (#786) 2023-01-21 18:21:22 -05:00
Outfluencer
50acf17f3f
Username can be 16 * 3 bytes (#936)
see my pr #843
2023-01-21 18:14:49 -05:00
EpicPlayerA10
8a048f0505
Fix sendPluginMessage (#926) 2023-01-13 17:43:50 -05:00
Andrew Steinborn
586cd56c05 Fire PluginMessageEvent correctly if it's sent when a connection is established
Fixes #774
2023-01-08 13:34:44 -05:00
Andrew Steinborn
022ae0fc00 Instead of re-encoding the client-server registry, pass through the original 2023-01-08 13:18:14 -05:00
Andrew Steinborn
7ed422b4ed Switch all Guava Cache uses to Caffeine 2023-01-01 19:05:13 -05:00
Andrew Steinborn
aaa24752ac Update various other dependencies 2023-01-01 18:58:27 -05:00
Andrew Steinborn
3768e66e86 Also use Spotless to remove unused imports 2023-01-01 18:52:11 -05:00
Andrew Steinborn
b0862d2d16 Use Spotless for license formatting 2023-01-01 18:46:33 -05:00
Andrew Steinborn
d715e17acb Bump copyright date to 2023 2023-01-01 17:56:00 -05:00
Andrew Steinborn
d72d707b1c
Convert Velocity buildscripts to Kotlin DSL (#918)
Spiritually indebted to #518 and @alexstaeding.

There's a minor break - we're going up to 3.2.0-SNAPSHOT as the API now compiles against Java 11. But this is more academic in practice.
2023-01-01 17:53:37 -05:00
Andrew Steinborn
ffa4c95435 Fix GS4 query reloading logic
Closes #915. This isn't a fatal error, but it's a clear papercut.
2023-01-01 13:07:31 -05:00
Andrew Steinborn
ef7ad150c2 Add plugin logger name to file logger configuration
Closes #903
2023-01-01 11:33:37 -05:00
Andrew Steinborn
4ef9a33f4c Add native info to dump 2023-01-01 11:30:39 -05:00
Andrew Steinborn
118c4b451c Save /velocity dump output into a local file instead.
dump.velocitypowered.com is going to go offline on January 15th.
2023-01-01 11:26:45 -05:00
James58899
294199e270
Fix typo in #900 2022-12-19 17:31:02 +08:00
Andrew Steinborn
1ec77eb123 Fix #887
Velocity always handled ALL as an alias of ONLINE, so handle ONLINE the same way.
2022-12-11 23:29:57 -05:00
Remynfv
495b796816
Fix grammar in obscure error message (#880)
The title really says it all. Change ``The forwarding-secret-file does not exists.`` to ``The forwarding-secret-file does not exist.``
2022-12-11 22:40:58 -05:00
JOO200
97770cd1a6
Reduce Spam from the TabList by not sending every package multiple times (#902)
* Reduce Spam from the TabList by not sending every package multiple times

VelocityTabList#processUpsert called entry.setX which will create a package and send it to the client.
BackendPlaySessionHandler doesn't return true for those packages, therefore the package for tab list updates will be send two times.

* Cleanup TabList#buildEntry, added listed status to Entry builder
2022-12-09 13:40:30 -05:00
James58899
fa17a5d4cc
Fix command packet (#900)
fix https://github.com/PaperMC/Velocity/issues/898
2022-12-08 18:13:57 +00:00
Petr Ilin
d3e5dc1354
Fix TitleTimes packet ID for Minecraft 1.19.3 (#899) 2022-12-08 17:03:16 +00:00
Corey Shupe
361f6335ac
Merge pull request #897 from RoccoDev/fix/1.19.3-unsigned-encode
chat: fix encoding for changed unsigned messages
2022-12-07 13:57:40 -05:00
RoccoDev
3ae3af45bc
chat: fix unsigned encoding for changed messages 2022-12-07 19:51:12 +01:00
Corey Shupe
2a0d657a0c Fix profile presence 2022-12-07 13:26:01 -05:00
Corey Shupe
cc7d199f47
Merge pull request #895 from RoccoDev/fix/1.19.3-legacy-cancel
regression: fix legacy chat cancelling on < 1.19
2022-12-07 13:19:07 -05:00
RoccoDev
039799b2d3
legacy-chat: fix cancel on < 1.19 2022-12-07 19:14:32 +01:00
Corey Shupe
0250d1ef8a Fix null timestamps being passed to timekeeper improperly. 2022-12-07 12:56:27 -05:00
Corey Shupe
b504e0857c
Update to 1.19.3-rc3 (#893) 2022-12-07 14:12:48 +01:00
Andrew Steinborn
7d77bfb53c Update select dependencies 2022-09-21 00:48:21 -04:00
Shane Freeder
f6b032cb04
Fix misrenamed illegal chat chars translation key 2022-09-15 21:48:28 +01:00
OOP-778
cae41c33a1
Fix connection error spamming (#847)
* Fix "pointers" for players never being used lol

* Added Platform Facet API to add Type pointers

* Remove duplicate

* Fix some connection things

* Make checkstyle happy?
2022-08-19 22:46:57 -04:00
Outfluencer
47cd9faf65
A char can be 3 bytes (#843)
BungeeCord reference: b5365dcba7
2022-08-19 22:45:58 -04:00
kyngs
3293f7a9eb
Fix #828 (#829)
Co-authored-by: kyngs <kyngs@users.noreply.github.com>
2022-08-09 15:03:03 -04:00
Andrew Steinborn
6496983ca3 Fix cancelling commands on <1.19 clients (#827) 2022-08-08 00:42:31 -04:00
JNNGL
62bd58d356
Fix decoding of unsigned messages on 1.19.1 (#814) 2022-08-03 11:20:25 -04:00
Rocco
8344082b1a
Fix chat decoding for legacy versions (#815) 2022-08-03 09:19:30 -04:00
James58899
88a5abd26c
Fix command packet wrong mark as unsigned (#810)
Dropping previousMessages will break the chat chain
2022-08-03 10:42:43 +00:00
Corey Shupe
e5b84ecf1d
Update/chat order queue (#801)
* Implement chat queue for ordered chat.

* Update system to handle spoofed chat as well.

* Fix checkstyle erroring on bad indentation.

* Fix ChatQueue to use whenComplete instead of thenRun

* Merge upstream.

* Checkstyle

* Deny denied commands.
2022-08-02 20:50:01 -04:00