2775 Commits

Author SHA1 Message Date
ZlordHUN
4c71000613 fix(bedrock): NetherNet direct connection ICE routing (#3030) 2026-08-23 21:16:14 +02:00
Alexander Medvedev
5fd0933c1c fix: ci 2026-08-23 17:19:24 +02:00
Noël Hagestein
f8932f4f3e feat(inventory): implement lore methods for item stack (#3025) 2026-08-23 16:56:26 +02:00
Alexander Medvedev
89f554ed36 chore: add release ci 2026-08-23 16:22:01 +02:00
Bryan
aee90883e3 fix(net): validate the encryption response verify token (#3007)
Co-authored-by: Alexander Medvedev <lilalexmed@proton.me>
2026-08-23 14:17:42 +02:00
Missing_Love
18e9a0c8b8 fix: 1.21.11 joins (#3027) 2026-08-23 13:43:54 +02:00
Alexander Medvedev
edb848d608 fix: ci 2026-08-23 12:42:37 +02:00
Alexander Medvedev
1abbc7bfec fix: empty entity data 2026-08-22 22:56:55 +02:00
Alexander Medvedev
df28c321ac feat: basic initial datapack support 2026-08-22 18:56:48 +02:00
Noël Hagestein
de8c780053 feat(config): add option to disable plugin signature verification (#2942) 2026-08-22 16:59:11 +02:00
Alexander Medvedev
beb6947dfc fix: https://github.com/Pumpkin-MC/Pumpkin/issues/1303 2026-08-22 15:31:58 +02:00
Gabe D.
7c4b4baaab feat(pumpkin): add /debug start and stop commands (#2782)
Implements the vanilla /debug start and /debug stop commands (tracked in #15):

- /debug start opens one server-wide tick profiling session and rejects duplicate starts.
- /debug stop reports elapsed seconds, processed ticks, and average TPS, then returns the floored average TPS.
- Profiling state handles tick counter wraparound and can be restarted after a completed session.
- Registers minecraft:command.debug at operator permission level 3 and uses the existing Java and Bedrock translation keys.

/debug function is intentionally out of scope because Pumpkin does not yet have the required function runtime.
2026-08-22 13:22:44 +02:00
kedor
381ca7c976 fix(pumkin): portal deadLock and finding portal logic (#3001)
* fix portal deadLock and finding portal logic

* fix clippy
2026-08-22 13:21:33 +02:00
Niclas
342575c2fa feat(plugin-api): support server-side command suggestions (#2344)
* feat(plugin-api): support server-side command suggestions

* fix(data): use deterministic block state properties

* chore: update subproject commit reference for pumpkin-plugin-wit

* fix(plugin-api): avoid unwrap in suggestion handler registration

* fix: point WIT submodule at accessible fork

* fix: restore upstream WIT submodule URL

* fix: update WIT submodule for command suggestions

* Update pumpkin-plugin-wit

---------

Co-authored-by: Alexander Medvedev <lilalexmed@proton.me>
2026-08-22 12:32:06 +02:00
DarkZmaj
4012bdd60b chore(lints): resolve the pre-existing clippy::unused_async_trait_impl wall (#3014)
Every trait method wasmtime's bindgen! generates must be `async fn`
regardless of whether a given implementation needs to await anything,
so clippy::unused_async_trait_impl fired 578 times across the WASM
plugin bridge (crates/pumpkin/src/plugin/loader/wasm/wasm_host/wit/v0_1)
plus a handful of similarly-shaped trait impls elsewhere (redstone
pressure plates, several plant blocks, the pathfinder, three Entity
setter methods). This blocks "Run lints (debug/release)" CI on every
branch regardless of what it actually changes.

Allow the lint at the module level for wasm_host's submodules (one
attribute per module covers every impl inside it) and per-function for
the scattered non-WASM occurrences, rather than restructuring any of
the affected code.

Also fixes three unrelated pre-existing lint failures uncovered once
the above stopped masking them:
- pumpkin-macros::count_placeholders needed to be a const fn
  (clippy::missing_const_for_fn) - this alone was blocking every other
  lint check from ever running, since pumpkin-macros failing to
  compile takes the whole workspace down with it.
- `Result<_, ()>` in Plugin::send_message (clippy::result_unit_err).
- `.ok().is_some_and(..)` that clippy::manual_is_variant_and wants as
  `.is_ok_and(..)`.

Verified with `cargo clippy --all-targets --all-features` (debug and
release) and `cargo test -p pumpkin --lib` (257 passed).
2026-08-22 12:25:51 +02:00
Alexander Medvedev
e1584ffb5f Update pumpkin-plugin-wit 2026-08-22 10:59:23 +02:00
Bryan
21c2b501f9 chore: remove the unused get_fluid_collisions (#3009) 2026-08-22 10:54:13 +02:00
Alexander Medvedev
05f3f8b4f7 feat: 1.7-26.2 client support
this was fucking hard
2026-08-22 10:49:06 +02:00
Alexander Medvedev
80e6fceb08 feat: 1.8 Client support 2026-08-21 16:24:22 +02:00
Alexander Medvedev
c7c8d10d47 feat: more multi version work 2026-08-20 22:39:16 +02:00
Alexander Medvedev
af90b14b1c Merge remote-tracking branch 'origin/master' 2026-08-20 13:15:58 +02:00
Mcxiaocaibug
d654e01e25 feat(command): add /locate structure (#2420)
* feat(command): add /locate structure

Implements /locate structure <name> on top of the existing
find_nearest_structure infrastructure (already used by eyes of ender),
with tab-completion for the known structure sets and vanilla-style
clickable [x, ~, z] teleport coordinates plus horizontal distance in
the success message.

Notes:
- Structure names refer to the generator's structure sets (villages,
  desert_pyramids, ...), optionally prefixed with minecraft:.
- Like the ender-eye path, stronghold (concentric-rings) lookups depend
  on the global structure cache being populated.

Closes #2230

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* refactor(command): derive locate suggestions from generated StructureSet::NAMES

Addresses review feedback: the structure set names are now emitted by
pumpkin-codegen alongside StructureSet::ALL instead of being hard coded
in the locate command.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* feat(command): add /locate biome and /locate poi, use ResourceOrTag arguments

Addresses review feedback on the /locate PR:

- New ResourceOrTagKeyArgument / ResourceOrTagArgument types mirroring
  vanilla's argument pair: both parse `id` or `#tag`, the latter also
  validates against the generated registry/tag data at parse time and
  raises vanilla's argument.resource(_tag).not_found errors.
  /locate structure now uses them instead of StringArgument.
- /locate biome: vanilla-parity spiral search (6400 block radius, 32
  block horizontal / 64 block vertical steps) over the dimension's noise
  biome source via the new find_closest_biome_3d in pumpkin-world,
  including the possibleBiomes short-circuit (walked from the BiomeTree)
  and superflat support. Runs on a blocking thread, reports the 3D
  distance and absolute-y clickable coordinates, and appends the
  concretely found biome for tag searches ("#minecraft:is_forest
  (minecraft:forest)"), all like vanilla.
- /locate poi: searches the world's POI storage within 256 blocks via
  the new PoiStorage::find_closest_matching (chebyshev gather, closest
  by 3D distance, like PoiManager.findClosestWithType), with tag
  support from the generated point_of_interest_type tag data.
- Suggestion matching now also treats ':' as a word separator so that
  e.g. "vil" completes to "minecraft:villages".

Notes / limitations:
- There is no generated structure tag or POI type registry data yet, so
  structure "#tags" resolve to the invalid-structure error and POI ids
  are accepted leniently (unknown ones simply report not-found); only
  nether portal POIs are currently recorded by the server.

Closes #2230

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* refactor(command): run structure search off the async executor, drop panic on join errors

Review follow-ups on the /locate PR:

- /locate structure now runs its search on spawn_blocking like the
  biome search does; scanning up to 100 regions of placement data is
  just as CPU-bound as the biome spiral.
- Blocking-task join errors (panic/cancellation) are mapped to a
  "search failed" command error instead of panicking the command task
  via .expect.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* chore(command): adapt /locate to upstream API changes

Rebasing onto master picked up three signature changes: WorldGenerator
gained a Custom variant for plugin generators, BIOME_REGISTRY became a
reference, and Level::world_gen is now an ArcSwap.

Plugin generators only expose biomes by generating a whole chunk, so
/locate biome reports no match for them rather than pretending to
search.

* fix(command): report structures /locate can actually find

/locate structure returned the placement grid's candidate chunk without
checking whether a structure grows there. Candidates are only possible
sites: the biome at one can reject every structure in the set, so the
command happily pointed at empty terrain.

Resolve the structure start for random-spread sets instead, over every
structure the set contains, which is what explorer maps already do.
Strongholds keep using the ring cache, whose positions are real and
which the start lookup does not handle.



Co-authored-by: Mcxiaocaibug <Mcxiaocaibug@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-08-20 13:14:55 +02:00
Alexander Medvedev
dd8ba62499 chore: make explosion make match more vanilla 2026-08-20 09:22:29 +02:00
Maksas Gornostajus
0844e92911 fix(entity): let explosions push TNT (#2941)
`TNTEntity` claimed to be immune to explosions, and `damage_entities` drops
immune entities before it gets anywhere near the knockback, so a chained TNT
never got the outward kick. Vanilla's TNT entity does not override
`ignoreExplosion`. The TNT case for the knockback origin in `damage_entities`
was unreachable until now.

`tick` also snapshotted velocity before moving and wrote back from that stale
value, so a push landing during the awaits was thrown away. Entities tick
concurrently, so this happened often enough to matter. It reads the velocity
back after `move_entity` now, like vanilla.
2026-08-20 08:49:13 +02:00
WissssleyL
ba58547485 fix(net): drop Java connections that go silent before login finishes (#2964)
Nothing bounds the handshake, status and login phase. Once a player is in
game, progress_player_packets keeps the connection honest with keep-alives,
but there is no equivalent before that, and accepted sockets only get
set_nodelay, so there is no TCP keep-alive either. A peer that stops talking
without closing holds its descriptor until the process exits.

get_packet now gives up after 30s of silence. The timer is reset on every
packet rather than bounding the whole handshake, so a slow but progressing
login is never cut off.

Closes #2627
2026-08-20 08:45:34 +02:00
kedor
cb1f22f7e3 feat(command): updating say commands to use the new node format (#2996)
* updating say commands to the new node format

* fix clippy
2026-08-20 08:42:39 +02:00
すごいジャン
c3e73c9f11 fix(worldgen): BlockDirection random sampling parity with vanilla (#2773) 2026-08-20 08:41:41 +02:00
Bluezly
d37ea7d988 fix(plugin): support LpVector3d and boxed byte slices in packet codegen (#2990) 2026-08-20 08:36:51 +02:00
Alexander Medvedev
c196aa5411 chore: switch handlers to ArcSwap
faster and yet again i need this for PatchBukkit
2026-08-19 21:25:26 +02:00
Alexander Medvedev
61bd8f77b6 chore: swap permissions_manger to dashmap
i need this also PatchBukkit
2026-08-19 19:50:20 +02:00
Alexander Medvedev
489403c58b chore: switch command_dispatcher to ArcSwap
i need this for patchbukkit, but this is also safer in terms of deadlocks
2026-08-19 18:57:31 +02:00
Alexander Medvedev
399bf14150 chore: add packet rate limiter 2026-08-19 11:53:53 +02:00
dependabot[bot]
5c212b38e0 chore(deps): bump DeterminateSystems/magic-nix-cache-action from 9 to 14 (#2980)
Bumps [DeterminateSystems/magic-nix-cache-action](https://github.com/determinatesystems/magic-nix-cache-action) from 9 to 14.
- [Release notes](https://github.com/determinatesystems/magic-nix-cache-action/releases)
- [Commits](https://github.com/determinatesystems/magic-nix-cache-action/compare/v9...v14)

---
updated-dependencies:
- dependency-name: DeterminateSystems/magic-nix-cache-action
  dependency-version: '14'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Alexander Medvedev <lilalexmed@proton.me>
2026-08-19 07:43:49 +02:00
TheDarkSword
207185340a fix: persist item data components dropped on save (#2421)
* fix: persist item data components dropped on save

`DataComponentImpl::write_data` defaults to returning `NbtTag::End`, so any
component relying on that default serialized to nothing. `write_item_stack`
walks the component patch and calls `write_data` on every entry, which meant
those components were silently dropped whenever an item stack was written to
NBT (chests, player inventories, chunk saves). Most of them already had a
deserializer, so the data just vanished on the next save/load.

Implement `write_data` for the data-carrying components that were missing it:
MaxDamage, Enchantable, Food, Tool, BlockEntityData, Container and
BundleContents. For the ones without a deserializer yet (MaxDamage,
Enchantable, Food, Tool) add the matching `read_data` and register them in the
`read_data` dispatcher so they round-trip through write_item_stack/
read_item_stack. The output follows the vanilla NBT shape for each component.

Add round-trip tests for the scalar and compound cases.

* test: use the assert_round_trip helper
2026-08-19 07:39:38 +02:00
kedor
f4b5a00209 fix(command): fix try_flatten of ContextChain - #2987 (#2988)
* fixing try_flatten

* matching try_flatten from vanilla code

* fix cargo

* adding test
2026-08-19 07:37:31 +02:00
ZlordHUN
63275ac637 fix(bedrock): restore eating sounds (#2943)
* Fix Bedrock eating sounds

* Fix Bedrock eating sound handling

* Fix Bedrock actor event values
2026-08-19 07:34:17 +02:00
ZlordHUN
a481248994 fix(bedrock): one block crawling (#2933) 2026-08-19 07:33:35 +02:00
ZlordHUN
dc39800571 fix(bedrock): waterlog aquatic blocks (#2905) 2026-08-19 07:28:32 +02:00
ZlordHUN
f73052c85b feat: Add villager trading and professions (#2408) 2026-08-19 07:27:33 +02:00
Alexander Medvedev
5ef9648362 fix: ci 2026-08-18 22:19:13 +02:00
Demetrius Kanios
29bc796d62 refactor(bedrock): Add PacketWrite impl for NbtCompound (#2992) 2026-08-18 12:15:13 -07:00
ZlordHUN
72dd152484 Fix Java disconnects on Bedrock player join (#2962) 2026-08-18 12:02:10 -07:00
dependabot[bot]
95c42fe927 chore(deps): bump DeterminateSystems/nix-installer-action from 16 to 22 (#2979)
Bumps [DeterminateSystems/nix-installer-action](https://github.com/determinatesystems/nix-installer-action) from 16 to 22.
- [Release notes](https://github.com/determinatesystems/nix-installer-action/releases)
- [Commits](https://github.com/determinatesystems/nix-installer-action/compare/v16...v22)

---
updated-dependencies:
- dependency-name: DeterminateSystems/nix-installer-action
  dependency-version: '22'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Alexander Medvedev <lilalexmed@proton.me>
2026-08-18 19:14:16 +02:00
Alexander Medvedev
ab60adb239 chore: much better tracked_data impl 2026-08-18 18:49:48 +02:00
Alexander Medvedev
5b833274d4 fix: pumpkin-plugin-utils 2026-08-18 15:46:30 +02:00
kedor
47ea95736a feat(command): add summon parameter for execute command and ressourceArgument (#2977)
* adding the summon argument to the execute commands

* fixing issue with the execute command and resources argument
2026-08-18 15:03:31 +02:00
Alexander Medvedev
423522f33e feat: chat spam prevention 2026-08-18 14:59:59 +02:00
Alexander Medvedev
2816d7162e chore: impl many ClientPacket traits 2026-08-17 17:21:36 +02:00
Alexander Medvedev
6c840de350 fix: nix flake 2026-08-17 12:33:05 +02:00
Alexander Medvedev
96cfde9091 fix: ci 2026-08-17 10:45:45 +02:00