Commit Graph
100 Commits
Author SHA1 Message Date
Shane Freeder 5613ed6dfb Provide env environment variable and copy spigots sys prop for overriding default repository 2025-06-18 11:04:48 +01:00
Shane Freeder d2b1158e6c Set correct world access on BSL snapshots 2025-06-17 20:38:39 +01:00
Shane FreederandGitHub 94f2903584 Do not blow up accessing unregistered memories from API (Fixes #12618) (#12639) 2025-06-06 22:37:52 -04:00
Shane FreederandGitHub 4eda045b15 Backport fix for MC-296337 (Fixes #12617) (#12619) 2025-06-06 19:05:30 +01:00
Shane Freeder cb3ffd0b4a Don't store empty PDCs on raids 2025-05-02 20:02:34 +01:00
Shane Freeder 93246a0730 Fix errors when loading raid files without a PDC 2025-05-02 19:43:06 +01:00
Shane FreederandGitHub fc0c371761 Fix handling of resultant crafting container from craftItemResult (#12307)
The result object of overhanging items is based upon a derived view
of the provided crafting slots, meaning that we need to consider this
when handing back the resultant slots.
2025-04-29 15:38:11 +02:00
Shane Freeder 2948eb296d Mitigate an issue when loading a spigot config with null spam exclusion entries 2025-04-15 15:54:10 +01:00
Shane Freeder a55345f991 Add support for deserializing manually deserialized items, also add caller note 2025-04-15 09:30:44 +01:00
Shane Freeder f517267c0c Add passthrough for air serialization 2025-04-12 18:44:48 +01:00
Shane Freeder 2aad131e74 Add config option for command spam whitelist 2025-03-23 18:31:39 +00:00
Shane FreederandGitHub 597dcfffb9 Add support for lz4 (#12053)
Mojang added this early 2024, however, it wasn't ever added to the actual config option
inside of paper
2025-02-08 19:07:43 +01:00
Shane Freeder a35cfe93f9 Correct version of some network related dependencies 2025-01-17 15:31:45 +00:00
Shane Freeder e150ffd272 Add missing final
"muh checkstyle" more like "muh missing style config"
2025-01-17 13:49:38 +00:00
Shane Freeder 938a84fc39 Add missing TagSerializable to GsonDataComponentValue converter (Fixes #11768) 2025-01-17 13:47:28 +00:00
Shane Freeder c9a904ed17 Fix keepalive logic resetting counter
This would of actually arised in the client being kicked due to sending
bad keepalive packets due to the erronious extra sending of keepalives too
2024-12-26 15:19:56 +00:00
Shane Freeder cbf630d5b5 Move missing import into feature patches to fix pre-features compile
Came across this in my complete utter failure to use the commands to
apply patches properly
2024-12-23 09:28:58 +00:00
Shane Freeder 767215bf9b net/minecraft/world/level 2024-12-14 23:42:36 +00:00
Shane Freeder a546b39e58 net/minecraft/world/scores 2024-12-14 20:46:54 +00:00
Shane Freeder 12e0268dab net/minecraft/core 2024-12-14 20:27:11 +00:00
Shane Freeder a890e322f1 net/minecraft/world/entity/ai/sensing (but, actually) 2024-12-14 18:42:28 +00:00
Shane Freeder e90ba22ef7 net/minecraft/world/entity/ai/sensing 2024-12-14 18:40:19 +00:00
Shane Freeder 1a214aed6a net/minecraft/world/entity/item 2024-12-14 17:58:14 +00:00
Shane Freeder 3672a7d70f net/minecraft/world/entity/npc 2024-12-14 16:44:20 +00:00
Shane Freeder 6002fbc152 /net/minecraft/world/level/levelgen/structure/templatesystem 2024-12-14 16:44:20 +00:00
Shane Freeder 49e63e0b01 Update WorldServer#serverlevelData mapping 2024-10-26 15:11:09 +01:00
Shane Freeder 9fdcea361c Anti Xray 2024-10-24 20:10:38 +01:00
Shane Freeder 3f75dfff7d Checkpoint 2024-10-24 19:40:24 +01:00
Shane Freeder 630bdd8cda A bunch more 637 2024-10-23 21:10:14 +01:00
Shane Freeder 615e1d5a6a A bunch of patches 2024-10-23 20:43:06 +01:00
Shane Freeder 5912598c02 Some small touchups to the GUI (#11505)
As noted on the issue, the method here can blow up in
certain cases, the GUI logic already handles "the mouse is missing",
and so, we'll just catch this and move on.

Misc fix - There is probably an issue report for this somewhere,
but, the details section utilised the bukkit singleton to try to get
the TPS from the server. We already have the MinecraftServer instance
passed into us, and so we'll just get the information directly from there instead.

Fixes: #11494
2024-10-21 00:10:10 +01:00
Shane Freeder 9ad769150f Always send Banner patterns to the client (#11506)
The mojang client will not remove patterns from a Banner when none
are sent inside of an update packet, given that this is not an expected
flow for them, this is not all too surprising. So, we shall resort to always
sending the patterns over the network for update packets.

Fixes: #11487
2024-10-21 00:02:00 +01:00
Shane Freeder 64705c224b [ci skip] rebuild patches 2024-10-17 21:24:10 +01:00
Shane FreederandBjarne Koll 5d6137bcc9 Only mark decorations dirty if a removal actually occurs (#11413)
* Only mark decorations dirty if a removal actually occurs

Vanilla calls this method blindly inside of a loop which erroniously marks
map data files as being dirty even if nothing has actually changed.

* Merge into existing patch

---------

Co-authored-by: Bjarne Koll <git@lynxplay.dev>
2024-09-19 15:27:33 +01:00
Shane Freeder d0221fe540 Migrate ArmorStand meta to using entity tag (#11107) 2024-08-16 23:30:11 +01:00
Shane Freeder c58d918886 Don't entirely die just because a plugin jar was bad 2024-07-29 16:54:46 +01:00
Shane Freeder c2b2de43cf Shutdown L4J cordially if the server stops before it's even started (#11172)
primarily, this allows us to ensure that appenders are flushed, console, log files
before the JVM exits to avoid issues such as error messages disappearing
2024-07-29 16:10:53 +01:00
Shane Freeder 7c88512287 Bump MCUtils#asyncExecutor core size
Long ago we discovered that the default thread pools would not increase
the number of threads running the pool until queue addition failed.
Bumping the core size mitigates an issue with spark-paper, and in general,
keeping async threads around generally beats having to spin new ones
everytime we want to execute a periodic async task.
2024-07-26 13:43:48 +01:00
Shane FreederandNassim Jahnke 12356fbe77 Fix explosions calculation getting stuck (#11061)
Co-authored-by: Nassim Jahnke <nassim@njahnke.dev>
2024-07-12 08:16:03 +01:00
Shane Freeder 69258a8c33 Do not crash when an exp orb attempts to mend an unrepairable item 2024-06-23 14:04:58 +01:00
Shane Freeder 28238907c1 Revert "Fixes exception log messages getting dropped during bootstrap (#10935)" (Closes #10945)
This reverts commit 05dd6c2bec.
2024-06-21 10:05:27 +01:00
Shane Freeder 71f3228b5c Fix diff in sprint interruption option (Closes #10939) 2024-06-21 01:21:23 +01:00
Shane Freeder 3bb51e10ab Fix sending disconnect packet in phases where it doesn't exist 2024-05-30 19:05:39 +01:00
Shane Freeder 1f743f10af Fix missing debug trace 2024-05-27 18:33:34 +01:00
Shane Freeder e04d670f1d Do not re-wrap vanilla goals (#10751)
There is no need to rewrap vanilla goals when they're being reregistered,
this breaks some expectations around behavior outside of general
wasting of resources.

Resolves: #10743
2024-05-24 15:22:41 +01:00
Shane Freeder c889d48f8c Make PaperSimplePluginClassLoader show class which is not found 2024-05-18 21:17:54 +01:00
Shane Freeder 2d2eafa713 Update Adventure to 4.17.0 Release 2024-05-08 15:48:45 +01:00
Shane Freeder a8e49a12d3 default save-empty-scoreboard-teams to vanilla
The primary environmental factor which caused this feature to be implemented
is no longer much of a factor within the community
2024-05-02 09:53:43 +01:00
Shane FreederandJake Potrebic f4303373e1 Add itemName components (Resolves #10467) (#10471)
* Add itemName components (Resolves ##10467)

* improve javadocs and formatting

* rebased

---------

Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
2024-04-28 18:08:59 +01:00
Shane Freeder 36fa573f48 Fix another missing book meta tag 2024-04-28 13:48:20 +01:00
Shane Freeder 4aab51d78a Fix book meta lacking resolved tag from older versions (Fixes #10470) 2024-04-28 13:15:03 +01:00
Shane Freeder 4f09300744 Restore Handle Large Packets Disconnecting Client Patch 2024-04-27 15:06:52 +01:00
Shane Freeder 0d8e6831c3 Fix StackOverflowException thrown on shutdown (Fixes #10404) (#10408)
paper previously migrated away from using executeIfPossible as this throws a
RejectedExecutionException when the server is shutting down, which is then picked
up by the Connection handler object and causes the player to be kicked without
the intended disconnection message that comes from commands such as /stop, /restart

This was fine, because previously changes made in spigot would just prevent these
packets from being executed anyways. Instead, we'll just use a marker exception
to try to detect this specific state.
2024-04-12 20:37:00 +01:00
Shane Freeder b56970d394 Allow player-list API to self un/list (#10358) 2024-04-07 01:45:43 +01:00
Shane Freeder 5efed01031 Do not copy profile data if profiles are the same (#10259) 2024-03-20 21:47:50 +00:00
Shane Freeder 5a66c3b64e Don't tick empty worlds (#9025) 2024-03-03 21:10:45 +00:00
Shane Freeder f8a84f01e2 Make debug mode print current configuration phase 2024-02-23 13:54:52 +00:00
Shane Freeder e33fdd8189 Do not access world state to see if we can see a Player
Thrown into the adventure patch because I don't see the justification of a patch existing
for something like this.
2024-02-22 16:23:15 +00:00
Shane Freeder 72004ecb99 Updated Upstream (Bukkit) (#10255)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
58ce1b0f Improve compatibility of new DamageSource API
2024-02-16 22:44:38 +00:00
Shane Freeder 49feea0525 Convert average tick value in the GUI to the correct granularity 2024-01-24 16:27:32 +00:00
Shane FreederandCryptite e34d100c9c Async world data IO saving (#10171)
Co-authored-by: Cryptite <cryptite@gmail.com>
2024-01-20 21:51:15 +00:00
Shane Freeder 0f611e7b4f Fix issue with kick event causes being passed improperly 2024-01-18 19:35:56 +00:00
Shane Freeder 79599cfd22 Re-add missing vanilla safeMode arg 2023-11-25 09:49:48 +00:00
Shane Freeder 3cf895a891 Don't leave the NearbyPlayers tracker in an entirely busted state on double-add detection 2023-11-05 22:15:38 +00:00
Shane Freeder 5165228828 [ci skip] Fix module derp 2023-10-29 01:32:13 +01:00
Shane Freeder 03bd83a051 [ci skip] Fix author in last patch 2023-10-29 00:58:15 +01:00
Shane Freeder 69b2101f34 Temp fix for serialisable blockdata 2023-10-22 19:56:25 +01:00
Shane Freeder 13884a0748 Quick tweaks to logical flow of getMapData 2023-10-04 16:25:26 +01:00
Shane Freeder 3ebe415f47 Fix/update wiki (#9758) 2023-09-25 00:02:46 +01:00
Shane Freeder 1a1af91ce3 Handle new brand payload type 2023-09-24 19:48:29 +01:00
Shane Freeder 3b3cf7f532 Don't allow for supporting block checks to load chunks
I cannot test this due to lack of hardware (took 30 minutes getting paper
updated and loaded into IJ on this machine...), however, this is the easiest
patch for now. Ideally, some form of distance check would probably be added to
improve invalidation of this cache.
2023-07-05 23:13:30 +01:00
Shane Freeder 7727050285 Temp: Pre-init PlayerChunkLoaderData in order to prepopulate the BFS lookup cache because potatos (Closes #9338) 2023-06-18 13:49:22 +01:00
Shane Freeder e00471db27 Updated Upstream (Bukkit/CraftBukkit)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
465c4964 PR-843: Add damage methods to FallingBlock
46ba7c9f SPIGOT-7335: Fix typo in TextDisplay#TextAlignment enum name

CraftBukkit Changes:
818582f40 PR-1169: Add damage methods to FallingBlock
15a3eac66 SPIGOT-7335: Fix typo in TextDisplay#TextAlignment enum name
f01fb4979 SPIGOT-7336: Fix typo in internal method name
2023-04-14 00:52:42 +01:00
Shane Freeder 5322e3cffb Revert "Resolve Plugin Dependency Issues, Improve PluginLoading Compat, Small Loading Issues (#9068)"
This reverts commit cfcfc9301c.
2023-04-10 11:25:04 +01:00
Shane Freeder 9df9cf9fb4 Updated Upstream (Bukkit/CraftBukkit)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
de5ba402 PR-848: Mark get/setCatType methods deprecated in addition to the enum

CraftBukkit Changes:
50ee87fbc SPIGOT-7333: Correctly handle null in ColorableArmorMeta#setColor()
790be710b SPIGOT-7332: Persistent Data Container of Chunk not saving on stop or restart.
2023-04-09 23:38:03 +01:00
Shane Freeder b4b4aee3dc Updated Upstream (Bukkit/CraftBukkit)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
aeb62aa3 Remove obsolete documentation from ArmorMeta#setTrim

CraftBukkit Changes:
cb6f3c028 PR-1173: Change CraftMinecartTNT to public for consistency
2023-04-09 01:13:38 +01:00
Shane FreederandOwen1212055 cec73ac951 Fix TPS command output (#9091)
* Fix TPS command output

* Cleanup + rebase

---------

Co-authored-by: Owen1212055 <23108066+Owen1212055@users.noreply.github.com>
2023-04-07 00:08:44 +01:00
Shane Freeder 9f03aa5cc0 Prevent GameEvents being fired from unloaded chunks 2023-04-06 12:42:10 +01:00
Shane Freeder 076afec362 Do not send expired keys to players on login (#9090)
This patch will prevent sending expired keys to players when logging into a server, while the client does have some grace period to prevent issues, if a key has expired beyond the grace period, connecting clients will be disconnected from the server upon join. The client should update keys before this key even expires, and a new key will be broadcasted out if we somehow actually get one.
2023-04-03 10:45:02 +01:00
Shane Freeder ee6a62f6b7 Don't use plugin-profiling to enable timings
The paper config has taken precidence over this for a long time
with 0 complaints, and now it's tripping the deprecation warning,
even if timings is disabled in the paper config.
2023-03-31 05:47:59 +01:00
Shane Freeder 19889e8a77 Temp fix for EntityType.translationKey
Upstream improperly used the enum name for looking up the vanilla entity
type to get the translation key; temp patch this until upstream fixes this,
also add some quick validation
2023-02-16 03:20:43 +00:00
Shane Freeder 0e45eeb9d2 Disable ATs from unapplied folder 2022-12-07 23:25:00 +00:00
Shane Freeder ec00900b8b Fix dumplisteners missing folder creation 2022-12-06 04:02:44 +00:00
Shane Freeder 3c0aa837c1 Fix Varint21FrameDecoder cached length buf usage 2022-11-22 17:50:31 +00:00
Shane Freeder 435cc8ebd8 Cleanup misc import from last commit 2022-11-06 22:46:23 +00:00
Shane Freeder f5e9a14a25 Prevent compass from loading chunks 2022-11-06 22:37:34 +00:00
Shane Freeder 857ece0812 Fix setting difficulity inside of API (Fixes #8533)
Vanilla moved some logic around setting the world difficulty which
was not adopted for inside of upstream properly, this addresses another
such case
2022-11-01 18:29:52 +00:00
Shane Freeder c0e803bfd2 Make CraftMinecartTNT public
adding the getHandle method causes some issues with things like ProtocolLib
due to the expectation that all classes which provide a getHandle method
are public.
2022-10-12 16:10:52 +01:00
Shane Freeder bf718e5334 [ci skip] shuffle patches and rebuild 2022-09-28 04:27:26 +01:00
Shane Freeder fb6addf9e6 Fix mangled patch 2022-09-24 05:48:42 +01:00
Shane Freeder 8e18842fbc Updated Upstream (Bukkit/CraftBukkit/Spigot)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
c7c11188 SPIGOT-2620: Add Player#sendBlockChanges()
f63d2b44 Improve annotation test on parameters
3372e7b4 SPIGOT-1244, SPIGOT-6860, SPIGOT-6874: Various Javadoc and formatting fixes
a1e8a9ab PR-793: Ignore .checkstyle file generated by Eclipse IDE

CraftBukkit Changes:
c2c39089e SPIGOT-2620: Add Player#sendBlockChanges()
8209158db PR-1113: Ignore .checkstyle file generated by Eclipse IDE

Spigot Changes:
4aa5ead2 Rebuild patches
2022-09-24 02:38:12 +01:00
Shane Freeder eb3f66c6da Updated Upstream (Bukkit/CraftBukkit) (#8378) 2022-09-23 06:08:43 +01:00
Shane Freeder ede4468516 Make WorldCreator#keepSpawnLoaded return the WorldCreator (Fixes #8321) (#8371)
* Make WorldCreator#keepSpawnLoaded return the WorldCreator (Fixes #8321)

Thought that I fixed this before push/merge, apparently not, hence, fix
the return type and add mitigation for this.

* Fix patch/build

* Rebuild patches
2022-09-20 01:28:22 +01:00
Shane Freeder e14a2a0cce Configurable chat thread limit (#7878) 2022-09-20 01:16:23 +01:00
Shane Freeder f7b33b60b0 Use thread safe Random inside of ServerLoginPacketListenerImpl
Vanilla uses a Random instance which is not thread safe inside of the
constructor for ServerLoginPacketListenerImpl, this is an issue because
instances of that class are created on the network worker threads, which
means that there is a potential (which we have reports confirming) that
multiple users logging on could trip this
2022-08-11 14:38:45 +01:00
Shane Freeder 53885ac491 Don't manually send ClientboundPlayerPositionPacket for refreshPlayer
in 1.19, mojang made it so that teleporations validate that an awaiting pos was
set in the server when teleporting, thus we need to ensure that this is set when
sending the player pos, otherwise the player will be kicked when the client sends
back the aknowledgement
2022-08-10 15:01:39 +01:00
Shane Freeder f9f8a78753 Fix plugin update IO logic when replacing jars 2022-07-23 05:52:57 +01:00
Shane Freeder 226468f7b0 Cache Component MOTDs 2022-07-23 02:56:50 +01:00
Shane Freeder 93f19c4e41 Add a bit of extra debugging to chat order/time errors
I do wanna add some leeway to the kick, if message was sent within 30-60
seconds of the last message, assume clock drift and just ignore the kick
(send a message? just silently ignore?), but, I'm not 100% on this one
2022-07-06 05:53:16 +01:00
Shane Freeder a029f5d67c Parse MOTD as legacy sectioned string (Fixes #8036)
This is not ideal but this is how MOTDs have been parsed for years,
ensure that this is performed for all things getting the MOTD from
the server
2022-06-22 09:15:20 +01:00