Commit Graph

74 Commits

Author SHA1 Message Date
Alexander Medvedev
4a4b72c83c chore(plugin-api): extend entity api 2026-05-17 19:46:57 +02:00
ChocoDev
2586d46380 feat: cross version sound id remapping (#2103) 2026-05-07 11:14:15 +02:00
Alexander Medvedev
12de93a4bb feat(bedrock): add zLib packet compression 2026-05-04 10:35:04 +02:00
Alexander Medvedev
e9423dcb9c chore: add encoder fuzzing
ofc nothing more :wink
2026-04-16 20:32:19 +02:00
Alexander Medvedev
2c338f468c feat: add dragon ai
not perfect, bit buggy, but it works overall
2026-04-12 19:10:14 +02:00
RB007
a7ebad7eee feat: send all crafting recipes to players (#1999)
* feat: send all recipes to players

* chore: clippy and added config option
2026-04-10 19:17:35 +02:00
HairlessVillager
974bdd98a6 chore: add license to Cargo.toml files (#1927) 2026-03-28 15:47:15 +01:00
とぴ。(おーけ
44989c86f4 feat: More compatible Java Edition versions (>=1.21) (#1435)
* 1.21.9

* 771: 1.21.6

* 770: 1.21.5

* 769: 1.21.4

* better impl

* missing data

* 768: 1.21.2

* added >=1.21.2 mapping

* impl abstract remapper.

* added entity_id remap

* fix commands packet (<1.21.6)

* fix 1.21.4 level_chunk_with_light

* fix reading packet

* fix sneak <=1.21.6

* Merge branch 'master' into protocol

* fixed `level_chunk_with_light` packet (<=1.21.4)

* 767: 1.21

* fixed `login_finished` packet (<=1.21.1)

* fixed `login` packet (<=1.21.1)

* fixed `player_position` packet (<=1.21.1)

* fixed `set_held_slot` packet (<=1.21.1)

* fixed `set_time` packet (<=1.21.1)

---------

Signed-off-by: とぴ。(おーけ <support@topi-banana.com>
Co-authored-by: Alexander Medvedev <lilalexmed@proton.me>
2026-02-23 12:06:37 +01:00
ChocoDev
9f78d65c3f perf: packet encode, decode and compression (#1517)
* fix: protocol network optimize

* compression reuse and decoder payload

* revert risky lighting queue

* refactor: split observability and dedupe packet broadcast grouping

* remove log.workspace = true

* [expect]

* clippy

---------

Co-authored-by: chocodev11 <chocodev11@users.noreply.github.com>
2026-02-12 13:41:33 +00:00
Alexander Medvedev
f60a77c5d9 chore: decrease compile time
Instead of parsing pumpkin-data for everyone who compiles lets have it as static files, pumpkin-codegen is a standalone parser now
2026-02-09 15:52:46 +01:00
Alexander Medvedev
fb13004b47 fix: apply clippy lints to workspace
also add contributors to /pumpkin command

Co-Authored-By: Fyor <90567841+fyordev@users.noreply.github.com>
Co-Authored-By: MartV0 <34748938+martv0@users.noreply.github.com>
Co-Authored-By: FabseGP <fabsegp@fabseman.space>
2026-01-28 00:52:47 +01:00
FabseGP
a04b7036bc chore: some cargo adjustments (#1306)
* chore: strip binaries & define rust-version in workspace

* fix: don't strip binary when profiling

* chore: clippy lints

* fix: use stable fmt

* fix: don't strip dev builds
2026-01-23 15:58:07 +01:00
Clicks
24fff00425 Make All Dependencies Workspace Dependencies (#1245) 2025-12-30 12:13:51 +01:00
Alexander Medvedev
42c903493a port to 1.21.11 2025-12-24 13:09:01 +01:00
Alexander Medvedev
3829850607 removed some clones
fix: https://github.com/Pumpkin-MC/Pumpkin/issues/1226
2025-12-07 22:43:26 +01:00
Alexander Medvedev
a2d8ca8d98 fix: pumpkin-world external crate compilation 2025-12-06 10:30:03 +01:00
Alexander Medvedev
03b3ff5e15 This should prevent some dead locks 2025-11-23 20:08:47 +01:00
Alexander Medvedev
0ce5471761 Overhaul registry loading
Registry data is now loaded dynamically for automatic future-proofing, ending the need for manual struct updates. Access to specific values now requires explicit data lookups.
2025-11-18 19:00:18 +01:00
Alexander Medvedev
47bbc56591 this should fix plugin errors
at least for now
2025-11-01 12:13:28 +01:00
Alexander Medvedev
0c2b647a45 fix CI
Replaced old chunk files used for testing
2025-10-06 16:14:03 +02:00
Alexander Medvedev
932512b5d6 lets try fix CI 2025-10-02 16:54:48 +02:00
Alexander Medvedev
91e77c33a0 add more loot table conditions
fix https://github.com/Pumpkin-MC/Pumpkin/issues/1155
2025-08-30 11:58:43 +02:00
Alexander Medvedev
c066787cc1 feat: implement Mob Spawners 2025-08-24 23:02:59 +02:00
Alexander Medvedev
53cef4b050 Add structures
this is by far not done and the implementation is not correct in many ways, but it is still something
2025-08-17 22:12:38 +02:00
Alexander Medvedev
8ccc135d74 Update all crates 2025-07-26 17:51:15 +02:00
Alexander Medvedev
b0cea38596 remove some internal crates 2025-07-11 14:23:14 +02:00
Alexander Medvedev
e0c91b3edc Initial Bedrock support
You can't join the World, But the base is ready
2025-06-29 00:33:44 +02:00
Alexander Medvedev
83555e0dee CI: Remove macOS
For some reason it seems that macOS often has their own implementations and causes the CI to fail
2025-06-22 23:28:59 +02:00
Alexander Medvedev
c253b0902c fix some CI issues
hopefully...
2025-06-12 20:15:46 +02:00
Alexander Medvedev
06c82c75f0 Multi Dimension refactor 2025-05-15 22:59:00 +02:00
Alexander Medvedev
c07882369c Update rustyline-async to 0.4.6
This also includes 2 other smaller crate updates, but i wanted just have rustyline-async not using a weird commit, i asked the maintainer of rustyline-async to release a new version, now its released
2025-04-27 10:51:05 +02:00
Alexander Medvedev
fbd95cb693 Read and Write light data using Anvil
Now we are reading and writing light data to and from the anvil format and send it in the chunk and light packet
2025-04-10 19:09:27 +02:00
Andrew Neeley
055a5d0feb Various essential chat improvements (#692)
* fully validate chat messages

* remove unnecessary stuff

* remove lies

* building errors

* Separate last_seen from signature_cache to mirror Vanilla behavior

* full cache management

* better obj management

* change inline values to const

* change unneccesary new to default

* better comments

* derive defaults

* remove random debugs

* Fix magic numbers

* pretty sure an EnumSet should be u8

* Add assert for allow_chat_reports config option

* Verify chat message expiry and order

* Implement chat session validation

* Set all `ChatError` to `Level::Warn`

* Truncate full_cache correctly

* move java hash functions together

* remove extra use

* `full_cache` as `VecDeque`

* Set `full_cache` capacity

* Remove length check for `key_signature`

* Move `PlayerInfoFlags`

* Move `fetch_mojang_public_keys`

* clippy fix
2025-04-05 22:23:24 +02:00
kralverde
b9d9bacf8c Abstract networking to streamline code and avoid creating a new buffer for (de)compression. (#607) 2025-03-20 06:23:25 -10:00
suprohub
186e846858 Plugin event rewrite (#513)
* simplify all

* fmt

* Consider using derive macro

* Add new events

* Add events call

* minor fixes

* minor fixes

* fix

* optimize code

* big changes

* fix skill issue

* fix

* Consider not specify patch version

* make logger shared

* i want test one thing

* Add one useful function

* add little amouth of docs

* use config instead

* revert changes

* fmt

---------

Co-authored-by: Alexander Medvedev <lilalexmed@proton.me>
2025-02-01 18:14:28 +01:00
Alexander Medvedev
709d222c23 add basic entity NBT storage 2025-01-19 19:30:32 +01:00
Alexander Medvedev
03e81a1436 transfer packet id parsing to build time
This also allows now to create custom packets with a custom packet id which is not in the packets.json
2025-01-10 13:42:39 +01:00
Alexander Medvedev
ee485056fb rename pumpkin-core to pumpkin-util
I see that there is an confusion between the pumpkin-core crate,  People often think that this is the most important one
2025-01-09 13:12:57 +01:00
Alexander Medvedev
fa07af7308 shorten compile times
but only by a bit :c
2025-01-02 15:47:11 +01:00
Alexander Medvedev
7161491005 add some simple test to our nbt crate 2024-12-27 00:27:24 +01:00
Alexander Medvedev
a0339728c7 pumpkin-protocol: remove pumpkin-config 2024-12-26 20:59:25 +01:00
Alexander Medvedev
3dae300f81 Some refactors 2024-12-24 00:56:19 +01:00
Snowiiii
f587cb6748 remove iter_tools
we only used them for collect_vec. I think its worth the "effort" to write Vec type annotations ourself and have one big crate with way too may features we don't need less
2024-12-12 23:40:52 +01:00
Snowiiii
b2f627d517 Use Entity teleport Packet instead of Player
Should make fixing https://github.com/Snowiiii/Pumpkin/issues/363 easier
2024-12-07 15:40:50 +01:00
Hugo Planque
836ddd39eb feat(protocol): Switch from using flate2 to libdeflater to (de)compress zlib (#346)
* feat(protocol): Switch from using flate2 to libdeflater to (de)compress zlib
2024-11-27 18:34:29 +01:00
Alexander Medvedev
402f3951f5 Move to own NBT crate (Mostly) (#100)
* Remove fastnbt as dependency

* Move to own NBT crate

* Added deserialization

Also replaced i8 bool's with bool's

* Use: fastnbt for pumpkin-world

Until i don't figure out why Arrays do not work, we can use fastnbt
2024-11-23 14:50:54 +01:00
we sell insurance
93c6da993f Implement Query protocol (#218)
* Add query options to config
Added packet data types
Correctly parse a handshake packet
Add tokio to pumpkin protocol for `AsyncReadExt` convenience functions

* Add repr(u8) so that PacketType is a byte

* Respond to handshake correctly

* Allow for proper decoding of status packets and properly handle errors in decoding

* Implement challange tokens and verify with token and address

* Encode Basic status packet
Switch to CString since its better to and null errors higher up the code

* Encode Full status packet

* Add forgotten fields to full status packet

* Correctly respond to query clients when requesting full status

* Return actual address and port of server
Respect config options
Remove uncessary debug derives

* Remove packet type as it is redundant/unnecssary

* Implement basic status request
Refactor code for better error handling

* Update README

* Show players correctly in full status packet

* Store all packets in structs instead of enums
Break up en/decoding for each packet
Reduce client tracking
Get rid of QueryClients struct
Stop storing of magic value and check during decoding
Added tests for all decoding and encoding
Fix all sugestions from @StripedMonkey
2024-11-05 20:07:31 +01:00
Snowiiii
b23b7421cf Revert "CChunkData optimizations (#193)"
This reverts commit a1b97730bd.

Due to Errors
```
thread 'tokio-runtime-worker' panicked at pumpkin-protocol/src/client/play/c_chunk_data.rs:84:25:
index out of bounds: the len is 4096 but the index is 25374
```
2024-10-27 12:29:53 +01:00
Alvsch
a1b97730bd CChunkData optimizations (#193)
* optimized CChunkData::write

* Added a profiling profile

* fix CI
2024-10-27 00:15:01 +02:00
Snowiiii
4bb52a7711 deny more clippy lints 2024-10-24 19:30:24 +02:00